From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <97535868628444.tru64-unix-managers.marc@archive.invalid> From: "rbabcock () heyoka ! cc ! whecn ! edu" Date: Mon, 27 Nov 2000 20:57:42 +0000 To: tru64-unix-managers Subject: SUMMARY: Need printing help - fast! X-MARC-Message: https://marc.info/?l=tru64-unix-managers&m=97535868628444 Thanks to all who responded, and especially to Ettore Aldrovandi and Debra Alpert, whose replies are copied below. The solution was to include an lp=@host/service line to the printcap entry. The curious thing is that the original printcap entry worked just fine on 4.0f. From: Ettore Aldrovandi Hi, are you trying to use tcp printing? Or just use remote printing? If the latter is the case, you'll need the the :lp: entry as well, while the ct flag is probably irrelevant. Also, filtering should be ignored. If on the other hand you are using tcp printing, then you should have :ct=tcp: alright, but that needs the lp flag to be set like :lp=@aaa.bbb.ccc.ddd/port: where "port" is defined in /etc/services (and depends on the printer, for ex. 9100 for several HPs). Is this a working printcap entry on 4.0F? If it is, I'm a little puzzled, because it shouldn't work. Maybe that's the cause. 5.1's lpd may be less forgiving. I have 5.0A and 5.1 and use tcp printing more or less as explained above. Here is an entry from my printcap: # HP LASERJET 8100DN (B/W Postscript, 2 sided printing) ps5_2|pspr5_2:\ :ct=tcp:\ :lp=@xxx.yyy.zzz.ttt/hp8100dn:\ :mx#0:\ # :rp=raw:\ :if=/usr/lbin/ppdof +Chplj8000.rpd -K two:\ :of=/usr/lbin/ppdof +Chplj8000.rpd:\ :lf=/var/adm/ps5_2err:\ :sd=/var/spool/ps5_2: hp8100dn is defined in /etc/services as hp8100dn 9100/tcp Hope this helps, Ettore -- Ettore Aldrovandi ettore@sg1.hep.fsu.edu Ph: (850) 644 3289 http://www.hep.fsu.edu Fax: (850) 644 6735 From: "Alpert, Debra" To: "'rbabcock@heyoka.cc.whecn.edu'" Subject: RE: Need printing help - fast Date: Mon, 27 Nov 2000 13:46:56 -0500 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: text/plain Ron, We had this same problem with the lpr binary that shipped with TU5.1. By using truss to trace the system calls made by lpr, I found that the program parsed the printcap file, assuming that the "lp" field (default output device) was explicitly set in /etc/printcap for each printer. I had never set this, as we print to a network device. In any case, since the lpr code doesn't actually check the return value when it looks for the lp printcap entry, it proceeds happily along, although a NULL pointer has been returned. This caused problems down the line, as you can see from the following truss output: Received signal #11, SIGSEGV [default] siginfo: SIGSEGV SEGV_MAPERR addr=0x0000000000000000 Err#139 Error 139 occurred. *** process killed *** The OS wasn't happy when access to memory address zero was attempted. It appears that the lpr code doesn't check the return value of the relevant call. In any case, I worked around this problem by adding a null lp entry to our printcap files (that is, ...stuff...:lp=:...stuff). Now the return value in question is a pointer to the above NULL string. This keeps lpr happy, and printing works once again. Hope this helps, --Deb Debra Alpert Senior Unix Systems Administrator Lifeline Systems > -----Original Message----- > From: rbabcock@heyoka.cc.whecn.edu [SMTP:rbabcock@heyoka.cc.whecn.edu] > Sent: Monday, November 27, 2000 12:14 PM > To: tru64-unix-managers@ornl.gov > Subject: Need printing help - fast > > Managers, > > Over the weekend I switched from an Alpha AS1000A 5/40 to an ES20D. > The old alpha was running 4.0f, the new one is running 5.1. I copied > the printcap file to the new system but am having a problem with the > networked printers. Below is a typical printcap entry: > > > lp20|20|LP20|:\ > :af=/usr/adm/lp20acct:\ > :lf=/usr/adm/lp20err:\ > :of=/usr/lbin/lpf -c:\ > :ct=tcp:\ > :pw#85:\ > :rm=aaa.bbb.ccc.ddd:\ > :rp=text:\ > :sd=/usr/spool/lpd20:\ > :sh: > > When a file is sent to this printer I get a segmentation fault and a > core dump. E. g., lpr -P20 /etc/motd results in a core dump. All of > my LAT printers are working ok. Any ideas? > > Ron Babcock, Dir. Admin. Computing > Casper College > Casper, WY 82601