How do Flickr, Youtube and other high traffic websites handle file uploads?
staunch: One really easy way that works extremely well is to use an old school CGI script to handle the upload. It will die as soon as the upload process is finished, which keeps things very self contained and clean.The most important thing (as others have noted) is that you do processing asynchronously. Get the file on the server, queue it (however simply), and then process the uploads in however big of batches your machine(s) can handle optimally.  99% of the time you're going to want ffmpeg for videos and ImageMagick for images.