[Samba] PDF printing problem - can't find Samba's spool file?

Kurt Pfeifle kpfeifle at danka.de
Fri Dec 13 00:04:03 GMT 2002

David Brodbeck wrote:
>>-----Original Message-----
>>From: Kurt Pfeifle [mailto:kpfeifle at danka.de]
>>I tell you what mine is doing: It *uses* the printing system. 
> Okay.  I know the one Linux Journal talked about a while back did not -- it
> was just a shell script that was run as a 'print command'.  This has some
> advantages, one being it's a lot easier to send a popup notification, since
> you already have the client IP.  My old script, the one that was an lpd
> input filter, had to go through some gyrations to figure out the IP
> associated with the username that the job was submitted under.
>>My printing
>>system is CUPS, the most flexible one of them all. I use a bash shell
>>script which is made to work as a CUPS "backend".
> This sounds interesting, and I may look into it if I can't figure this out.
> I was hoping to get rid of the added complication of the printing system
> altogether, since it shouldn't really be necessary for what I'm trying to
> do.  There are NO physical printers on the system, so running a full-blown
> spooling and printing system doesn't get me anything but configuration
> headaches and another running service for someone to exploit.  And frankly,
> editing /etc/printcap gives me a raging headache. ;)
>>>I didn't post that
>>>information because it didn't seem relevent to the question.
>>You yourself indicated that it is relevant because you said after
>>the upgrade your script stopped working...
> Right, but that script isn't the same one I'm trying to use now.  That
> script was an lpd input filter, linked in through /etc/printcap.  This one
> is run directly from Samba.  It does work, except for the fact that Samba
> never creates a temporary file with the print job in it.  This makes me
> skeptical that CUPS will work, either -- where would it get the data from?
> I know under LPRng, Samba simply created a temporary file, then called lpr
> on it.  That won't work if there's no temporary file created.
>>And, BTW, you shouldn't call people any names, who are giving their
>>private time for free to help people who seem to have 
>>problems in their profession -- or be prepared to get no answer at all.
> I'm sorry, but if someone is rude to me I tend to return the favor.  You may
> want to go back and look at the tone of voice you used in your original
> reply to me.

I did, and I don't feel guilty of being rude. However, I feel I have put
in a *lot* of effort to help you, *after* I was able to tickle a little
piece of info out of you. Remember, no-one eles responded at first, and
you should ask yourself why. Try to provide more useful info in the future
in your first port.

> I *do* appreciate the help, but I don't appreciate being treated like an
> idiot in the process.

I am sorry, if me slightly ironic undertone did hort you.

>>* Samba has a great little utility, which lets you increase
>>   and decrease the debuglevel "on the fly", without editing
>>   and reloading the smb.conf or stopping and starting the
>>   daemon:
>>    "smbcontrol smbd debuglevel"  # tells you the current debuglevel
>>    "smbcontrol smbd debug 3"     # set the debuglevel to 3
> Good idea.  I will give this a try after business hours.  Right now there's
> so much traffic on the system that the debug output is overwhelming at level
> 3.

Sometimes -- if it is very obvious -- you even get useful info from debuglevel
2 or 1.

> I'll keep your other suggestions, and use them if I can't get this working
> as-is.  I really feel like it shouldn't be necessary to build a whole CUPS
> configuration just to do this, though. 

No, it isn't. If your clients don't run CUPS, you'd have to upgrade them
to CUPS to reap the fullest of benefits from that approach (PDF backend
script on the server). If your clients run CUPS anyway, then it is the
most easy and complete approach. If you don't have any physical printer
in your net served by CUPS, you can well stick with what you plan.

But who could know your intention or your environment from the info
you provided?

> Other examples I've seen for
> creating PDF printers didn't.

Please tell us the content of the smb.conf file (without comments),

     grep -v ^# /etc/samba/smb.conf | grep -v "^;" | grep -v ^$

Only if you tell us all your other settings will someone be able to
guess why your Samba spool directory doesn't seem to get the jobs,
or why your custom print command isn't executed (questions coming to
mind are "What's in the [general] section?"; "What's in the [printers]
section?" etc.)

Kurt   [ who was missing a comment about his previous hints and questions
          regarding the "printing = cups" and "printcap = cups" settings
          and the question if your smbd is linked against libcups?  ]

More information about the samba mailing list