DSM-G600, DNS-3xx and NSA-220 Hack Forum

Unfortunately no one can be told what fun_plug is - you have to see it for yourself.

You are not logged in.

Announcement

#1 2008-09-07 18:23:12

5h4rk
Member
Registered: 2008-01-26
Posts: 27

Transfer Speed between HDs

Hi, I'm copying files from a Seagate Barracuda 200G to a Seagate Barracuda 1T and getting a transfer rate of 5.xx MB/s in average. Is this normal?


FFP 0.5 | FW 1.0.5

Offline

 

#2 2008-09-07 19:48:53

fordem
Member
Registered: 2007-01-26
Posts: 1938

Re: Transfer Speed between HDs

It depends on how you're doing the copy - if it is through Windows, cut & paste or similar - then you're transferring data from disk #1 across your network to the Windows PC and then back across the network to the NAS - 5.xx MB/sec is a little less than the theoretical maximum for a 100 mbps LAN but it sounds about right given my "non-scientific" tests.

File size also plays a part - a single 2GB file transfers a heck of a lot faster than 1000 x 2MB files, even though it's the same volume of raw data - this is due to the "housekeeping" required to keep directory and block allocation listings etc. up to date.

Offline

 

#3 2008-09-07 20:19:31

bq041
Member
From: USA
Registered: 2008-03-19
Posts: 709

Re: Transfer Speed between HDs

If you are copying from 1 drive in the NAS to the other drive in the NAS, you will maximize your speed by telnetting in and copying the files that way.  It takes the network completely out of the equation.


DNS-323     F/W: 1.04b84  H/W: A1  ffp: 0.5  Drives: 2X 400 GB Seagate SATA-300
DNS-323     F/W: 1.05b28  H/W: B1  ffp: 0.5  Drives: 2X 1 TB  WD SATA-300
DSM-G600   F/W: 1.02       H/W: B                Drive:  500 GB WD ATA

Offline

 

#4 2008-09-08 03:34:21

bspvette86
Member
Registered: 2008-05-09
Posts: 81

Re: Transfer Speed between HDs

I did an internal copy of a 220MB file from /mnt/HD_a2 to /mnt/HD_b2 in 9.21 seconds.  That is a transfer rate of roughly 24MB/s.


# # time cp /mnt/HD_b2/tmp/test1 .

real    0m 9.21s
user    0m 0.21s
sys     0m 7.62s


Regards,
BSPvette

Offline

 

#5 2008-09-08 10:21:11

Pejn
Member
Registered: 2007-12-17
Posts: 61

Re: Transfer Speed between HDs

real    0m 10.90s
user    0m 0.12s
sys     0m 7.55s

with a 230mb file but in windows i get 31sec with same file hmm

Offline

 

#6 2008-09-08 15:13:56

fordem
Member
Registered: 2007-01-26
Posts: 1938

Re: Transfer Speed between HDs

Pejn wrote:

real    0m 10.90s
user    0m 0.12s
sys     0m 7.55s

with a 230mb file but in windows i get 31sec with same file hmm

Like I said earlier - if you do it from Windows the data has to corss the network twice, once coming and once going - it is not an efficient way to transfer data.

Offline

 

#7 2008-09-08 15:36:36

5h4rk
Member
Registered: 2008-01-26
Posts: 27

Re: Transfer Speed between HDs

I think I'm good then, I'm getting this with a 650MB file:

real    0m 29.78s
user    0m 0.48s
sys     0m 20.45s


FFP 0.5 | FW 1.0.5

Offline

 

#8 2008-09-10 15:07:46

DaveN
Member
Registered: 2008-01-12
Posts: 21

Re: Transfer Speed between HDs

When I copy a 477102080 byte file (exactly 455 MB) from HD_a2 to HD_b2 these are my results:
/mnt/HD_b2/temp # time cp /mnt/HD_a2/Backup/WinXPHome6.tib .
real    0m 19.29s
user    0m 0.28s
sys     0m 15.72s
Giving a speed of 24733130 bytes/sec (23.6 MB/s) - similar to everyone else's results.

However, nightly I use rsync to copy from HD_a2 to HD_b2.  This is a typical output log when doing so:
2008/09/02 02:34:15 [3264] Number of files: 20025
2008/09/02 02:34:15 [3264] Number of files transferred: 26
2008/09/02 02:34:15 [3264] Total file size: 450206222593 bytes
2008/09/02 02:34:15 [3264] Total transferred file size: 6223343983 bytes
2008/09/02 02:34:15 [3264] Literal data: 6223343983 bytes
2008/09/02 02:34:15 [3264] Matched data: 0 bytes
2008/09/02 02:34:15 [3264] File list size: 322655
2008/09/02 02:34:15 [3264] File list generation time: 0.001 seconds
2008/09/02 02:34:15 [3264] File list transfer time: 0.000 seconds
2008/09/02 02:34:15 [3264] Total bytes sent: 6224427974
2008/09/02 02:34:15 [3264] Total bytes received: 1083
2008/09/02 02:34:15 [3264] sent 6224427974 bytes  received 1083 bytes  3601058.18 bytes/sec
2008/09/02 02:34:15 [3264] total size is 450206222593  speedup is 72.33
2008/09/02 02:34:15 [3264] sent 6224427974 bytes  received 1084 bytes  total size 450206222593

