# [SOLVED] cups problem: Can't print to remote Printer

## furanku

Hi,

I have a gentoo desktop system (~amd64, 192.168.0.2), which serves as cups server (1.3.10) for an HP 5600 printer. Printing locally on the server works fine. Printing from an ubuntu laptop (192.168.0.3) on the local home network to this server worked fine for several years, but broke some months ago with an update (don't remember exactly what was updated).

Since then I tried almost every guide to set up network printig again, with no avail. The best I can achieve is that the ubuntu laptop sees the printer, but printing never works typically i see

```

E [30/May/2009:03:03:53 +0200] Get-Printer-Attributes: Forbidden

D [30/May/2009:03:03:53 +0200] cupsdSendError: 18 code=403 (Forbidden)

D [30/May/2009:03:03:55 +0200] cupsdCloseClient: 20

D [30/May/2009:03:03:55 +0200] cupsdAcceptClient: 20 from 192.168.0.3:631 (IPv4)

D [30/May/2009:03:03:55 +0200] cupsdReadClient: 20 POST /printers/Officejet_5600 HTTP/1.1

D [30/May/2009:03:03:55 +0200] cupsdAuthorize: No authentication data provided.

D [30/May/2009:03:03:55 +0200] Get-Printer-Attributes ipp://192.168.0.2:631/printers/Officejet_5600

```

 in the cups log file.

My current cupsd.conf looks like this 

```
LogLevel info

SystemGroup lpadmin

# Allow remote access

Port 631

Listen /var/run/cups/cups.sock

# Enable printer sharing and shared printers.

Browsing On

BrowseOrder allow,deny

BrowseAllow all

BrowseAddress @LOCAL

DefaultAuthType Basic

<Location />

  Allow localhost

  Allow 192.168.0.*

  Allow all

  # Allow shared printing and remote administration...

  Order allow,deny

  Allow all

</Location>

<Location /admin>

  Encryption Required

  # Allow remote administration...

  Order allow,deny

  Allow all

</Location>

<Location /admin/conf>

  # Allow remote access to the configuration files...

  Order allow,deny

  Allow all

</Location>

<Policy default>

  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job CUPS-Move-Job>

    Allow all

    Order allow,deny

  </Limit>

  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default>

    AuthType Default

    Order allow,deny

  </Limit>

  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After CUPS-Accept-Jobs CUPS-Reject-Jobs>

    AuthType Default

    Allow all

    Order allow,deny

  </Limit>

  <Limit CUPS-Authenticate-Job>

    Allow all

    Order allow,deny

  </Limit>

  <Limit All>

    Order allow,deny

  </Limit>

</Policy>

```

But this is just one configuration I tried among a lot of others I found on the net. I especially tried a lot of combinations of Allow options in the config file. Could anyone post a minimal configuration file for network printing?

----------

## furanku

Ok, just if someone runs into the same problem, here's what solved the problem:

For some reasons I do not understand, in the ubuntu printer configuration the cups server IP was alwasy replaced by its full qualified hostname including the pseudo domain name ".site". Adding an entry in the clients /etc/hosts, which resolves that back to the servers IP (192.168.0.2) enabled printing from the laptop. Strange, but I'm to lazy to investigate any further what caused that problem, just glad that it works again ...

----------

