🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.sun
Article #11909

SunOS to printer on ethernet terminal sever?

#11909
From: George A. Planansky
Date: Tue, 04 Apr 1989 12:06
30 lines
1952 bytes
We have several printers connected to serial ports on 3COM (Bridge) CS210
communications servers, so that you can connect to a printer by connecting
to its tcp/ip address on ethernet.  For these printers, which are NOT
connected in the usual Unix way to a serial or parallel port on a
computer, how do I spool from Unix to a printer?

Partial answer:  make the following script, called printer.filter:
   #
   cat | (telnet printeraddress) >>& printer.log
where "printeraddress" is the tcp/ip address of the printer's port
on the terminal server.

Then use the following printcap entry:
netpr|printer at printeraddress on terminal server/
	|lp=/dev/null|of=/usr/local/bin/printer.filter

Problem:  It works fine except that if the telnet connection fails, say if
its busy, lpr still bithly spools jobs off to /dev/null.

1. how can I get the printer.filter script to tell lpr the status of the
telnet connection?  I've tried grep'ing for "busy" in the script, and
exiting with an error status, but the error status does not reliably get
propagated back to the lpr program.  What can I do about that?

2. if there is a better way to connect to a printer via ethernet and a
terminal server, I'd be obliged to learn of it.

I can get email as:  gplan@ra.umb.edu .
Otherwise I am George Planansky, at Atmosphere Environment Research, 
840 Memorial Drive, Cambridge MA 02174, USA; phone (617) 547-6207.
Technical Details
Message-ID: <757@umb.umb.edu>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cornell!uw-beaver!rice!sun-spots-request

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cornell!uw-beaver!rice!sun-spots-request
From: contact!umb!gplan@husc6.harvard.edu (George A. Planansky)
Newsgroups: comp.sys.sun
Subject: SunOS to printer on ethernet terminal sever?
Keywords: Software
Message-ID: <757@umb.umb.edu>
Date: 4 Apr 89 12:06:50 GMT
Sender: usenet@rice.edu
Organization: UMASS-Boston, Boston, MA
Lines: 30
Approved: Sun-Spots@rice.edu
Original-Date: 19 Mar 89 07:22:54 GMT
X-Sun-Spots-Digest: Volume 7, Issue 223, message 13 of 15