[Xprint] Normal Users unable to print via Xprint

Roland Mainz roland.mainz at nrubsig.org
Sat Apr 17 01:50:43 EDT 2004


Adrian Kuepker wrote:
> I'm running Xprint 0.9. When users try to print to Xprint printers from
> Mozilla, the console that started the daemon receives the following
> errors and nothing comes out of the printer:
> 
> AUDIT: Wed Apr 14 14:08:25 2004: 323 Xprt: client 1 connected from local
> host
> AUDIT: Wed Apr 14 14:08:25 2004: 323 Xprt: client 1 disconnected
> AUDIT: Wed Apr 14 14:08:30 2004: 323 Xprt: client 1 connected from local
> host
> AUDIT: Wed Apr 14 14:08:30 2004: 323 Xprt: client 1 disconnected
> AUDIT: Wed Apr 14 14:08:30 2004: 323 Xprt: client 1 connected from local
> host
> lpr: unable to create temporary file.
> AUDIT: Wed Apr 14 14:08:35 2004: 323 Xprt: client 1 disconnected
> 
> I verified that users have write privs for files in /var/spool and /tmp,
> and there was no change in behavior when set to world-writeable for
> either. Is there anything I'm missing that would enable the printing to
> work properly? If there is pertinent information that should be
> provided, please let me know what should be included.

I can only guess since I do not have seen the source of the "lpr" you
are using.
First guess is: The Xprint system is started at system startup with a
CWD (current working directory) set to '/' or '/root' ... but when Xprt
(the Xprint server) executes commands it switches to the user id of the
requesting client via setuid() and then it may not have access to that
directory anymore and that may result in the above error message.

Can you try the following (as root):
1. Stop the Xprint service
% /etc/init.d/xprint stop
2. Switch to a directory which EVERYONE can write to:
% cd /tmp
3. Start the Xprint service again (e.g. with CWD=/tmp)
% /etc/init.d/xprint start

Does that work around the problem ?

BTW: Which spooler do you use ? CUPS ? LPRng ? Which version ? Where can
I get the source code from (assuming it is public) ? 

----

Bye,
Roland

-- 
  __ .  . __
 (o.\ \/ /.o) roland.mainz at nrubsig.org
  \__\/\/__/  MPEG specialist, C&&JAVA&&Sun&&Unix programmer
  /O /==\ O\  TEL +49 2426 901568 FAX +49 2426 901569
 (;O/ \/ \O;)


More information about the Xprint mailing list