On Tue, Dec 15, 2009 at 6:51 PM, Barry <[email protected]> wrote: > Christopher Sawtell wrote: >> >> 2009/12/12 Barry <[email protected]> >> >>> Nick Rout wrote: >>> >>>> On Fri, Dec 11, 2009 at 5:02 PM, Barry <[email protected]> wrote: >>>> >>>>> I have a old printer which gets used once per month and is unplugged >>>>> and >>>>> stored most of the time. >>>>> >>>>> When I plug it in cups recognises it but produces 'permission denied' >>>>> messages even though I have added myself to the lp and lpadmin groups. >>>>> >>>>> Stopping and restarting the cups daemon does not work >>>>> >>>>> To get output I have to alter the permissions on /dev/lp0 from 660 to >>>>> 666. >>>>> >>>> who owns the file /dev/lp0? (if it is a symlink then who owns the file >>>> it ultimately points to?) >>>> >>>> >>> lp0 is owned by root and group is lp. This is not a link >>> >>> The cmd to print a file is issued by the user. >>> >>> In cups the allowed users for this printer are set to 'root,barry'. Just >>> a >>> thought, users are not set for my usb printer, should users be unset? >>> >> >> It would help considerably if we knew, definitively, the full ownerships >> of >> both the device, and that of the lpd and cups processes. >> >> Please can you execute the following commands and report what is printed. >> In the interest of avoiding typo errors it would be best if you could cut >> and paste the one-liners to and from your mail agent and a console. >> >> ls -l /dev/lp0 >> >> ps aux | egrep "cups|lpd" | grep -v grep >> >> imho, in actual practice, i.e. once a month, the use of the cups printing >> system in this case is total overkill. >> >> cd ~/the/data/dir/of//the/print/labels_file >> >> cat labels_file | lpr -Pdmp # dmp = the name of the dot matrix printer > > copied as requested > > [ba...@localhost ~]$ ls -l /dev/lp0 > crw-rw-rw- 1 root lp 6, 0 2009-12-03 03:50 /dev/lp0 > > [ba...@localhost ~]$ ps aux | egrep "cups|lpd" | grep -v grep > root 28599 0.0 0.4 7880 1840 ? SNs Dec10 0:07 cupsd >
Barry certainly at one time cupsd only initially runs as root (so as to access port 631) and switches to another user. However it has changed a lot since I last delved! (and been bought by Apple!!) Your version is old, 1.4.x is available now. This problem seems ot be described in many posts dating around 2005, so i suspect an upgrade may help. BTW Chris on my system lpr is provided by cups :) (specifically cups-bsd "Common UNIX Printing System(tm) - BSD commands" - whether cupsd is required to run to make that version of lpr work I do not know. > >
