Monday, March 21, 2011

File Systems Vs Transfer speed for USB drives

My last visit to computer store was for USB backup hard drive. There are many models and sizes there. Some of them have USB3.0/2.0 interface. But actually I don't understand why need to make the USB3.0 interface with slow and small 2,5'' SATA drive. I believe it is a marketing lead. My choice was SAMSUNG G2 Portable Cobalt-Black 640Gb External Hard Drive (model: HX-MU064DC/GB2)
In this article I'm going to test it with MacOS 10.6.6 and check the transfer speed for it with different file systems (exFAT, Mac OS Extended and Mac OS Extended Journaled) For my tests I'll use the free utilities. One of them is UNIX `dd` the other one is `MMBench` which displays the speed of you hard drives and recording devices. OK, Lets do it. 
First of all I connect the G2 to computer and format it with Mac OS Extended Journaled.
The G2 package show us that this drive box is compatible with Mac OS and Windows operating systems. But not with Linux.
As I noted with Mac OS this drive is smart enough to fall into sleep mode after 5 minutes of non activity and power off the top LED plus park the heads if you unmount the drive from your system.
The first test with `dd` command shows:
$ dd if=/dev/zero of=/Volumes/SAMSUNG/sTest.img bs=8k count=256k
262144+0 records in
262144+0 records out
2147483648 bytes transferred in 57.358373 secs (37439759 bytes/sec)
It writes 2Gb file on disk and shows average writing speed around 35,71 Mb/sec
Check it with MMBench program and drop onto disk the same file via Finder. See screenshots below. The read maximum speed even faster recording speed.
That is result with Mac OS Extended:
$ dd if=/dev/zero of=/Volumes/SAMSUNG/sTest.img bs=8k count=256k
262144+0 records in
262144+0 records out
2147483648 bytes transferred in 56.367256 secs (38098070 bytes/sec)
It shows average writing speed around 36,33 Mb/sec. Hmm, it is little faster.
That is result with brand new MS exFAT filesystem:
$ dd if=/dev/zero of=/Volumes/SAMSUNG/sTest.img bs=8k count=256k
262144+0 records in
262144+0 records out
2147483648 bytes transferred in 55.282079 secs (38845928 bytes/sec)
It shows average writing speed around 37,05 Mb/sec. It seems faster file system. Our winner.

As result of these tests we see that average read/record speed is faster for exFAT and slower for Mac OS Extended Journaled. The tip: "don't use journaled file systems on external drives" looks correct.
In my case I need cross platform file system for Linux, Mac OS and Windows. So, I chose exFAT. If you need to save Mac OS permissions and no need cross platform solutions then Mac OS Extended is OK. The Partition Map should correspond to File systems type - Apple Partition Map to Mac OS file systems and Master Boot Record to MS file systems like exFAT. And never use GUID partition Table for external drives. Use it only for internal system drives. I don't show the NTFS and FAT32 files systems cause it is outdated or not well usable with MacOS/Linux. Here is screenshots:
Read HFS+Journaled
Read HFS+
Read exFAT
Write HFS+Journaled
Write HFS+
Write exFAT

1 comment:

Anonymous said...

very useful!