The transfer speed is here is only 3601058.18 bytes/sec (~3.4 MB/s)

Any ideas why rsync is dramatically slower?

Offline

 

#9 2008-09-10 15:29:47

fordem
Member
Registered: 2007-01-26
Posts: 1938

Re: Transfer Speed between HDs

A couple of things - first - the time taken to copy a single 2GB file will always be less than the time taken to copy 2x1GB files, which will be considerably less than the time take to copy 200 x 10MB files, which in turn will be less than it takes to copy 2000 x 1MB files, even though the quantity of data copied remains constant - for each file transferred the disk must update block allocation tables, etc, so the heads must swing back & forth and time is lost.

Second - I don't think rsync is just copying files - it needs to determine which files (or portions of files) needs to be transferred - I use Microsoft's Synctoy which I believe does an essentially similar task, and have watched it spend over an hour doing "analysis: before it takes perhaps 60 seconds to do the actual sync.

Offline

 

#10 2008-09-10 16:03:39

DaveN
Member
Registered: 2008-01-12
Posts: 21

Re: Transfer Speed between HDs

I agree that it is probably a s/w issue with rsync, but unfortunately I can argue against most of the points fordem mentions.

To clarify, most of the files I'm transferring are compressed backups of 455MB in size.  They are also "new" files, so there should be little or no comparison required.  This is the exact listing of what was transferred (26 of 20025 files):
2008/09/02 02:05:27 [3264] building file list
2008/09/02 02:05:28 [3264] cd..t...... ./
2008/09/02 02:05:28 [3264] >f.st...... ffp.log
2008/09/02 02:05:28 [3264] >f.st...... fun_plug
2008/09/02 02:05:28 [3264] cd+++++++++ .bootstrap/
2008/09/02 02:05:28 [3264] >f+++++++++ .bootstrap/dmesg.out
2008/09/02 02:05:28 [3264] >f+++++++++ .bootstrap/part.conf
2008/09/02 02:05:28 [3264] >f+++++++++ .bootstrap/part_table.sh
2008/09/02 02:05:28 [3264] >f+++++++++ .bootstrap/read_me.txt
2008/09/02 02:05:28 [3264] >f+++++++++ .bootstrap/setup.sh
2008/09/02 02:05:28 [3264] >f+++++++++ .bootstrap/usb-storage.ko
2008/09/02 02:05:28 [3264] >f+++++++++ .bootstrap/usbmount.sh
2008/09/02 02:05:28 [3264] cd..t...... Backup/
2008/09/02 02:05:49 [3264] >f+++++++++ Backup/Documents12.tib
2008/09/02 02:07:59 [3264] >f+++++++++ Backup/Photos140.tib
2008/09/02 02:10:09 [3264] >f+++++++++ Backup/Photos141.tib
2008/09/02 02:12:18 [3264] >f+++++++++ Backup/Photos142.tib
2008/09/02 02:14:27 [3264] >f+++++++++ Backup/Photos143.tib
2008/09/02 02:16:36 [3264] >f+++++++++ Backup/Photos144.tib
2008/09/02 02:18:46 [3264] >f+++++++++ Backup/Photos145.tib
2008/09/02 02:20:55 [3264] >f+++++++++ Backup/Photos146.tib
2008/09/02 02:23:04 [3264] >f+++++++++ Backup/Photos147.tib
2008/09/02 02:25:14 [3264] >f+++++++++ Backup/Photos148.tib
2008/09/02 02:27:23 [3264] >f+++++++++ Backup/Photos149.tib
2008/09/02 02:29:33 [3264] >f+++++++++ Backup/Photos150.tib
2008/09/02 02:31:42 [3264] >f+++++++++ Backup/Photos151.tib
2008/09/02 02:32:17 [3264] >f+++++++++ Backup/Photos152.tib
2008/09/02 02:32:43 [3264] >f+++++++++ Backup/Programs18.tib
2008/09/02 02:33:37 [3264] >f+++++++++ Backup/WinXPHome12.tib
2008/09/02 02:34:15 [3264] cd..t...... usb-storage/
2008/09/02 02:34:15 [3264] >f.st...... usb-storage/snapshot.sh

The .bootstrap, ffp, and usb-storage files are tiny text files, and I agree these will take longer per byte to transfer.  The files in the Backup directory are the compressed backups.  From the timestamps you can see that the large files (e.g. Photos147.tib) take ~2:10 to transfer - compared to 20 seconds using "time cp".

