Posted
by
Cliff
on Thursday June 29, 2006 @11:48PM
from the maximizing-bandwidth-usage dept.

Milo_Mindbender asks: "I've got a pretty common problem: copying a ton of files from an old Windows XP computer to a new one. After noticing how long transfers were taking over my 100mbps Ethernet, I hooked up a IEEE1394/Firewire cable and things were much faster. Strangely though, Windows is still only using about 10% of the cable's 400mbps bandwidth. Does anyone know any tips/tricks for speeding this up or any Shareware mass-file-copy tools that would be faster than Explorer/file sharing? Right now, the older machine is setup with Windows file sharing and the new machine is copying from it, neither machine is using much CPU and the disks are nowhere near their max speed. The number and size of the files might be what's slowing it down, since it's gigabytes of files in the 100-200k size range."

Nothing to do with compression (although that may help); it's about one big file being faster to copy than lot's of small files that add up to the same size. Even if you zip them up without compressing (it'll be an option somewhere) then this will help.

Another thing is that even without looking at third party tools, you should be using XCOPY in preference to windows explorer.

There is an Exchange server utility that is optimised for moving gigantic files very fast; doubtless you can find similar programs about.

I haven't used xcopy in a while. Certainly not on an XP machine. The last time I used it was on a w98 box and it truncated all of the filenames to 8.3 format (7~.3 really). Is there now a version that supports long filenames?

Robocopy is approximately a hundred trillion trillion trillion times better than xcopy.

To put that in perspective, you would need to weld fourteen quadrillion VW Beetles end to end, then use the resulting Beetle Bar as a lever and an object with the displacement of eleven million Libraries of Congress as the fulcrum in order to give xcopy the same Windows command-line file copying power as Robocopy.

Robocopy has nice features, but it's slow. I've started using HAS [heatsoft.com] instead. It costs, but It's got more features, a nice GUI if you happen to like that, and most importantly, it's about 3x faster on my servers than Robocopy.

There is an Exchange server utility that is optimised for moving gigantic files very fast; doubtless you can find similar programs about.

Perhaps you mean ROBOCOPY.EXE (RobustCopy)? It is a tool in the Wind2k/2k3 Admin toolkit designed to do just what you describe: Faithfully, accurately, (and efficiently) copy large files from one place to another.

The point is not to make them smaller - it is to make them all one file. Of couse, smaller is better too.I wonder how the microsoft backup too would work in this situation. Backup to a file, copy the file, then restore from it. I've done it in the past, though not for the same reason, and it's worked...not sure about speed.

Clearly, moving the disk would be the best option. I often use a firewire Wiebetech Drive (useful to have around if you often find the need to do such things) dock to perform a similar ta

Have you tried to archive/compress them first [gzip/zip/etc], then move the big file over? Lots of small files take longer to move than fewer larger files.

Is it just possible that you are confusing bits with bytes per second? 400 Mb/s is about 40 MB/s (or pretty close, especially as you rarely the full theoretical 50 MB/s that you would think this would equate to).

It would be faster to 'tar' directly to the target machine. Tar will stream the output and is probably much more efficient than Windows Explorer.Also, booting the machine from a Linux boot CD and mounting the drive read-only and using tar to move the files is probably the fastest method. I do this all the time to recover/backup machines at work.

The problem with doing that is Windows can detect the "magic" folders... Mods: If you don't know what "magic" is, please mod some other comment. Thank you.

Do you mean the software named "Magic Folders" [google.com]? Or perhaps you have some kind of Folder of Holding [wikipedia.org] with compression created by a high-level Magic User. Most likely you mean the Special Folders [wikipedia.org] that are used by Windows, but then again you may just be spouting about something you actually know little about.

Or maybe you should just explain yourself and not flame the mods... You might even get modded +Insightful or +Informative then and you would have the advantage of explaining your term to the person you were answering - thus being genuinely helpful.

Yes, I meant the special folders. Thanks for the link. However, it just seemed simpler to give a warning. Doing the file operations over the network obviates all concern about stray magic.If you've got a system you don't care about, and another system disk you were planning on wiping anyway, install the second disk and try various copy/delete/move operations between the original special folders and the newly installed ones on the second disk. Use Explorer, magic is not quite as strong using xcopy from the c

BTW, I learned the term "magic" from the Microsoft tool "tweakgui". I didn't invent it.

I looked in TweakUI and it calls them "Special Folders" as well. My point is: Be careful about how you present things that you may only have cursory knowledge of here on Slashdot. I was being funny about it, but there are planty of users out there who will ream you for bad information. Instead of being authorative and telling the mods what to do, you could have replied in the form of a question such as "You could try, but won't windows have problems with the magic folders?" or something like that. Further, you could disclaim being an authority and just post something along the lines of "I think that...".

Ok, I'm done being a slashdot post nazi now:D

From my experience, XP stores the hard locations (ie: c:\Documents and Settings\BrynM\My Documents") for the special folders it needs in the registry. I've never had a problem slapping a previously used drive into a machine to copy files (I did this exact thing to recover files after and IDE failure that was corrupting NTFS just a couple of weeks ago). If you've had problems or know of them, then please post that.

Mods: If you don't know what "magic" is, please mod some other comment. Thank you.

Normally I avoid posting on the techie parts of slashdot, as I know approximately fuckall in the power/knowledge sense when it comes to the esoteric hardware and coding problems that are usually discussed. I just read, hopefully learn something, and avoid sticking my foot in my mouth. But, there was something about this that really rubbed me sideways in an uncomfortable "AAAHHAGH, you're rubbing be with stingling nettles!!

Sorry, I was just trying to avoid karma burn from mods who might think I was being a smartass about Microsoft products. How's that working for me?:)I replied further upthread to the guy who knew what I was talking about. What I *really* hoped would happen was that a few hackers would try to find out what I (and Microsoft) meant by "magic", but on Googling right now, it is not as obvious as it used to be in 1995, when the magic was first conjured. Here be dragons:

Special folders don't exist on the second drive. Only the real folders do. So your desktop folder is still in a folder on the drive, you just have to know where to look. In this case, that's Drive:\Documents and Settings\User\Desktop. The virtual folder itself ceases to be where you expect it to be, as Windows is not searching your secondary drive for them, but it continues to be where it is.If you want to know where a folder really is on the drive, just do a search for a file you think is in the drive.

As for me, I'm never putting an old system disk on a new system as a second disk. After what happened last time.

Aha! You did have problems. Please post what happened so the rest of us may avoid it. Even if you weren't sure what was going on when it happened, you might get replies that help clear things up. I hope you don't think I'm nitpicking you, I'm just trying to help you and I have the Karma to burn on helping other posters (modded to oblivion for being offtopic). Believe it or not, I've learned quit

Well, then don't put anything you want to transfer between drives in the recycle bin.

I've done this type of copy--physically move the source drive into the computer with the target drive--many times with Windows 98, 2000, and XP. I've copied files and folders to and from 'My Documents', 'Desktop', 'Application Data', and other special folders. I've never had an issue with this approach.

Non login requiring link here [kbalertz.com] Article seems to imply that only 1394b (FW800) controllers are affected. Still, limiting to S100 is a pretty dumb move on MSFT's part (insert tinfoil rant about MS being in league with Intel over FW vs USB2 here).As a side note, I use an external FW drive on my HP laptop running XPSP2 Pro, and I can pull >35MB/s from it. I do not have any machines with 1394b so I can't confirm that there is an issue with that, but my 1394 port is definitely not running at S100.

This being slashdot, I'm sure someone will correct me if I'm wrong, but your hard drive is most likely not fast enough to receive the full 400 Mb/s stream from the firewire. The fastest SCSi drives are 320Mb/s and that's not sustained.

To get full firewire transfer goodness, you need a raid of fast drives, on both systems.

"Modern? This is from an old computer to a new computer - and those speeds would be for consecutive data. Which I suppose is fair, given that the user defragmented completely. But an IDE drive's speed is far less 400mbit/s."

They're just about as fast as SATA drives, since ATA-100 is still faster than the sustained speeds of the drives (100 is megabytes in this case). This is why ATA-133 never caught on -- it's faster than any of the drives you'd connect it to. It wasn't SATA's speed that made it popular, it's the numerous other advantages (thinner cable, cheaper, hotplug, etc).

Acuatlly hardrives both IDE/EIDE, and normal scsi are measured in MB/s note the capital B meaning BYTEs not BITs. External communication channels are measured in bits/s. Only the new SATA, and SerialSCSI drives are bits/sec. If you calculate it out, a 3.0Gb/s SATA drive pulls about 375MB/s burst rate. Its marketing manipulation.I'm not sure why you're transfers aren't that fast, for me firewire from my external harddrive is just as fast and getting stuff off my fileserver *6 disk raid 0*. I have yet to

It is remarkable that a/. user, who should have some measure of tech-savvy, mistakes megabits per second with megabytes per second. This is pretty basic stuff, kiddies. Firewire (the IEEE1394A type) tops out at 400 Mb/s, which is 50 MB/s. Eight bits in a byte, remember? SATA is 150 MB/s or 1.2 Gb/s. SATA-2 doubles that. Ultra320 SCSI is 320 MB/s or 2.56 Gb/s. The newer IEEE1394B is 800 Mb/s, but you will only typically find that on a Mac.

If your not maxing out your connection, any number of things could be limiting the speed of the transfer; cpu, bus speed, harddrive performance etc. Use a system monitoring utility to see what's at 100% utilization, and then upgrade the part. Transfering larger files that are sequential on the disk will also help.

Since the poster already mentioned CPU, I suspect they know enough to look at the basic utilization stats. Most likely, however, the limiting factor is either the hard drive speed or the fact that Windows explorer is a piece of crap.

What is the manufacturer of Firewire controllers in the computers you are using? VIA controllers are usually not the best Firewire controllers. Texas Instruments controllers are usually better. For that matter, depending on the situation try compressing the files. Also, do not depend on time remaining in Windows I have found it wildly inaccurate at times. Windows seems to estimate the time remaining to be way too high, so YMMV, literally.

That's not a FireWire controller. Oxford makes bridge chipsets from FireWire to ATA. A FireWire controller generally refers to the bridge between an peripheral bus and FireWire, e.g. PCI to FireWire. My advice: TI chipset. Accept no substitutes. In particular, though, avoid NEC from what I've read.

As for the performance problems, if you have SP2 and FW800 ports (or a controller that's FW800-capable under the hood but uses FW400 PHYs), make sure you install the FireWire hot patch [microsoft.com] from Microsoft or Fir

Your file size, and disk seek time, are the problem. Lets say your drive has a 5ms seek time (that's pretty damn fast). writing each file actually requires three writes: to the file allocation tabe, to the directory, and the contents of the file itself. Assuming the writes take another 5ms, that's 20ms per file. that limits you to 50 files per second. At 200kiB per file that's about 10 megs per second.

First off, I'm not sure NTFS has a file allocation table. But more relevantly, there are two filesystems I know of that do lots of small files really well: Reiser4 and XFS. At least in the case of Reiser4, Microsoft could license it.The key feature here is lazy allocation. It not only keeps your drive from getting as fragmented, it also means that when it does decide it has to write, it's writing all the files at once, and can make intelligent decisions like, write all the metadata out, then write all t

Windows (XP at least) doesn't buffer writes to removable media by default. You can enable that feature by going into Disk Administrator, finding the firewire drive in the bottom-right quadrant, right-clicking on the grey label and picking properties. On the policy tab you can opt to have Windows buffer writes at the price of having to "eject" the disk before unplugging it.

Well, I could think of a lot of ways to speed it up under Linux using various combinations of rsync, and... well, really just rsync. See if there's a good rsync clone for Win32 that will preserve your precious file attributes. Even running it under cygwin may be better in the long run, especially because inevitably (speaking from experience) your large copy will be interrupted halfway through by an "unreadable file" or some such rubbish, and you'll find yourself having to try to fix it and start the copy all over again from the beginning, or else trying to just transfer the remaining directories you think you're missing.

Using cygwin's rsync via ssh: (after running "ssh-host-config" on your new box and setting a "passwd" as Administrator )

will do the trick, and you can just keep running it over and over again until all the files are mirrored. It will take a long time to buld a list of all the files you need to transfer, but it will only tranfer the files you're missing, and will attempt to do some compression (which should help because you're more IO bound than CPU bound, but just remove the -z if your CPU is pegged). Plus, you'll find rsync & scp damn useful for many other common tasks you take on.

The bottleneck is probably your windows filesystem, and cygwin's extra abstraction layer will only make that worse. But using rsync under cygwin means you only have to transfer the files once - which will be a much bigger time saver than trying and failing to do the entire transfer several times.

If you were doing this often, I'm guessing you might see an improvement if you defragment your old drive first, but you obviously don't really want to waste time on that for a once and final transfer.

Also, the Windows TCP/IP stack is typically tuned for 2 - 10Mbps links. Here's some information on how to fix that: http://rdweb.cns.vt.edu/public/notes/win2k-tcpip.h tm [vt.edu] It's mainly geared towards improving throughput on high-capacity WAN links, but parts are also relevant to achieving decent performance on 100Mbps+ networks as well. Also remember that a lot of network drivers suck too and are incapable of pushing the throughput even to a fraction of its rating... that's been a factor too, especially on cheap windows crap. An updated NIC driver/might/ get your net transfer to catch up with your firewire transfer somewhat.

Since you're getting 40Mbps / 400Mbps firewire, you're really not doing too bad. Converting to bytes, 5MB/s is a decent fraction of the 20MB/s to 50MB/s raw speed of your older hard drives, and actually seems reasonable given that you're sending lots of small files and not a few big ones where you can actually make good use of your drive's readahead cache.

Strangely though, Windows is still only using about 10% of the cable's 400mbps bandwidth.

Are you sure you aren't confusing mbps [wikipedia.org] with MBps [wikipedia.org]? 400mbps is equal to 50 megabytes per second, and "12.5% of the cable's bandwidth" sounds suspiciously like your description of the problem, "about 10% of the cable's bandwidth".

Are you sure you aren't confusing mbps with MBps? 400mbps is equal to 50 megabytes per second...

Are you sure you aren't confusing mbps [wikipedia.org] with Mbps [wikipedia.org]?

Last I checked, 400mbps is equal to 0.4 bytes per second. I remember getting speeds like that back in the days of dial-up. Like back in the day when you picked up the phone and read off ones and zeros to your friend on the other line as he copied your fortran program by punching holes in his punch card. Oh yeah, and uphill both ways. In the snow.

I was about to post in a similar vein, wondering how 10% of 400 Mbps can be faster than 100 Mbps, but after reading your post it makes sense; the question submitter is saturating the LAN connection and getting ~10 MBps, and is also saturating the firewire connection thinking it can do faster because he is expecting it to go 400 MBps.

First of all, I'm confused by what you mean when you say it's only using 10% of bandwidth. 400Mbps, means you're gonna get something like a max of about 40 Megabytes per sec transfer. (remember, 8 bits per byte, plus some overhead) Are you seriously only getting 4 MB/s?As far as copying faster. You might want to try robocopy from the Windows 2003 resource kit [microsoft.com] or xxcopy [xxcopy.com]. I've tried xxcopy and it seems to buffer things well, such that I can do a sustained 25 MB/s or so when backing up files to my 500 Gig

I did a freelance gig back in '98 where I had to use a Mac (an 8600/300 w/64 megs of RAM). It took well over 20 minutes to copy a 17 meg file from one folder on the hard drive to another. 20 minutes! At home, on my Pentium Pro 200 running NT4, the same operation would take about 2 minutes.

Well, I figured I'd better make sure I referenced something that explicitly says it's a joke. You know Mac people...we'd end up with 700 posts about how "Well, yeah, but that was before Mac OS X" or how they don't have the problem and I'm making it up, etc., etc.

There is a problem in Windows XP SP2 with firewire transfer. Albeit that it could be numberous small files creating problems but it should be faster than 100mbps ethernet. Try this blog regarding Windows XP SP2 Firewire Slowness [hishamrana.com] for a link to the KB and a links to few other work arounds or just go direct to the KB article [microsoft.com].

Why not just plug in the old machine's hard disk to the new machine? Leave the lid off, have an IDE ribbon cable dangling over the side of the case, prop the disk upright with a chipped mug and a spare copy of Tanenbaum's Minix book... this is the correct old-school approach to moving data and many times faster than anything involving slinging a cable between the two boxes.

Dude, although this makes sense, it's also mighty inconvenient, even for a hardware geek (which I am). Firewire would do the trick much better I think. Your method involves opening up both PCs, connecting the ribbons to the other computer. Firewire method involves taking a cable, plug it in to the ports on both machines, and it's ready to go. I think simplicity wins personally, IMHO.

In Windows XP or in Windows Server 2003, you can change the write cache policy to optimize write performance for a disk device and for data safety. You can select either the Optimize for quick removal option or the Optimize for performance option in Device Manager.If the Optimize for performance option is selected, data that is written by an application is cached by the operation system, and lazy write is used for the cached data.

I have another post in this article describing my speed issues as well. I've also tried the setting you suggested in the past and that had no noticable change at all. Maybe that is useful for short bursts with a few files. The bottleneck always seems to be how Windows treats or handles large amounts of files. It might not even be the amount of files but the latency or overhead involved with opening and closing a file multiplied by the number you have adds up to significant delays. Anything above 10k or

I use NSCopy for any decently-sized Windows File Sharing file transfer - it can copy a whole directory tree and throttle the speed down or up (to maximum "plaid") Just google for it, it's free.If you want more speed, I'd say get FireZilla (an FTP client) and FireZilla Server (an easy to use FTP server), both open source and free. Set up the server on the "source" computer, and download as fast as you can! It will use the bandwidth much better.

10% of firewire 400 is 40mbps. fast ethernet is more than that even with the collisions. So I dont know how you got faster transfers with firewire.One option is to just pull the drive from the old machine and use it as the slave drive. I use this when moving large files. Another option is to have a gigabit card, now around $14 everywhere. Newer PCs already have gigabit cards. Just use a crossover cable if you wont buy the (also cheap) gigabit switch.

Agreed 100%. Any time I need to transfer massive amounts of files (and physically moving the hard drive from one machine to another is not an option), Filezilla never lets me down. Server on one side, client on the other... they're a quick setup and just as easy to install as remove when they're no longer needed. Its amazing how much data can fly through a router that's actually working it full capacity.

It might be true if you are doing a sector by sector read, and then only if you have platters with high areal density (ie extremely recent drives). Windows file copy; however, does not optimize its disk access in any way and so you have lots of delays while moving from file to file. So, yeah, Firewire (400) might be a bottleneck if you are doing drive imaging or copying lots of very large files, but sustaining ~50MB/s during random access is still a pipe-dream on normal consumer drives at this point in time

Just because you are gay, Anonymous homophobe Coward, and you recommend Linux, that doesn't make it a "fag's OS". It does make you a repressed "fag" cruising Slashdot for humiliation, regardless of your OS choices.

And maybe you're an Anonymous Coward who can tell the difference between an OS war flamefest response, and a response actually pointing out that the OS is the key to the solution. Even pointing out how to keep the old OS, pointing out how the old HW is also the problem.You know, an Anonymous Coward actually able to understand the info in a post, rather than just jumping into OS flamewar mode when seeing a point about OS choice affecting the task.