Printing.

Griff Miller griff.miller at positron.com
Fri Oct 12 14:25:02 GMT 2001


> Hi,
> 
> I'm running Samba 2.2.1a on a FreeBSD 4.3 box. Basically I'm trying to
> replace a Small Business Server 2000 machine. The one problem I have run
> into so far is printing. I have about 6 Hp laserjet printers. Can anyone
> point me in the right direction towards getting these up and running.
> I've looked at the FreeBSD handbook. But couldn't get them to work - the
> need to be set up as network printers rather than throught parrallel
> ports due to physical restrictions. Anyone got any pointers, I'd really
> appreciate. Thanks.

I am not the world's most experienced, but I'll try to help out.

Note that there's more than one way to do this. I'll just describe one.
For example, you could set "load printers" to yes, and your printers
would automatically get loaded. I prefer to set them up individually.

First of all, you need to be able to print to these printers from the
Unix machine. Can you do that yet? If not, you need to set this up.
I don't know if FreeBSD has any kind of printer admin interface, but
if you set up the FreeBSD machine to print to the "raw" queue on the
printers, you should be very close. Example /etc/printcap entry:

hp1:lp=:rm=hp1:rp=raw:lf=/usr/adm/lpd-errs:sd=/usr/spool/hp1:mx#0:

So, you would have a queue on the FreeBSD box called "hp1", which
prints to a printer whose hostname is "hp1" .  Obviously, whatever
nameservice you are using needs to resolve "hp1" to the printer's
IP address. You need to have a file called /usr/adm/lpd-errs and a
directory called /usr/spool/hp1. These need to have the proper permissions
and owner/group, whatever that is for FreeBSD.

Now, you should be able to "echo foo | lpr -P hp1" and get something out
on hp1.

Once that is working, you can then setup a share in your smb.conf like this:

[hp1]
        comment = HP LaserJet 1
        path = /usr/spool/samba-printers/hp1
        printer = hp1
        public = no
        writable = no
        printable = yes

Make sure that /usr/spool/samba-printers/hp1 exists and is writable.

Now, you can navigate to Network Neighborhood -> SAMBASERVER -> hp1 .
Double-click on hp1, and provide it with a printer driver, and you
should be good to go.

Later, when you get a little more comfortable with Samba, you can
configure Samba to hold the printer drivers, so that you don't have
to manually install printer drivers on every client machine. Just
double-click on hp1, and you're instantly set up.

Hope this helps. Good luck!

-- 
Griff Miller II                   |                                           |
Manager of Information Technology | "I need to be the owner of all of         |
Positron Corporation              |  the files in /usr/kvm."                  |
griff.miller at positron.com         |                                           |




More information about the samba-ntdom mailing list