On a night where no changes have been made to HD_a2, the "transfer" takes approximately 30 seconds.  This I can assume is the overhead to generate the file list on both drives and compare the size / timestamp / attributes to determine nothing has changed.  In the example I posted earlier the total time taken was just under 30 minutes.  Although significant, 30 seconds should not cause a 10 fold slowdown.

Any thoughts / disagreements with my reasoning, or ideas for further debugging?

Offline

 

#11 2008-09-10 16:11:26

bq041
Member
From: USA
Registered: 2008-03-19
Posts: 709

Re: Transfer Speed between HDs

The next question I would ask is, "Does rsync look internal to the archive (compressed) file to look for changes internal to it?"  If it does, it will significantly slow it down.  Try rsync with a large, non-archive file and see if it takes the same amount of time.  You should be able to find a video file large enough to try.


DNS-323     F/W: 1.04b84  H/W: A1  ffp: 0.5  Drives: 2X 400 GB Seagate SATA-300
DNS-323     F/W: 1.05b28  H/W: B1  ffp: 0.5  Drives: 2X 1 TB  WD SATA-300
DSM-G600   F/W: 1.02       H/W: B                Drive:  500 GB WD ATA

Offline

 

#12 2008-09-10 16:14:18

fonz
Member / Developer
From: Berlin
Registered: 2007-02-06
Posts: 1716
Website

Re: Transfer Speed between HDs

bq041 wrote:

Does rsync look internal to the archive (compressed) file to look for changes internal to it?

No, it doesn't.

I'd ask for the exact rsync command. There are options that can slow down rsync dramatically.

Offline

 

#13 2008-09-10 16:28:08

DaveN
Member
Registered: 2008-01-12
Posts: 21

Re: Transfer Speed between HDs

Try rsync with a large, non-archive file and see if it takes the same amount of time.

I'm not sure I understand.

All the files listed like this: ">f+++++++++" did not exist on HD_b2 before the transfer so there can't be block level comparison.  Also, the archive (compressed) file is a .tib (True Image Backup) type - which is a proprietary that only (as far as I know) Acronis programs can decode.  I just wanted to stress the point that the data is similar to random bytes (which means they can't be easily compressed during the transfer).  These conditions are similar to a large video file in my mind.

I'd ask for the exact rsync command. There are options that can slow down rsync dramatically.

The exact command is:
$ffp_path/rsync -aix --stats --link-dest=$dstpath/current --delete --log-file=$logdir/rsync.log $srcpath/ $dstpath/$date/
I understand that --delete causes some performance degradation, and will try a test without it (after work) - any other ideas.

Offline

 

#14 2008-09-10 16:59:18

fonz
Member / Developer
From: Berlin
Registered: 2007-02-06
Posts: 1716
Website

Re: Transfer Speed between HDs

DaveN wrote:

$ffp_path/rsync -aix --stats --link-dest=$dstpath/current --delete --log-file=$logdir/rsync.log $srcpath/ $dstpath/$date/

Looks ok. The candidates would have been -c, -z, -e ssh.

Offline

 

#15 2008-09-10 19:43:09

DaveN
Member
Registered: 2008-01-12
Posts: 21

Re: Transfer Speed between HDs

I did a test and it looks like the rsync options have no effect on the long copying time (I'm using rsync version 3.0.3).

I created a new empty directory (/mnt/HD_a2/temp/) and copied a single 455MB file into it (WinXPHome6.tib).

I then created another empty directory, this time on the second drive (/mnt/HD_b2/temp/) and timed various methods of copying the file (deleting the file after each transfer so the destination was empty in all cases).

These three rsync commands:
/mnt/HD_b2/temp # time rsync -aix --stats  --delete /mnt/HD_a2/temp/ .
/mnt/HD_b2/temp # time rsync -aix /mnt/HD_a2/temp/ .
/mnt/HD_b2/temp # time rsync /mnt/HD_a2/temp/WinXPHome6.tib  .
each returned statistics similar to this:
real    1m 43.28s
user    0m 49.03s
sys     0m 51.82s

The cp command was around 5x faster:
/mnt/HD_b2/temp # time cp /mnt/HD_a2/temp/WinXPHome6.tib .
/mnt/HD_b2/temp # time cp /mnt/HD_a2/temp/* .
With times similar to this:
real    0m 19.73s
user    0m 0.35s
sys     0m 16.19s

The situation is no better when only one disk is involved.  A cp of the same file from /mnt/HD_a2/temp to /mnt/HD_a2/temp2 took approximately 30s, while rsync took 1m 40s.

Using top, cp seems to use about 85% of the CPU during the transfer, while rsync maxes out the CPU with two processes each using approximately 50%.

Can anyone else confirm these timings on their DNS-323, or provide results from a similar test on a linux box (I'm running XP so can't try this myself).

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2010 PunBB