110 likes | 141 Views
COP 4343 Unix System Administration. Unit 9: printing lpr CUPS. Printing in Unix. Traditional Berkeley Line Printer Daemon AT&T Line Printer System Improvements: typical Linux implementation LPRng Emerging standard Internet Printing Protocol: IPP/1.1 Common Unix Printing System: CUPS.
E N D
COP 4343Unix System Administration Unit 9: printing lpr CUPS
Printing in Unix • Traditional • Berkeley Line Printer Daemon • AT&T Line Printer System • Improvements: • typical Linux implementation • LPRng • Emerging standard • Internet Printing Protocol: IPP/1.1 • Common Unix Printing System: CUPS
Traditional Linux printing • PRINTER environment variable • command line printing: lpr ex: lpr filename • print job maintenance • show print queue: lpq • remove job from queue: lprm
lpd daemon • configuration • /etc/printcap • local or remote printers • print filters • queue control per printer • lpc • status, start, stop
Common Unix Printing System • CUPS manages printers in a network • maintains printer definitions • allows printing to network printers • maintains lpr commands and /etc/printcap file for backward compatibility
CUPS device support lpinfo -v network socket network http network ipp network lpd network smb serial serial:/dev/ttyS2?baud=115200 direct parallel:/dev/lp1 direct usb:/dev/usb/lp0 direct scsi direct hal
CUPS setup • cups service • yum install cups • enable in run-level: chkconfig cups on • start service: service cups start • configuration • /etc/cups/cupsd.conf • specify which IP:port to listen on listen on 127.0.0.1:631 • allow access to Location / and /admin allow from 127.0.0.1 • security: allow tcp port 631 in firewall
Common Unix Printing System • managing CUPS printers • command line interface: lpadmin • old style semi-graphical: • printconf • web interface on port 631 http://localhost:631/admin • printer definitions • ppd files
CUPS printer setup • printer class • for sets of similar printers • jobs accepted to class will print on one printer in class • printer setup • local: device • network: protocol + host + name • ex: “lpd://ferret.cs.fiu.edu/venom”
CUPS printer setup • supported printers • HP, Epson, Okidata, Postscript, ... • printer options • output resolution, double-sided, banner, ...
CUPS printing • client • PRINTER environment variable • interactive from program • lpr or lp • lpq • lprm • lpstat