[comp.unix.admin] LP Spooler problems

dfh@dwx3bs.att.com (D442-D. F. Haertig (Dave) x3040) (05/30/91)

I have some questions on the UNIX LP Spooler.  I am not a system
administrator, and have tried to set-up the spooler with the help
of 'root'.  We are using an AT&T 3B15 running System V, R3.1.1.

Brief history
-------------
I maintain an Oracle database on the system.  Users run reports against
the database that sometimes take several hours to run.  What I want to
do is:
  (1) Assure that only one report is running at any given time (so as
      not to drag down the system) - an obvious spooler application.
  (2) Be able to turn the report interface on and off to allow us to
      shut down the database for backup, etc - the disable and enable
      commands should support this.

When I talk about a "printer" below, I'm obviously not really talking
about a printing device.  It's actually a database interface program that
emails a report back to the user.

Everything works fine except for the disable/enable part.  All sources
of documentation I can find on the LP Spooler state that any job
currently running on a printer when it is disabled will be run
again (in it's entirety) when that printer is later enabled.  This is
not happening.  The disable leaves the job in queue, but the enable
does not respawn the job.  It just sits there in queue.  Subsequent
job requests do *not* flush out the old disabled/enabled job.

If we use lpshut/lpsched instead of disable/enable, jobs are aborted,
left in queue, and automatically restarted as desired.  This also will
flush the old disabled/enabled jobs that were in never-never land.  Our
'root' doesn't have a problem with me using lpshut/lpsched since there
are no printers on the system and my application is the only one using
the spooler.  Unfortunately, lpshut must check your real userid, because
it doesn't allow the Joe Average user access - even with the setuid
bit set.

For what it is worth, other system administrators tell me that currently
running jobs are canceled and deleted from the queue when a printer
is disabled.  I don't see this happening either.  Maybe they're running
a different release of UNIX?

I don't normally read this newsgroup, so email responses are preferable.

Thanks,
Dave Haertig
dfh@dwx3bs.att.com