One more note, if you are have some budget, nsort is very fast for this type of work, http://www.ordinal.com/performance.html, for example it does that same test sort (24 mil recoreds) in < 5 minutes on my 420r 2proc sun. The only catch is that it is pretty spendy I think.