February 26, 2007

There's Work, and Then There's Projects


Here's what I've been up to in the three months since my last post:

Work - Lulu has its ups and downs like any place. I've spent the past few weeks learning Javascript in some depth, and MSIE6 is now officially evil. And of course, there's plenty of PHP code to wade through as well.

My Projects™ - Every once in a while I'll get an idea that I need to take on a big new project, but of course they just keep adding up because it takes longer to finish them than to start them. I still haven't processed the photos from the sightseeing portion of last August's trip to Peru, and I only recently ingested all the video footage I shot on that trip. Fro these, I hope to create an additional photo gallery and three videos (general sightseeing, mission trip, and a funny video about Machu Picchu). I also need to do a video for a friend's wedding over a year ago (sorry Isaac!) and another one for my brother's wedding (which can be excused by the fact that my uncle-in-law hasn't had time to get me all the footage yet). Add to these a rather complicated tax return, a motorcycle that just doesn't want to be repaired, and the usual housekeeping, and I'm booked solid until 2010. And I just remembered that I'm supposed to redesign a website by Wednesday.

Anyways, one cool thing people might be interested in is the video editing setup I've been putting together. This consists of a storage server running Fedora Core 6, and a MacBook Pro running OS X with Final Cut Studio.

The storage server is cool because it has 2TB of RAID-5'd storage across 5 disks. I played around with various filesystems before going with ext3 (xfs and jfs were both faster but I really don't trust them, and ext4 should help performance a lot). There's also a 200GB LTO-2 tape drive for backup - I got a really good deal on this on eBay, and it gives me virtually unlimited archival storage at only $0.15/gigabyte.

The MacBook Pro is a refurb 15.4" Core2Duo system. I upgraded it to 2G of RAM (unfortunately, the 4G limitation of 32-bit systems means that prices of >= 2G DIMMs are insane).
The MBP only has 120G of disk space - I am looking forward to the release of Fujitsu's 300GB 2.5" drive, which should give me room to install Linux and Windows as well, and a speed-up in transfer rates as well. The system runs fine and I have no complaints other than the fact that OS X is not open source :)

Speaking of transfer rates, here are some interesting stats:

  • After enabling jumbo frames, raw GbE network throughput between the storage server (hereafter called 'monolith') and the Macbook Pro (hereafter called 'slab') is in the neighborhood of 110-120 MB/s

  • The disk array in monolith can sustain a transfer rate of just under 80 MB/s

  • The ext3 filesystem overhead reduces that to 65-70 MB/s

  • Samba talking to the SMB client implementation in OS X reduces that to 39 MB/s

  • If you use the default OS X NFS mount options, you'll get something like 3 MB/s


I'm not kidding on the last point there... MacOS X has default NFS options that are really aweful for performance. There are some ways that you can use to bring it up to a decent level ('decent' as in "on par with SMB", which is not that exciting when the server can theoretically do a lot better).

First step in improving MacOS X NFS performance: edit /System/Library/StartupItems/NFS/NFS and change the 'nfsiod -n 4' line to 'nfsiod -n 16' or even 'nfsiod -n 32'. (Reboot your system after, or just kill & restart nfsiod.) This will give you maybe 3-4x the transfer rate.

Switching to NFS-over-TCP will easily double your throughput as well, but the really critical factor using either TCP or UDP is to bump the rwsize up to something like 64k. This means that the magic line for mounting would look something like:

mount_nfs -o tcp,rwsize=65536,readahead=16 monolith:/repo /mnt/monolith/repo

The result should be roughly 35-40 MB/s of throughput (assuming jumbo frames, GbE, and no other bottlenecks). I say "should be" because I can't replicate that benchmark at the moment. SMB is faster anyways and requires no special options, so you can use the Finder to attach the share.

If anyone knows of a network filesystem for both Linux & MacOS that can perform better than this, please let me know! For now, I've resigned myself to the SMB throughput - not ideal for playing 5 simultaneous DV streams. I would guess that Apple is too happy with Xsan to pay much attention to NFS & SMB. It'd be nice if NFSv4 was in Leopard!

Final Cut Studio is fairly neat, but quickly toggling the caps-lock key seems to crash it about 20% of the time, and it has plenty of other warts. I'll have to write more about video another time.

1 Comments:

Matt said...

Interesting findings on NFS performance enhancements. Very cool stuff, many thanks for sharing what you've learned.

I wanted to note that your experiences with FCP Studio crashing 20% of the time when CAPSLOCK is toggled, seem really odd...that has never happened to me, nor have I heard it mentioned by other FCP editors. Gotta be frustrating...I accidentally nab CAPS instead of SHIFT all the time. I can't imagine how I would react if it crashed when I did that.

Anyway, just wanted to note that it seems like odd behavior, and perhaps there's another underlying issue at play.

Matt Jeppsen
www.Freshdv.com

28 March, 2007 10:52  

Post a Comment

<< Home