Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have two printers, a Dell V715w and a HP LaserJet P2015, connected by USB to a computer running Ubuntu for sharing to all of the laptops in my house with CUPS. I installed both printers locally on the Ubuntu computer, configured CUPS, started it, and tested printing locally, with no problems.

I connected to the HP printer on all of the laptops fine, and tested printing from all of them, also with no problems.

I've tried connecting to the Dell printer on two of the four laptops, running Vista, unsuccessfully. It errors with:

Windows cannot connect to the printer. Make sure that you have typed the name correctly, and the printer is connected to the network.

The Dell printer has wireless networking built in, but I would prefer to use USB. I'm mostly sure that I've installed it correctly, because it does print, just not over the network. The "server" computer and one of the laptops I've tried it on are directly connected to my wireless router through Ethernet. Is there anything that could be causing it to go wrong?

cups error log, as requested:

E [13/Jun/2011:16:23:06 -0400] Unable to remove temporary file "/var/spool/cups/tmp/.hplip" - Is a directory
E [13/Jun/2011:16:33:22 -0400] Unable to remove temporary file "/var/spool/cups/tmp/.hplip" - Is a directory
E [13/Jun/2011:16:46:31 -0400] [cups-driverd] Bad driver information file "/usr/share/cups/drv/sample.drv"!
E [13/Jun/2011:17:01:42 -0400] [cups-driverd] Bad driver information file "/usr/share/cups/drv/sample.drv"!
W [13/Jun/2011:17:25:41 -0400] Duplicate listen address "0.0.0.0" ignored!
W [13/Jun/2011:17:25:41 -0400] Duplicate listen address "::" ignored!
E [13/Jun/2011:17:25:42 -0400] Unable to remove temporary file "/var/spool/cups/tmp/.hplip" - Is a directory
E [13/Jun/2011:17:25:42 -0400] Unable to bind socket for address 0.0.0.0:631 - Address already in use.
E [13/Jun/2011:17:25:42 -0400] Unable to bind socket for address :::631 - Address already in use.
E [13/Jun/2011:17:25:42 -0400] Unable to bind broadcast socket - Address already in use.
W [13/Jun/2011:17:26:28 -0400] Duplicate listen address "0.0.0.0" ignored!
W [13/Jun/2011:17:26:28 -0400] Duplicate listen address "::" ignored!
E [13/Jun/2011:17:26:28 -0400] Unable to remove temporary file "/var/spool/cups/tmp/.hplip" - Is a directory
E [13/Jun/2011:17:26:28 -0400] Unable to bind socket for address 0.0.0.0:631 - Address already in use.
E [13/Jun/2011:17:26:28 -0400] Unable to bind socket for address :::631 - Address already in use.
E [13/Jun/2011:17:26:28 -0400] Unable to bind broadcast socket - Address already in use.
E [13/Jun/2011:17:27:22 -0400] Missing printer-uri, job-uri, or ppd-name attribute!
E [13/Jun/2011:17:27:22 -0400] Returning IPP client-error-bad-request for windows-ext (no URI) from 192.168.1.2
E [13/Jun/2011:17:30:20 -0400] Missing printer-uri, job-uri, or ppd-name attribute!
E [13/Jun/2011:17:30:20 -0400] Returning IPP client-error-bad-request for windows-ext (no URI) from 192.168.1.6
E [13/Jun/2011:17:33:39 -0400] Missing printer-uri, job-uri, or ppd-name attribute!
E [13/Jun/2011:17:33:39 -0400] Returning IPP client-error-bad-request for windows-ext (no URI) from 192.168.1.3
E [13/Jun/2011:17:37:16 -0400] Missing printer-uri, job-uri, or ppd-name attribute!
E [13/Jun/2011:17:37:16 -0400] Returning IPP client-error-bad-request for windows-ext (no URI) from 192.168.1.5
E [13/Jun/2011:18:01:11 -0400] [cups-driverd] Bad driver information file "/usr/share/cups/drv/sample.drv"!
E [13/Jun/2011:18:02:08 -0400] [cups-driverd] Bad driver information file "/usr/share/cups/drv/sample.drv"!
E [13/Jun/2011:18:03:25 -0400] [cups-driverd] Bad driver information file "/usr/share/cups/drv/sample.drv"!
E [13/Jun/2011:18:57:20 -0400] [Job 3] 
E [13/Jun/2011:18:57:25 -0400] [Job 3] 
W [13/Jun/2011:18:58:45 -0400] Duplicate listen address "0.0.0.0" ignored!
W [13/Jun/2011:18:58:45 -0400] Duplicate listen address "::" ignored!
E [13/Jun/2011:18:58:45 -0400] Unable to remove temporary file "/var/spool/cups/tmp/.hplip" - Is a directory
E [13/Jun/2011:18:58:45 -0400] Unable to bind socket for address 0.0.0.0:631 - Address already in use.
E [13/Jun/2011:18:58:45 -0400] Unable to bind socket for address :::631 - Address already in use.
E [13/Jun/2011:18:58:45 -0400] Unable to bind broadcast socket - Address already in use.
E [13/Jun/2011:19:01:54 -0400] [cups-driverd] Bad driver information file "/usr/share/cups/drv/sample.drv"!
E [13/Jun/2011:19:06:25 -0400] Missing printer-uri, job-uri, or ppd-name attribute!
E [13/Jun/2011:19:06:25 -0400] Returning IPP client-error-bad-request for windows-ext (no URI) from 192.168.1.2

cupsd.conf, also as requested:

