1

So my questions are:

What would cause lp or lpr to return Unauthorized?

What can I do to fix this problem?

I'm running Ubuntu 10.04 LTS with latest updates. This worked and then stopped after an update. The problem is I don't remember when it stopped. My user is part of lpadmin, which allows me to create and configure printers through the CUPS interface.

Here are my system's protections for lp and lpr.

root@steamboy:/usr/bin# ls -l lp
-rwxr-xr-x 1 root root 13540 2011-09-12 10:41 lp

root@steamboy:/usr/bin# ls -l lpr
-rwxr-xr-x 1 root root 13540 2011-09-12 10:41 lpr

Only if I sudo can I print something at the command line using lp or lpr.

ics@steamboy:~/icsdev$ lp x.tmp
lp: Unauthorized
ics@steamboy:~/icsdev$ lpr x.tmp
lpr: Unauthorized

(x.tmp is a real file.)

2
  • Maybe the user are blocked from using the printer.
    – Mitch
    Jun 7, 2012 at 20:55
  • I've edited the original post. This happened after an update. I know of no printer blocked list. Jun 7, 2012 at 21:02

2 Answers 2

2

Uninstalling and installing cups does NOT cure it. What if you had 50 printers?

In /etc/cups/printers.conf look for AuthInfoRequired it is probably set to negotiate.

There are numerous ways to change this but I do this

/etc/init.d/cups stop
vim /etc/cups/printers.conf 

Remove the line with negotiate in it

/etc/init.d/cups start
1
  • In my case, AuthInfoRequired is set to none and I still have this problem. Nov 6, 2023 at 8:31
0

One thing that might be worth trying is:

sudo apt-get purge cups

That will not only uninstall cups but also delete its configuration files in case one of them is wrong.

Then:

sudo apt-get install cups

Since the configuration files are now fresh you will have to reinstall your printers. If you use any other computer as a print server you may have to do this there as well.

This opensuse link describes what another user had to do to one of his cups configuration files to solve this error message.

5
  • I see you have been struggling with this for quite a while. Jun 8, 2012 at 19:42
  • I'll also give this a shot Monday. Thanks again, again. Jun 8, 2012 at 20:10
  • Excellent. Glad to hear it. Jun 27, 2012 at 17:31
  • I've spread the info far and wide, referencing this post. Jun 27, 2012 at 17:32
  • Doesn't fix the issue nowadays; after a purge and reinstall, the problem persists. Nov 6, 2023 at 8:34

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .