If you can use Python, I think the best tool is the pyPdf, it is very very fast at manipulating the pdf files. It does not need to convert pdf into ps and back again. There are several scripts using this package on this forum. just search that.
http://pybrary.net/pyPdf/