LogLevel warn
MaxLogSize 0
SystemGroup lpadmin
# Allow remote access
Port 631
Listen /var/run/cups/cups.sock
Listen 631
# Share local printers on the local network.
Browsing On
BrowseOrder allow,deny
BrowseRemoteProtocols
BrowseAllow all
BrowseAddress @LOCAL
BrowseLocalProtocols CUPS dnssd
DefaultAuthType Basic
<Location />
  # Allow shared printing...
  Order allow,deny
  Allow @LOCAL
</Location>
<Location /admin>
  # Restrict access to the admin pages...
  Order allow,deny
</Location>
<Location /admin/conf>
  AuthType Default
  Require user @SYSTEM
  # Restrict access to the configuration files...
  Order allow,deny
</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 CUPS-Get-Document>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>
  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default CUPS-Get-Devices>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </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
    Require user @SYSTEM
    Order deny,allow
  </Limit>
  <Limit Cancel-Job CUPS-Authenticate-Job>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>
  <Limit All>
    Order deny,allow
  </Limit>
</Policy>
<Policy authenticated>
  <Limit Create-Job Print-Job Print-URI>
  AuthType Default
  Order deny,allow
</Limit>
  <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 CUPS-Get-Document>
AuthType Default
Require user @OWNER @SYSTEM
Order deny,allow
  </Limit>
  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default>
  AuthType Default
  Require user @SYSTEM
  Order deny,allow
    </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
    Require user @SYSTEM
    Order deny,allow
      </Limit>
  <Limit Cancel-Job CUPS-Authenticate-Job>
      AuthType Default
      Require user @OWNER @SYSTEM
      Order deny,allow
        </Limit>
  <Limit All>
        Order deny,allow
          </Limit>
</Policy>
share|improve this question
    
The Missing printer-uri, job-uri, or ppd-name attribute! error indicates Windows is trying to connect to a printer that doesn't exist. Are you sure the printer URL matches exactly, capital letters and all? When you browse to localhost:631/printers and click on the printer, the URL that appears in your address bar is exactly what should be entered in Windows. –  Patches Jun 14 '11 at 23:02
    
Sorry for the late response. I've tried that, and the error log gives me this: W [15/Jun/2011:07:50:29 -0400] Duplicate listen address "0.0.0.0" ignored! W [15/Jun/2011:07:50:29 -0400] Duplicate listen address "::" ignored! E [15/Jun/2011:07:50:29 -0400] Unable to bind socket for address 0.0.0.0:631 - Address already in use. E [15/Jun/2011:07:50:29 -0400] Unable to bind socket for address :::631 - Address already in use. E [15/Jun/2011:07:50:29 -0400] Unable to bind broadcast socket - Address already in use. –  Mike Jun 15 '11 at 12:08
    
that looks like something wrong in your CUPS config. Can you post /etc/cups/cupsd.conf? –  Patches Jun 15 '11 at 22:40
    
Okay, that error is because Listen 631 is redundant. Port 631 takes care of it. (My cupsd.conf didn't have it and I get that error when I add it.) But theoretically that has absolutely nothing to do with your problem. Since you seem to be doing everything right, this smells like a bug to me. You might want to run apport-bug cups to report it to the Ubuntu developers and see what they can make of it. –  Patches Jun 16 '11 at 5:48

1 Answer 1

Trying to print over Samba has always given me nothing but headaches. I suggest you use the Internet Printing Protocol (IPP) instead.

First make sure your have IPP enabled in CUPS on your print server:

  1. Browse to http://localhost:631/ on the print server machine.
  2. Go to the Administration tab.
  3. Make sure Share printers connected to this system and Allow printing from the Internet are checked.
  4. Click the Change Settings button.
  5. CUPS will restart to allow your changes to take effect.

Then, set up the printers on the Vista machines thusly:

  1. Go to Start > Devices and Printers.
  2. Click Add a printer on the toolbar.
  3. Click Add a network, wireless, or Bluetooth printer
  4. Click The printer I want isn't listed
  5. Select Select a shared printer by name
  6. Enter http://<hostname>:631/printers/<printer-name> where <hostname> is the hostname or IP address of your Ubuntu machine hosting the printer and <printer-name> is the Queue name revealed by the CUPS admin interface.
  7. Windows should connect to your printer.
  8. You'll now be prompted to select a driver for your printer. You can select the Generic manufacturer and MS Publisher Imagesetter printer driver, which will just have Windows send print jobs to CUPS in PostScript format and allow CUPS to use its driver instead, or select the driver for your printer if you need to use any advanced features it offers. (The former generally works better, IMHO.)
  9. Click OK.
  10. Windows verifies that you have successfully installed the printer. Click Next.
  11. You are given the option print a test page to verify that everything works if you'd like.
share|improve this answer
    
I've done all that. Step 7 (the actual connecting) in the Vista side of the setup does not happen, and it throws the error in the original question. –  Mike Jun 14 '11 at 3:45
    
@Mike: If you've enabled Internet printing in CUPS like I explained, your firewall might be getting in the way. Try running sudo ufw allow 631 on a terminal to unblock the CUPS port. –  Patches Jun 14 '11 at 3:48
    
Would that be the problem if one of the printers prints but the other doesn't? Because that is the case. –  Mike Jun 14 '11 at 3:54
    
The HP printer connected through CUPS prints fine. The Dell doesn't. –  Mike Jun 14 '11 at 3:54
    
@Mike: Ah, I missed that part. Go to the CUPS admin interface, and on the Administration tab click Manage Printers. Click on the printer, and then on its page select the Administration dropdown and choose Modify Printer. Click Continue on the first page that appears, then on the second page make sure Share this printer is checked. Then click Continue again, and click Modify this Printer to make the changes take effect. If sharing wasn't checked, it should work now. –  Patches Jun 14 '11 at 4:15

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.