Archive

Archive for August, 2010

How fast is your Net?

August 27, 2010 Leave a comment

So, as I have been trying to make a copy of my ReadyNAS NV+ data, I decided to take another look at my overall home network bandwidth between computers.

In a past survey of TCP benchmarking tools, I came across an excellent TTCP utility. Its simple, its easy to compile under Unix variants including MacOS, and there’s a pre-compiled binary for Windows platforms as well.

I thought I’d jot down a few notes before I forget them and have to figure it all out again.

First, lets remind ourselves of the maximum bandwidth for various types of connectivity, this table sums it up.

Medium Gbit/sec Mbit/sec Mbytes/sec bytes/sec
1 GigE 1 1024 ~128 134217728
Fast Ethernet 100 ~12 13107200
802.11g 19 ~2 2490368
802.11n 160 ~20 20971520

A couple of notes about the wireless specifications –

802.11g – Operates at a maximum physical layer bit rate of 54 Mbit/s exclusive of forward error correction codes, or about 22 Mbit/s average throughput.

802.11n – Operates at a maximum raw data transfer rate ranging from 54 Mbit/secĀ  to 600 Mbit/sec. Actually achieved speeds range from 130 to 160 Mbit/sec.

Ok, so now on to some quick reference configurations for TTCP and some of my real world numbers.

TTCP Parameters Bytes Sent Computed Duration Actual Duration Bandwidth
-l 65536 -n 2048 134217728 1 sec @ 1Gbit
-l 32768 -n 4096 134217728 1 sec @ 1Gbit
-l 16384 -n 8192 134217728 1 sec @ 1Gbit
-l 32768 -n 76 2490368 1 sec @ 19Mbit
-l 16384 -n 152 2490368 1 sec @ 19Mbit
-l 32768 -n 2280 74711040 30 sec @ 19Mbit 27.1 21.02 Mbit/sec
-l 16384 -n 4560 74711040 30 sec @ 19Mbit 27.8 20.45 Mbit/sec
-l 65536 -n 122880 8053063680 60 sec @ 1Gbit 68.2 900.63 Mbit/sec
-l 32768 -n 245760 8053063680 60 sec @ 1Gbit 68.3 899.59 Mbit/sec
-l 16384 -n 491520 8053063680 60 sec @ 1Gbit 133.3 460.64 Mbit/sec

For my tests, I was transferring between a Windows 7 Desktop and a Apple Mac-Mini with two switches between the two. All the numbers look pretty good in my book. For the wireless tests, I flipped off the Ethernet interface on the Mac-Mini to force it though the AirPort connected to an AT&T U-Verse Residential Gateway (which is 802.11g.)

Advertisements
Categories: Computing

ReadyNAS to Windows Backup

August 27, 2010 1 comment

I’ve been having some problems with my ReadyNAS NV+ unit recently that has me worried the hardware is about to fail, so I’ve been trying to copy everything as efficiently as possible to a spare disk on my Windows 7 desktop.

My first attempt was to use the Microsoft SyncToy, it was relatively efficient but had a couple of problem. The most serious of which is that it appeared to cause the NV+ to freeze occasionally. The other annoyance is, similar to using Windows Explorer to copy, timestamps on folders are not preserved. So I pitched it.

This didn’t leave me with many options, so I tried falling back on the tried and true Rsync utility as Rsync is one of the utilities included with the ReadyNAS firmware, and is available in various forms on Windows including as part of the Cygwin package.

My first thought was rsync-over-ssh, using a relatively compute-lite cipher. I had previously checked out ciphers for SSH, and had found the blowfish was about the least expensive, so I gave it a shot.

It, unfortunately, did not perform well at all. Running top on the NV+ I could see a lot of the CPU was taken up by SSH. ‘Nuff of that.

Ok, so next attempt, the ReadyNAS firmware comes with the Rsync daemon. That should be a pretty optimal experience with a client and server designed for each other. Brrrt! This still suffered from some pretty poor transfer rates.

But all is not lost, I attempted what I figured would give me the worst performance, mounting a share through CIFS and then using Rsync to copy from the CIFS share to the local disk. Generally networked filesystems suffer from some overhead themselves, so putting Rsync on top of that couldn’t be good.

To my surprise, it worked quite well. Ok, so mainly it worked quite well for copying large files, producing transfer rates between 20-30 MB/sec, and consuming about .5 Gbit/sec of network bandwidth. Bingo!

And the bonus, file and folder permissions and timestamps are preserved pretty well. I did run into some issues at first with Rsync (or perhaps Cygwin) having problems setting permissions on a subset of files. It appears to have to do with how Cygwin tries to map POSIX file permission to Windows ACLs, in the end I was able to resolve this by running Rsync as Administrator on Windows.

So, before I forget and have to do it all again, here’s some notes on what I did.

First of all, when you kick of a Cygwin Bash Shell, right click on the Start Menu entry and then select Run as Administrator.

The rest is just mapping a ReadyNAS CIFS share to a drive letter, then firing off an rsync, for example:

% NET USE Q: \\\\READYNAS\\Share
% rsync -rlptDWiv --whole-file --inplace \
  --delete-during --delete --stats --progress \
  /cygdrive/q/  /cygdrive/e/Share/
Categories: Computing