Quote:> We have an Epson serial printer being used as a transaction logger.
> Sometimes the operators turn off the printer resulting in the spool queue
> filling up. The printer will no longer work. Clearing the spooler doesn't
> Shutting down the scheduler and restarting it won't help either. Unix
> be restarted. Shutting down Unix is not an option in our application, If
> anyone knows a fix please help.
maybe the printer driver gets spurious interrupts when the operator turns
off/on the printer itself, thereby locking the OS's pa driver.
Check this by reproducing the problem, then issuing a:
where X is the lp number attached to the printer.
If you get a "Can't open /dev/lpX" error message or the command locks
indefinitely, the above one is probably the reason.
In this case, you can try using a device-polling pa node throught the
The needed command to create a polled device driver node to lp0 is:
mknod /dev/lp0p c 6 64
where /dev/lp0p is the name to which the new device entry is attached, 'c'
means we are going to create a character-based (ie: non block) device
entry, 6 is the my system's pa major device number (this *MUST* be the same
of the one actually related to /dev/lp0 on your system, so check it out!)
and 64 is the minor number.
If you have your printer attached to /dev/lp1, use 65 as minor number. 66
if it is attached to /dev/lp2.
Since you're using the spooling system, you've also to attach the new
device node at the spooling printer you use as transaction destination.
Otherwise you can simply replace the old /dev/lpX entry with the new one,
mv /dev/lpX /dev/lpX-
mv /dev/lpXp /dev/lpX
this lets you undo your changes issuing:
mv /dev/lpX- /dev/lpX
Finally, I don't know if this is going to fix your problems. Sometimes it
works, sometime doesn't...