Managing Printer Entries
Adding Printers
To add printer entries to the LDAP directory, use either the printmgr
configuration tool or the lpset -n ldap command-line utility. See lpset(1M). Note that the printer objects
added to the directory only define the connection parameter, required by print system
clients, of printers. Local print server configuration data is still held in files.
A typical printer entry would look like the following:
printer-uri=myprinter,ou=printers,dc=mkg,dc=example,dc=com
objectclass=top
objectclass=printerService
objectclass=printerAbstract
objectclass=sunPrinter
printer-name=myprinter
sun-printer-bsdaddr=printsvr.example.com,myprinter,Solaris
sun-printer-kvp=description=HP LaserJet (PS)
printer-uri=myprinter
Using lpget
lpget(1M) can be used to list all printer entries known by the LDAP
client's LDAP directory. If the LDAP client's LDAP server is a replica server,
then printers listed might not be the same as that in the master
LDAP server depending on the update replication agreement. See lpget(1M) for more information.
For example, to list all printers for a given base DN, type
the following:
# lpget -n ldap list
myprinter:
dn=myprinter,ou=printers,dc=mkt,dc=example,dc=com
bsdaddr=printsvr.example.com,myprinter,Solaris
description=HP LaserJet (PS)