Shrinking PDF to Send to Kindle

I needed to send PDF to my Kindle today but it was too large to send via Gmail (around 30MB, 5MB over the Gmail sending limit). I had a few choices. Split the file up somehow, boot Windows and use my hugely expensive copy of Adobe Acrobat, put the file on my Kindle manually via USB or try the free way.
The first two options sounded like a nightmare, especially booting Windows, uuugh! The USB transfer option is a pain, plus it’s really nice for Amazon to store a library for me in the cloud, free of charge, for me to download to my Kindle ereaders (plural) as and when I please. Fortunately I found a nice Ghostscript command to run on my Ubuntu 12.04 installation:

gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/ebook -dNOPAUSE -dQUIET -dBATCH -sOutputFile=smallerFile.pdf bigFile.pdf

30.9MB down to 18.8MB, sweet. You can substitute ‘ebook’ in that commnand line with ‘screen’ which is even more radical in the size reduction, albeit with even more pronounced reduction in the quality of bitmaps in the document.

There is another trick – you can also split the file using pdftk. The following, for example, extracts just the first 10 pages from a PDF:
pdftk big.pdf cat 1-10 output pages1-10.pdf