Configuring /etc/printcap

The /etc/printcap file is the glue that holds all of what we have covered so far together. It defines the name and aliases of a printer, what filter it uses, the conversion filters it can use, what option should be used to access the filter, where the printer spools to, and more.

There is already an /etc/printcap file on your system, but all of the options are commented out. You will need to uncomment and change options and/or add options.

The format of /etc/printcap is fairly simple. Here is a sample entry:

simba|lp|local line printer:\
#       :sh:\
        :lp=/dev/lpt0:sd=/var/spool/lpd/simba:lf=/var/log/lpd-errs:\
        :if=/usr/libexec/if-ps:

The first line in this entry gives the printer name, followed by any aliases we want to ...

Get FreeBSD® Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.