System Administration Guide: Advanced Administration

How to Set a System's Default Printer

  1. Log in as superuser, lp, or assume an equivalent role on the system where you want to set a default printer.

  2. Set the system's default printer.


    # lpadmin -d [printer-name]

    -d printer-name

    Name of the printer you are assigning as the system's default printer. If you don't specify printer-name, the system is set up with no default printer.

    The default printer name is entered in the system's /etc/lp/default file.

  3. Check the system's default printer.


    $ lpstat -d
    

Example—Setting a System's Default Printer

The following example shows how to set the printer luna as the system's default printer. This means that luna is used as the system's default printer if the LPDEST or PRINTER environment variables are not set.


# lpadmin -d luna
# lpstat -d
system default destination: luna