There is also a different type of PDF known as PDF/A. PDF/A is a subset of PDF that is meant for archiving information. In order to preserve the information in the file and to ensure that the contents will still appear as it should even after a very long time of storage, PDF/A sets stricter standard than those used by PDF.
PDF/A is a special type of PDF meant for archiving documents
PDF/A does not allow audio, video, and executable content while PDF does
PDF/A requires that graphics and fonts be embedded into the file while PDF does not
PDF/A does not allow external references while PDF does
PDF/A does not allow encryption while PDF does
-dPDFSETTINGS can be any of:
/screen : low-resolution output, lowest output size
/ebook : medium-resolution output, medium output size
/printer OR /prepress : high-resolution with maximum output size
Run the Shrinkpdf script:
./shrinkpdf in.pdf out.pdf
The script is almost same as the explicit gs command above. However, it has one advantage – it does an output file size check.