Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 (Tek) 9/28/84 based on 9/17/84; site athena.UUCP Path: utzoo!watmath!clyde!burl!ulysses!mhuxr!mhuxt!houxm!vax135!cornell!uw-beaver!tektronix!teklds!athena!rogers From: rogers@athena.UUCP (Roger Southwick) Newsgroups: net.unix Subject: Re: 4.2 Printer Spooler Question (long answer) Message-ID: <350@athena.UUCP> Date: Mon, 26-Aug-85 13:35:38 EDT Article-I.D.: athena.350 Posted: Mon Aug 26 13:35:38 1985 Date-Received: Wed, 28-Aug-85 21:28:17 EDT References: <136@cdstar.UUCP> Reply-To: rogers@athena.UUCP (Roger Southwick) Organization: Tektronix, Beaverton OR Lines: 68 Summary: [Do not meddle in the affairs of Unix, for it is subtle and quick to anger.] > We would like to hook up a HP laser jet printer to the spooler in > a special way. I would like to create two queues, by two different > names, with different spool directories and different output > filters. All this works fine, but if you enable printing on both > at once you get multiplexed output!! Is there anyway to set this > up, so that the device is shared properly and output files don't > get stepped on. Today we must stop printing on one queue to start > the other. Hello there... I'll hope that you don't get hoards of these sorts of answers. To start, I'll assume that you are using the same 'lp=/dev/foo' in both entries in your /etc/printcap. The problem is that setting up a new queue says that there are multiple lock files for the device, and the spooler assumes that if you send something to queue A, then something to queue B, that both device A & B are open (not locked). To solve this, use a line like: :lo=../QUEUENAME/lock: on all but one of your entries. Thats how I fixed it. For example here is a portion of our /etc/printcap where I have set up 3 queues and 3 filters for one device: lprw|lp|Wide Line Printer:\ :lp=/dev/lprw:\ :sd=/usr/spool/lpd/lpwide:\ :lf=/usr/spool/lpd/ERRORLOG:\ :af=/usr/adm/lpdacct:\ :if=/usr/lib/local/filters/printronix:\ :gf=/usr/lib/gpf:\ :of=/usr/lib/lpf:\ :tr=\n\f:\ :pq=lpwide:\ :br#9600: lpsloww|lps|Slow Wide Line Printer:\ :lp=/dev/lprw:\ :sd=/usr/spool/lpd/lpsw:\ :lo=../lpwide/lock:\ :lf=/usr/spool/lpd/ERRORLOG:\ :af=/usr/adm/lpdacct:\ :if=/usr/lib/local/filters/printronix:\ :gf=/usr/lib/gpf:\ :of=/usr/lib/local/filters/lpf_slow:\ :tr=\n\f:\ :pq=lpsw:\ :br#9600: lafastw|lpf|Fast Wide Line Printer:\ :lp=/dev/lprw:\ :sd=/usr/spool/lpd/lpfw:\ :lo=../lpwide/lock:\ :lf=/usr/spool/lpd/ERRORLOG:\ :af=/usr/adm/lpdacct:\ :if=/usr/lib/local/filters/printronix:\ :gf=/usr/lib/gpf:\ :of=/usr/lib/local/filters/lpf_fast:\ :tr=\n\f:\ :pq=lpfw:\ :br#9600: Hope that solves your problem. -Roger