We currently use PLP with a home grown program that recreates
the printcap according to location (selected at login time)
and a form type, which is set/changed from this program.  We
have multiple "form types" that get printed to the same printer
depending on what form type is set to be serviced with the sv=
parameter in the printcap.   We currently have two printers, one
is a ticket printer and the other is an OTC that emulates HP3.
The ticket printer has two form types that it can handle, the
otc has six form types. This has worked really well for us for
the past five plus years.  I am now trying to upgrade to LPRng
(3.6.12) and have been unsuccessful.  The first problem that I
run into is that the old printcap does not appear to work with
LPRng?  I suspect that it is not being parsed the same way...
just a guess.  (here's a copy of the PLP printcap)

# This file is generated!
#
# Any edits you make will be deleted by the next run of bpcontrol,
# and could break bprint, so DON'T EDIT THIS FILE!  Run bpcontrol
# to change settings instead.
#

lexmark1:\
# Do not remove the next line.  It is used by bpmkspool.
:cm=Lexmark Optra E310 Series printer:\
:rm=dhcp02:rp=registry:\
:ss=cashoffice.SUMMARY:lo=lock.lexmark1:\
:lp=:\
:lf=/var/adm/lpd-errs:\
:sf:sh:mx#0:

monarch1:\
# Do not remove the next line.  It is used by bpmkspool.  
# TELPRINT telprint -q -m666 /dev/telprint_monarch1 ts1 3008
:cm=Monarch 9800 Series printer:\
:ss=any.LBL_MONARCH:lo=lock.monarch1:\
:lp=/dev/telprint_monarch1:\
:lf=/var/adm/lpd-errs:\
:sf:sh:mx#0:

otc1:\
# Do not remove the next line.  It is used by bpmkspool.  
# TELPRINT telprint -q -m666 /dev/telprint_otc1 ps1 2000
:cm=OTC (HP LaserJet III compatible) printer:\
:ss=any.SUMMARY:lo=lock.otc1:\
:lp=/dev/telprint_otc1:\
:lf=/var/adm/lpd-errs:\
:if=/usr/newsprint/lpd/if -notc1 -h%h:\
:sf:sh:mx#0:

otc2:\
# Do not remove the next line.  It is used by bpmkspool.  
# TELPRINT telprint -q -m666 /dev/telprint_otc2 ps2 2000
:cm=OTC (HP LaserJet III compatible) printer:\
:ss=any.SIGN_OTC:lo=lock.otc2:\
:lp=/dev/telprint_otc2:\
:lf=/var/adm/lpd-errs:\
:if=/usr/newsprint/lpd/if -notc2 -h%h:\
:sf:sh:mx#0:

any.LBL_MONARCH:\
:sv=monarch1:mx#0:sd=/var/spool/bp/any.LBL_MONARCH:

any.LBL_OTC:\
:mx#0:sd=/var/spool/bp/any.LBL_OTC:

any.LINENS_OTC:\
:mx#0:sd=/var/spool/bp/any.LINENS_OTC:

any.SIGN_OTC:\
:sv=otc2:mx#0:sd=/var/spool/bp/any.SIGN_OTC:

any.SUMMARY:\
:sv=otc1:mx#0:sd=/var/spool/bp/any.SUMMARY:

any.TAGM_MONARCH:\
:mx#0:sd=/var/spool/bp/any.TAGM_MONARCH:

any.TAG_MONARCH:\
:mx#0:sd=/var/spool/bp/any.TAG_MONARCH
any.TAG_OTC:\
:mx#0:sd=/var/spool/bp/any.TAG_OTC:

cashoffice.LBL_MONARCH:\
:mx#0:sd=/var/spool/bp/cashoffice.LBL_MONARCH:

cashoffice.LBL_OTC:\
:mx#0:sd=/var/spool/bp/cashoffice.LBL_OTC:

cashoffice.LINENS_OTC:\
:mx#0:sd=/var/spool/bp/cashoffice.LINENS_OTC:

cashoffice.SIGN_OTC:\
:mx#0:sd=/var/spool/bp/cashoffice.SIGN_OTC:

cashoffice.SUMMARY:\
:sv=lexmark1:mx#0:sd=/var/spool/bp/cashoffice.SUMMARY:

cashoffice.TAGM_MONARCH:\
:mx#0:sd=/var/spool/bp/cashoffice.TAGM_MONARCH:

cashoffice.TAG_MONARCH:\
:mx#0:sd=/var/spool/bp/cashoffice.TAG_MONARCH:

cashoffice.TAG_OTC:\
:mx#0:sd=/var/spool/bp/cashoffice.TAG_OTC:

In the above printcap, there are three printers, with two 
locations ("any" and "cashoffice").  The sv=printer is the
queue that is currently being serviced depending on which 
location you selected at login time.

We use a program called bprint that we pass a form type to
to tell it which queue to spool to (basically a wrapper to
lpr), If that queue is currently being serviced, it prints, otherwise
it
sits there untill we run the bpcontrol program to change form type and
then that service (sv= ) gets turned on for that queue and rereads the
printcap and HUPs lpd to print what's in that queue.

So in short, with the combination of ss, sv and the location,
the printer services that queue, while other jobs if any, sit
in their queue awaiting to be serviced.

________


It looks like LPRng now has Class/forms built into it.  I've
looked at several of the e-mails on "load balancing" with 
multiple printers from a single queue.  Is there an inverse
solution for single printers that service multiple queues? 
How would I set up my printcap to function the same way as
the above printcap??

Also, I want to use NIS only (no local printcaps) on all of 
my systems.  When I run checkpc -f  -Pprinter_name,  checkpc
fails saying that it can't ypmatch all in the printcap map.  Is
there a way to create spool dirs with the correct permissions
and owner?   As a work around, I created a local printcap with
the same prameters as in the NIS printcap map and then ran 
checkpc -f to create them, then remove the printcap.

Lpd doesn't like to start up either because it can't find
a  local /etc/printcap.  To get around this I touch printcap
to satisfy the startup script. 

Forgot to mention that we are running this on Linux (redhat 6.2)
LPRng 3.6.12 


Any help, comments or suggestions would be greatly appreciated!

-jimr

++++++
begin:vcard 
n:Raeuchle;Jim
tel;fax:603-443-6190
tel;work:603-448-4100  X5161
x-mozilla-html:FALSE
org:Burlington Coat Factory Wharehouse;Network group
adr:;;2 South Park Street;Lebanon;New Hampshire;03677;USA
version:2.1
email;internet:[EMAIL PROTECTED]
title:Network Engineer
x-mozilla-cpt:;-32512
fn:Jim Raeuchle
end:vcard

Reply via email to