# printing over smb

## simcop2387

where would i find a good resource on setting up a printer over samba, i'm not sharing mine, i need to print over another.  i managed this with mandrake one time, using cups i belive, but i'm willing to use anything else that works with software the best.

----------

## [UK]Superdude

Supplied for you by the good people who write the Gentoo docs:  :Smile: 

http://www.gentoo.org/doc/en/printing-howto.xml

Got me printing via smb

----------

## simcop2387

shows how much i read docs  :Very Happy: 

----------

## =X¥®µ§=

I have the same problem, and that documentation doesn't work...

I used cups, the kde print manager, webmin, but nothing works

I have samba working (on the windows box you can access the shared linux folders - btw is the other way around possible too??) so that's not the problem...

I have the printer and all installed, but it just doesn't want ot print!

the KDE printer app can even FIND the *** printer   :Crying or Very sad: 

Can anyone help me out here?

----------

## [UK]Superdude

 *Quote:*   

> I have samba working (on the windows box you can access the shared linux folders - btw is the other way around possible too??) so that's not the problem...

 

yup, you can remotely mount shares via smbmount or the normal mount cmd like this

```
mount -t smbfs //computername/sharename /place/you/want/to/mount/it
```

or if you can browse shares using smbclient which is kinda like a bad ftp client  :Smile: 

 as for the printer problem, did you manage to print a cups test page ok?

----------

## =X¥®µ§=

thx, that worked  :Smile: 

however, how can I achieve this automatically?

can I use fstab to do this (and so it automatically gives the password for that disk)?

and that box isn't always on, so it should only mount IF it can make contact, is this possible?

(as you already figured I'm quiet n00b  :Wink:  )

no, I can't print a test page  :Sad: 

in KDE print manager you can even see the devices connected to the workgroup, together with the printers they share, and even if I select that printer it doesn't work

*update*

I just managed to print 3 testpages...I just turned it on and it started printing 3 of them (although there were no active jobs according to cups) but when I try to print a page with opera, it doesn't work

(no, the fact that I didn't turn the printer on isn't really dumb since this printer always automatically started with both windows and redhat/mandrake/suse...like distros)

I have a HP DeskJet 970Cxi and I have HPIJS installed, but in kde/cups/webmin the only drivers I can use are from ESP... maybe this is part of the problem?

----------

## [UK]Superdude

That does sound a bit strange. Im using the same driver for a hp 1220c, it should display as a HP deskjet series driver...

As for automatically mounting a share, I've not tried it myself, but from th fstab man page it would seem to be able to be done. Try googling perhaps....

----------

## simcop2387

i myself cant even get printing to work right now, i havent had much time to work on it though so i should have some time this weekend to work on it, i know the printer works, guess i should have saved my config from my mandrake box when i had it going, oh well too late now already formated.

----------

## Rob W

I just went through this with my own system, Gentoo 1.1a (2.4.19-gentoo-rc5)  It literally took me two weeks of RTFM, googling, and wading through forums.

First thing:  is your samba spool shared?  You must set the sticky bit on the spool, which by default on Gentoo is /var/spool/samba.  The default emerge of samba will not set this for you.  This allows a Windows machine to find the samba printer on the network when you run the Add Printer wizard on windows and allows the Windows client to print to it.

The other pitall, involves the printcap.  The line

```
printcap name = cups
```

needs to be in there, if you're using CUPS, NOT printcap name = lpstat

The third trap is that the default gentoo samba does not have an important line in the [printers] section of smb.conf:

```
printable = yes
```

I had to add that.

Once done, the Samba/Linux printer (HP LaserJet 5L) works flawlessly.  I had to tweak the LaserJet PPD file to reduce the imageable area so text was not truncated at the right and bottom margins.  But it's great now.

Let me know if this helps.  Just be aware, this is what works on my system, YMMV.

Rob W.

Milwaukee, Wis, USA

----------

