CUPS URL changes

Michael Sweet mike at easysw.com
Thu Jun 15 11:22:01 PDT 2006


Paul Goodman wrote:
> How do I prevent the URL from changing in the web interface when I perform administrative actions? Here's what happens:
> 
> I open a browser and go to http://localhost:631. Then I click the "Administration" tab. I am prompted for a user name and password, which I enter and log in successfully. Then I click "Manage Printers" and am taken to http://localhost:631/printers. I choose a queue at random and click on "Stop Printer" at which point the url changes from localhost:631 to the server name:631. In other words:
> http://<nameofcupsserver>:631/admin/?op=stop-printer&printer_name=<printer>
> 
> And I get the message:
> Forbidden
> You don't have permission to access the resource on this server.
> 
> If I edit the URL above and change the FQDN of the server to localhost again (but leave everything the same) the action is successful, but why does it keep changing the URL and how can I prevent this behavior?

Check your /etc/hosts file; a recent post turned up an entry like the
following:

     127.0.0.1 loopback localhost

CUPS is seeing "loopback" as the hostname instead of "localhost".

It could also be a difference between the hostname and ServerName
fields - make sure that they match, otherwise the URL rewriting
won't see that the printer is local...

-- 
______________________________________________________________________
Michael Sweet, Easy Software Products           mike at easysw dot com
Internet Printing and Document Software          http://www.easysw.com




More information about the cups mailing list