How to improve speed?

Hiiii

I have tried so many methods to copy the partition.Currently I read the used clusters from a source partition (using FSCTL_GET_VOLUME_BITMAP )and copy those clusters into destination Partition.This works fine ,but very very very slow…

Because the my data transfer block size is the size of a cluster size…So it comes as 2kb / 4 kb like that…The used clusters may not me continuously… copying single cluster at a time…
So so slow process…

How to improve it’s speed…???


Thanking you

after reading,You can divide Volume Bitmap into multiple parts and create multi thread application to read and write in different location. So Multi threaded application could help you. Some smart calculation( taking 32 bit value, find continuous used cluster and reading them togetjer using & operator) could make it faster.

Hope it helps you…

Thank you Mr.Suresh Vishnoi

I take 32 bits from bitmap at a time.And I’ll try to divide the bitmap and perform the copy operation in multiple threads…

Once again thank you for the useful information…
with regards
Krish

hiiii…

I divided the volume bitmap to two and put first half in one thread and second half in another thread.In the first thread it copy the half of the used clusters in the source volume and in second thread the rest of the clusters.

But this multi threading decreasing my speed…

I think we can’t beat readfile and writefile by putting multi threading…


with confusion

xxxxx@gmail.com wrote:

hiiii…

I divided the volume bitmap to two and put first half in one thread and second half in another thread.In the first thread it copy the half of the used clusters in the source volume and in second thread the rest of the clusters.

But this multi threading decreasing my speed…

That can happen. After all, this is converting sequential disk access
to random disk access, and injecting a lot of seek operations.

Your earlier message implied that you were reading one cluster at a
time. If this is the case, you will see a performance win by reading a
much larger run at a time - try a few megabytes, work from there.

You might also want to issue reads to the src and writes to the dest
asynchronously, so that your process can use both disks in parallel (the
operation will be the slowest of the two.)

Note that copying a partition is never going to be fast. The amount of
data being accessed here is (potentially) very large.

If a disk can do 50Mb/s sequential, and you’re copying a 1Tb partition
that’s 50% used, that’s 170 minutes just for the reads - if you’re
writing to the same physical disk, expect serious delays.

  • M


This posting is provided “AS IS” with no warranties, and confers no rights.

On Sun, Jul 5, 2009 at 9:43 AM, Malcolm Smith wrote:

> xxxxx@gmail.com wrote:
>
>> hiiii…
>>
>> I divided the volume bitmap to two and put first half in one thread
>> and second half in another thread.In the first thread it copy the half of
>> the used clusters in the source volume and in second thread the rest of the
>> clusters.
>>
>> But this multi threading decreasing my speed…
>>
>
> That can happen. After all, this is converting sequential disk access to
> random disk access, and injecting a lot of seek operations.
>
> Your earlier message implied that you were reading one cluster at a time.
> If this is the case, you will see a performance win by reading a much
> larger run at a time - try a few megabytes, work from there.
>
> You might also want to issue reads to the src and writes to the dest
> asynchronously, so that your process can use both disks in parallel (the
> operation will be the slowest of the two.)
>
> Note that copying a partition is never going to be fast. The amount of
> data being accessed here is (potentially) very large.
>
> If a disk can do 50Mb/s sequential, and you’re copying a 1Tb partition
> that’s 50% used, that’s 170 minutes just for the reads - if you’re writing
> to the same physical disk, expect serious delays.
>
> - M
>
>
>
----------------------------------------------------------------------------------------------------------------------------------
Dear
----------------------------------------------------------------------------------------------------------------------------------
Dear Malcolm Smith
I understand the the problem…To improve the speed only I put it in
multi threading…But gives poor speed…
In the above case disk operation parallel…the head has to move a
lot…so consuming extra time…

Here I’ve to copy the used clusters only…And clusters may not be
continuously…
That is the problem I face to take Lager block size in Mega Bytes… to
copy…

Now I’m totally confused…First I tried to copy files… that is
working…But if any error occurs suddenly stopping… After that I tried
with clusters …And with clusters I can operate only one cluster at a time
…so this one gives slow speed…

THANKS AND REGARDS…
kRISH…