Every now and then a customer comes to me with a lot of JPEG formated files that need to be optimized for online use. The main reason for optimizing them is to use them online, or to burn them to a DVD that doesn't require them to be on top quality. I do that often when creating static web-sites that live inside the DVD and are given to visitors on seminars.
There is a command line tool available under Linux that allows you to optimize all images in a given directory with a very simple command. Say hello to jpegoptim.