AIX Printer process,test print

** Myselft & Credit Web http://www.unet.univie.ac.at/aix/aixbman/printrgd/toc.htm
Printer process :qdaemon,lpd
Check Printer process: lssrc –s qdaemon,lssrc –s lpd
Print job:
lp –d <qname> <file>
lp –d test /etc/hosts
List job: lpstatus
Create remote priter qname
smit-->print-->add print-->remote-->
   Qname:test
   Print server:X.X.X.X -or- hostname
   Name of Queue on remote server (Port from print server) :PR1

Guide to Printers and Printing

Testing the qdaemon
Scenario: Submitting jobs to the spooler causes no discernible spooler activity; this is a well-known scenario in AIX Version 3.2.5. Assume a local ASCII print queue named asc.
Use the command ps -ef | grep qdaemon to verify that the qdaemon is not active. If the qdaemon is not active, you should see, at the most, a line of output representing the grep itself. It should look something like this:
root  2992 18792   0 12:46:39  pts/2  0:00 grep qdaemon
If the qdaemon is active, which it almost certainly will not be, you will see a variant of the following line:
root  2980 3652    0 12:41:25   -   0:00 /usr/sbin/qdaemon
If the qdaemon is not active, issue the command startsrc -s qdaemon to restart the qdaemon. If the qdaemon died, it should have been restarted automatically by the srcmstr process, but it doesn't always work, so restart it manually. You should see a variant of this message:
0513-059 The qdaemon Subsystem has been started. Subsystem PID is 3000.
Wait one minute or so and re-issue the command ps -ef | grep qdaemon. Is the qdaemon still active or did it just start and then die?
If the qdaemon is no longer active, despite the fact that you just restarted it and received a message stating the qdaemon's process id (PID) and that it was active, check for the existence of the file named /var/spool/lpd/stat/pid. You can do this by issuing the command cat /var/spool/lpd/stat/pid. This file contains the PID of an active qdaemon. When the qdaemon is not active, the file is supposed to be removed.
If the cat command prints a number on your display, that should be the pid of an active qdaemon. If you have already determined that the qdaemon is not active, remove the file /var/spool/lpd/stat/pid because a previous instance of the qdaemon somehow died without causing this file to be removed. If the file does not exist, you should see a message like:
cat: cannot open /var/spool/lpd/stat/pid
If the qdaemon was inactive, you restarted it, it died again, the file /var/spool/lpd/stat/pid existed, and you removed that file, then again restart the qdaemon using the command startsrc -s qdaemon. Wait one minute or so and again issue the command ps -ef | grep qdaemon to see if the qdaemon remained active. You can also again issue the command cat /var/spool/lpd/stat/pid to see the file was re-created and now contains a valid PID.
If the answer to the original question, Is the qdaemon running?, was yes, it is, then it is possible that the qdaemon is waiting on all currently running jobs to complete before it shows any signs of accepting new jobs. This scenario often occurs when a machine running AIX has a large number (greater than 25) of printers attached to asynchronous adapters, such as 64-port or 128-port adapters.
To check to see if the qdaemon is waiting on a job to complete before it runs any more jobs, use lpstat to see if any jobs have a status of RUNNING. If so, physically examine the printers that show RUNNING jobs and verify that at least one job is actually running. If one or more printers are showing DEV_WAIT because of paper jams or because they are out of paper, fix the problem and see if the printer begins printing. If it does begin printing, again use lpstat to see if the queue status is RUNNING. In any of these circumstances, the point is to verify that at least one printer is actually printing even though the qdaemon is not starting new jobs.
Now submit a new job to the spooler with the command enq -Pasc /etc/motd.
Use lpstat to examine the queue status. If the new job has a job number of NEW, then the qdaemon is for some reason focused on a running job(s) and will not start any new jobs until the currently running job(s) complete. You can only wait. You can't even cancel the job(s) that are running, because job cancellation requests are just jobs as well, and the qdaemon isn't taking new jobs.

0 comments:

Loading