Tell me more ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have some PDF-files that I would like to shrink. The biggest is 1.2 MB, but I need it to be smaller than 1 MB. Any suggestions as to how? (Terminal commands would be awesome)

share|improve this question
This question appears to be abandoned, if you are experiencing a similar issue please ask a new question with details pertaining to your problem. If you feel this question is not abandoned, please flag the question explaining that. :) – jrg Feb 28 '12 at 13:44

closed as too localized by jrg Feb 28 '12 at 13:44

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, see the FAQ.

2 Answers

ghostscript! It is probably already installed (*) otherwise use sudo apt-get install ghostscript.

Command line to reduce file size:

gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/screen -dNOPAUSE -dQUIET -dBATCH -sOutputFile=output.pdf input.pdf

  • I do not know if you can get the 1.2 Mb below 1 Mb with this though. Probably depends on the content if it does;
  • Replace output.pdf and input.pdf to your pdf names.

(*)

$gs
GPL Ghostscript 9.01 (2011-02-07)
Copyright (C) 2010 Artifex Software, Inc.  All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
GS>^C

share|improve this answer
I don't see how this will reduce the size of my files? All I can gather from that command line is that you just reprint the file using gs. Could you explain a little further? – Ole Christian May 7 '11 at 7:43

I reduced a size of some pdf by importing them to OpenOffice (LibreOffice), and then exporting to PDF format with increased JPEG compression.

Good luck. Vincenzo

share|improve this answer
Could you explain a little further how you imported them? I tried opening the pdf in LibreOffice, and it asked for some ASCII parameters which I just clicked OK on. Then, all I got was a bunch of gibberish in a very long document (The PDF is one page). – Ole Christian May 7 '11 at 7:52

Not the answer you're looking for? Browse other questions tagged or ask your own question.