[Samba] LPRng and Samba -- Still

Ryan Novosielski novosirj at UMDNJ.EDU
Fri Dec 6 08:04:00 GMT 2002


I've found a solution to this problem I think should work... but...
doesn't. Take a look at the smb.conf man page:

          %u   user name of the current service, if any.

          %U   session user name (the user name that the client
               wanted, not necessarily the same as the one they got).

...so far so good. Well, LPRng handily includes a way to set who is
printing the current job, by setting print command like the following:

   print command = /opt/LPRng/bin/lpr -P%p -U%U -J'%J' -r %s

...with -U being the important part. But what I can't figure out is is
that %U is still the network guest user. Isn't Samba supposed to use, in
the case of %U (capital U) the client-chosen username? When someone logs
in initially as a username, according to my understanding of the docs on
%U vs. %u, I should have no problem when using the above print command.

Anyone have any comments in regard to this or has anyone any experience
with that?

---- _  _ _  _ ___  _  _  _
|Y#| |  | |\/| |  \ |\ |  |  | Ryan Novosielski - Jr. UNIX Systems Admin
|$&| |__| |  | |__/ | \| _|  | novosirj at umdnj.edu - 973/972.0922 (2-0922)
\__/ Univ. of Med. and Dent. | IST/ACS - New Jersey Medical School - C630

---------- Forwarded message ----------
Date: Fri, 15 Nov 2002 15:38:34 -0500 (EST)
From: Ryan Novosielski <novosirj at umdnj.edu>
To: Samba Mailing List <samba at lists.samba.org>
Subject: LPRng: LPRng and Samba (fwd)

I'm looking for a little help with Samba and LPRng, however, the LPRng
portion of it isn't really all that important -- I believe this is mainly
a Samba issue.

The problem here is that we have 4 campus servers. Each one hosts a Samba
domain. Sometimes, users for whatever reason will go to a different campus
(where they may or may not have an account -- the problem occurs when they
do not). They log in using the Samba domain of their home site, but
attempt to use printers on the campus they are visiting. While the PC they
are using knows what their username is, and I can take this on good faith,
since they do not have an account on the machine Samba serving the
printers, their jobs print as the network guest user. This is clearly a
problem for accounting. Does anyone know of a way for LPRng to find out
who the client PC is logged in as by the time accounting occurs? We don't
wish to just give away pages to students who happen to travel. It's a
shame the setup is the way it is, but I'm just looking for a way to make
this work in our current environment.

Thanks for any help you may wish to give me!

---- _  _ _  _ ___  _  _  _
|Y#| |  | |\/| |  \ |\ |  |  | Ryan Novosielski - Jr. UNIX Systems Admin
|$&| |__| |  | |__/ | \| _|  | novosirj at umdnj.edu - 973/972.0922 (2-0922)
\__/ Univ. of Med. and Dent. | IST/ACS - New Jersey Medical School - C630





More information about the samba mailing list