Operating System - HP-UX
1826056 Members
4136 Online
109690 Solutions
New Discussion

trap "printer busy" on shell script

 
roberto salvatori
Frequent Advisor

trap "printer busy" on shell script

hi all,
what i wanna do is to trap on script shell if one or more printers are busy.
lpstat have no option to do this (i think so).
what can i do? have someone an idea?
thanks in advice

roberto salvatori
3 REPLIES 3
Robert-Jan Goossens
Honored Contributor

Re: trap "printer busy" on shell script

Hi roberto,

Not sure but I think lpstat -p will inform if printer is busy.

Hope it helps,

Robert-Jan.
roberto salvatori
Frequent Advisor

Re: trap "printer busy" on shell script

true, lpstat doesn't show if printer is busy or not. i wanna trap the same thing like on sam. waiting for someone. roberto
Mark Grant
Honored Contributor

Re: trap "printer busy" on shell script

Does "lpstat -t | grep "printing" do what you are after?
Never preceed any demonstration with anything more predictive than "watch this"