Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 27 Aug 1998 11:06:48 +0100 (BST)
From:      Stewart Morgan <stewart@visint.co.uk>
To:        The Hermit Hacker <scrappy@hub.org>
Cc:        samba@samba.anu.edu.au, freebsd-questions@FreeBSD.ORG
Subject:   Re: /etc/printcap for samba-shared printer...
Message-ID:  <Pine.BSF.3.96.980827105946.6386B-100000@dylan.visint.co.uk>
In-Reply-To: <Pine.BSF.4.02.9808250108000.434-100000@thelab.hub.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 25 Aug 1998, The Hermit Hacker wrote:

> 
> Morning...
> 
> 	Just spent this evening getting printing setup off my FreeBSD
> machine (oh, how I love Solaris at these times *groan*)...got it now so
> that I can print directly from Netscape, color and graphics and all.
> 
> 	The printer is an HP 560c.
> 
> 	Now, I want to be able to print from my Windoze95 machine, and
> have samba setup for that, as well as file sharing.  If I setup my Windoze
> machine such that my printer is \\thelab\deskjet, which is the same
> printer (in /etc/printcap) that I use for Netscape under Unix, the test
> page gets sent across, but it isn't correct (graphic is all skewed).

	If it's any help this is the setup we've got -- basically, it'
all from the Samba documentation (docs/Printing.txt I think?). Woody's
printer is an HP LaserJet 4 non-ps printer.

/etc/printcap
-----8<------
woody|Woody's Printer:\
        :sh:\
        :sd=/var/spool/output/woody:\
        :lp=/dev/null:\
        :if=/usr/scripts/PrintToWoody:
----->8------

/usr/scripts/PrintToWoody
-----8<------
#!/bin/sh -x

# This script is an input filter for printcap printing on a unix machine. It
# uses the smbclient program to print the file to the specified smb-based
# server and service.
# For example you could have a printcap entry like this
#
# smb:lp=/dev/null:sd=/usr/spool/smb:sh:if=/usr/local/samba/smbprint

(
# NOTE You may wish to add the line `echo translate' if you want automatic
# CR/LF translation when printing.
#       echo translate
        echo "print -"
        cat
) | /usr/local/bin/smbclient "\\\\woody\\HP\ LJ" "" -U woody -N -P
----->8------

Simply change the relevent details (man smbclient(1) also helps).


Stewart Morgan
--------------                                                                 -
Systems Administrator

Vision Interactive Ltd
18 Whiteladies Road, Clifton, Bristol, BS8 2LG.

E-Mail	: stewart@visint.co.uk
Tel	: +44 (0)117 973 0597
Fax	: +44 (0)117 923 8522
WWW	: http://www.visint.co.uk/


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.96.980827105946.6386B-100000>