Linux Programmer | RHCE | RHCSA

Search This Blog

Thursday 12 January 2017

system-config-printer !!

List only connected Printers on Local machine 

             The important part here is the "device-URI". This way you tell CUPS which backend it shall use with the printer "printername". The backends for most types of local printers are already part of the CUPS package. CUPS 1.1.x contains backends for parallel, serial, and USB printers, CUPS 1.2.x will also support FireWire (IEEE 1394) and SCSI printers.

            The backends do not only send data to the appropriate devices. They are also called when CUPS is started. They auto-detect which printer models are connected to which ports. So you should set up your BIOS for the parallel ports to allow bi-directional communication. Then your printer(s) can answer to the auto-detection requests.
To see which devices the CUPS backends auto-detect currently, execute them without command line options:

   $ /usr/lib/cups/backend/usb
   direct usb:/dev/usb/lp0 "HP PSC 950xi" "USB Printer #1"
   direct usb:/dev/usb/lp1 "EPSON USB Printer" "USB Printer #2"
   direct usb:/dev/usb/lp2 "EPSON USB Printer" "USB Printer #3"
   direct usb:/dev/usb/lp3 "Unknown" "USB Printer #4
 
 
List Installed Printers  
        this will list the printers which is installed in local machine.
lpstat -p | awk '{print $2}' | xargs -n1 lpq -P | grep -i "ready" 
 
 
================== Other Options ================
  • /usr/bin/lp - Used to submit print jobs
  • /usr/bin/lp.cups - Used to submit print jobs
  • /usr/bin/lpoptions - Gets and sets printer options for a single user when run by a user or for the system when used by root
  • /usr/bin/lppasswd - Changes printing passwords for an individual user or adds, deletes, and changes printer users and passwords when run by root
  • /usr/bin/lpq - Shows the status of a printer queue
  • /usr/bin/lpq.cups - Shows the status of a printer queue
  • /usr/bin/lpr - Used to submit print jobs
  • /usr/bin/lpr.cups - Used to submit print jobs, forcing use of CUPS
  • /usr/bin/lprm - Used to remove print jobs from a queue
  • /usr/bin/lprm.cups - Used to remove print jobs from a queue
  • /usr/bin/lpstat - Gives status of the CUPS system, such as queue lengths and printers
  • /usr/bin/lpstat.cups - Gives status of the CUPS system, such as queue lengths and printers
  • /usr/bin/cancel - Cancels a print job
  • /usr/bin/enable - Enables a print queue or class of printers, requires a management password
  • /usr/bin/disable - Disables a print queue or class of printers, requires a management password
  • /usr/sbin/lpadmin - Manages printers and classes, requires a management password
  • /usr/sbin/lpc - A compatibility program for Berkley style printers, limited to queue status in CUPS
  • /usr/sbin/lpc.cups - A compatibility program for Berkley style printers, limited to queue status in CUPS
  • /usr/sbin/lpdomatic - A filter script provided to be used in setting up printers
  • /usr/sbin/lpinfo - Shows available printer devices and drivers on the system
  • /usr/sbin/lpmove - Moves the jobs destined for a queue to another queue

These commands only work when you're logged in as root, either when you log in or after switching to root using the su command:
  • /usr/bin/lprsetup.sh - A shell script provided to help set up ghostscript printers
  • /usr/sbin/accept - Causes the print queue to accept requests
  • /usr/sbin/reject - Causes the print queue to reject requests
 

No comments:

Post a Comment

SSH not working with password after upgrade ubuntu 22.04

Issue: In recent upgrade of ubuntu 22.04 we are not able to login server with SSH password. but when we try to login with key then it allow...