[sf-lug] lpadmin --> forbidden

Dennis J Harrison Jr dennisharrison at gmail.com
Sun Oct 26 15:33:25 PDT 2008


A little more background is in order here.

What distro is this?  And how is this printer connected?  USB?

If so you might want to look into what version of cups you are running.

Also you might find this url helpful

http://lists.debian.org/debian-user/2006/08/msg00950.html

On Sun, Oct 26, 2008 at 4:56 PM, Alex Kleider <a_kleider at yahoo.com> wrote:
> I expect this is way more than you wanted, but here it _all_ is:
>
> alex at lildell:~$ lpinfo -v
> network socket
> network beh
> network http
> network ipp
> network lpd
> direct parallel:/dev/lp0
> file cups-pdf:/
> alex at lildell:~$
> alex at lildell:~$ dmesg | grep -i print
> [   24.778371] parport0: Printer, Hewlett-Packard OfficeJet Series 700
> alex at lildell:~$ man lpadmin
> alex at lildell:~$ cd /etc/cups
> alex at lildell:/etc/cups$ ls
> acroread.conf   client.conf         cupsd.conf.O   mime.types    printers.conf    raw.types
> classes.conf    cupsd.conf          cups-pdf.conf  pdftops.conf  printers.conf.O  snmp.conf
> classes.conf.O  cupsd.conf.default  mime.convs     ppd           raw.convs        ssl
> alex at lildell:/etc/cups$ cd ppd
> alex at lildell:/etc/cups/ppd$ ls
> OfficeJet.ppd  PDF.ppd
> alex at lildell:/etc/cups/ppd$ su george
> Password:
> george at lildell:/etc/cups/ppd$ ls
> OfficeJet.ppd  PDF.ppd
> george at lildell:/etc/cups/ppd$ lpadmin -p OfficeJet -v parallel:/dev/lp0 -m OfficeJet.ppd
> lpadmin: Forbidden
> george at lildell:/etc/cups/ppd$ su root
> Password:
> root at lildell:/etc/cups/ppd# lpadmin -p OfficeJet -v parallel:/dev/lp0 -m OfficeJet.ppd
> lpadmin: Forbidden
> root at lildell:/etc/cups/ppd# man lpadmin
> root at lildell:/etc/cups/ppd# which lpadmin
> /usr/sbin/lpadmin
> root at lildell:/etc/cups/ppd# ls -l /usr/sbin/lpadmin
> -rwxr-xr-x 1 root root 21508 2008-10-15 10:30 /usr/sbin/lpadmin
> root at lildell:/etc/cups/ppd# lpadmin
> Usage:
>
>    lpadmin [-h server] -d destination
>    lpadmin [-h server] -x destination
>    lpadmin [-h server] -p printer [-c add-class] [-i interface] [-m model]
>                       [-r remove-class] [-v device] [-D description]
>                       [-P ppd-file] [-o name=value]
>                       [-u allow:user,user] [-u deny:user,user]
>
> root at lildell:/etc/cups/ppd# lpadmin -p OfficeJet -v parallel:/dev/lp0 -m OfficeJet.ppd
> lpadmin: Forbidden
> root at lildell:/etc/cups/ppd# file /usr/sbin/lpadmin
> /usr/sbin/lpadmin: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), for GNU/Linux 2.6.8, dynamically linked (uses shared libs), stripped
> root at lildell:/etc/cups/ppd# exit
>
> ----------------------- end of cut and paste---------------------------
>
> This gives you a complete overview of what I was doing.
> I'm the sudoer on this machine and when I'm logged on, the printer functions but not so when George is logged on. He can't install the printer using the standard Ubuntu utilities because he doesn't have root privileges.
> Seems catch 22 to me.
> I was driven to the command line because
> giving http://localhost:631 to firefox just caused it to sit there and go nowhere which suggests that there may be a more fundamental underlying problem in the cups system.
> This machine has another problem: after every boot it must be given
> sudo ifup eth0
> to get networking going
> so my plan is to start over and reformat the drive with the new version of
> ubuntu as soon as it comes out Thursday. In other words: solving this problem isn't critical but it does interest me to find out what is happening.
>
> Thanks for taking an interest.
>
> alex
>
>
> a_kleider at yahoo.com
>
>
> --- On Sun, 10/26/08, John Lowry <johnlowry at gmail.com> wrote:
>
>> From: John Lowry <johnlowry at gmail.com>
>> Subject: Re: [sf-lug] lpadmin --> forbidden
>> To: sf-lug at linuxmafia.com
>> Date: Sunday, October 26, 2008, 1:53 PM
>> Can you cut and paste the error message you get?
>>
>> Alex Kleider wrote:
>> >
>> > While trying to solve a pesky printer problem from the
>> command line I get
>> > forbidden
>> > as a response to trying to execute the following:
>> >
>> > root at lildell:/etc/cups/ppd# lpadmin -p OfficeJet -v
>> parallel:/dev/lp0 -m OfficeJet.ppd
>> >
>> > permissions seem to be in order:
>> > root at lildell:/etc/cups/ppd# ls -l /usr/sbin/lpadmin
>> > -rwxr-xr-x 1 root root 21508 2008-10-15 10:30
>> /usr/sbin/lpadmin
>> >
>> > Has anyone any idea what's happening?
>> >
>> >
>> >
>> >
>> >
>> > _______________________________________________
>> > sf-lug mailing list
>> > sf-lug at linuxmafia.com
>> > http://linuxmafia.com/mailman/listinfo/sf-lug
>>
>> _______________________________________________
>> sf-lug mailing list
>> sf-lug at linuxmafia.com
>> http://linuxmafia.com/mailman/listinfo/sf-lug
>
>
>
>
> _______________________________________________
> sf-lug mailing list
> sf-lug at linuxmafia.com
> http://linuxmafia.com/mailman/listinfo/sf-lug
>




More information about the sf-lug mailing list