[cups.general] Re: Automatic Printer Restart?

Minatra, Pat H. pminatra at hsutx.edu
Tue May 9 08:52:48 PDT 2006


This is exactly what I was going to do but I need to find a way to tell
it if the printer is XYZ123 then skip it and go to the next one, in
other words, I have at least one printer I need to leave down all the
time and I just can't seem to figure out how to tell it to skip one.

Wondering if anyone can jog my memory and help me understand how to do
that please?

Thank you for any assistance and have a GREAT day!


-------------------------
"Life is but a twinkle in the eye of eternity"
"The shortest distance between a problem and a solution is the distance
between your knees and the floor"
"sorrow looks back - worry looks around - faith looks up"
Regards,
Pat H. Minatra - N5GJR
(325) 670-5804 voice
(325) 670-1570 fax
Hardin*Simmons University  
www.hsutx.edu
PO BOX 16040
Abilene, TX  79698

-----Original Message-----
From: cups-bounces at easysw.com [mailto:cups-bounces at easysw.com] On Behalf
Of Franz Pfoertsch
Sent: Tuesday, May 09, 2006 8:47 AM
To: cups at easysw.com
Subject: [cups.general] Re: Automatic Printer Restart?

a small cronjob for printer restart:
-8<------------
#!/bin/bash
########################################################################
######
# /usr/local/sbin/start_printers.sh
# Beschreibung: Da die Drucker bei korrodin unter Cups zwar Auftr e
#               anstandslos annehmen, diese aber erst drucken, wenn
#               die Drucker "enabled" werden, dieses Skript als
Workarround:
#               Es enables mintlich die vorhanden Drucker. Unsch , aber
#               wenn's hilft...
########################################################################
######


PRINTERS=$(lpstat -t | grep disable | /usr/bin/cut -d" " -f2)

for PRINTER in $PRINTERS
do
        /usr/bin/enable $PRINTER
done
-8<----------
The crontab entrie:

# (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp
$)
3 * * * * /usr/cust/bin/start_printer >/dev/null 2>&1


I_one wrote:

> Can i see this script for automatic restart my LPD printers ... i have
the
> same problems ... ?
> 
> <angelb at bugarin.us> /  
> : news:24847-cups.general at news.easysw.com...
>> You could setup a cron process that checks for disabled printers
>> every 10 minutes and enables it if found. That's what I did for
>> our servers.
>>
>> At the moment, I don't think there's any setting in CUPS that
>> allows for automating this process. CUPS wouldn't know when a
>> printer has become online or available.
>>
>>> I have a CUPS server with about 20 printers running on it through
the
>>> CUPS-LPD service. One thing that I've noticed is that if a printer
gets
>>> unplugged from the network then printer goes to a "Stopped" state.
This
>>> means that I have to go into the server and turn it back on.
>>>
>>> Does anyone know if there is a way which you can make CUPS
automatically
>>> start the printer once it has re-established its connection on the
>>> network?
>>

_______________________________________________
cups mailing list
cups at easysw.com
http://lists.easysw.com/mailman/listinfo/cups





More information about the cups mailing list