[Bug 1099184] Re: Avahi reports IPv6/IPv4 and "dnssd" CUPS backend only tries IPv6, no IPv4 fallback

Keith Wansbrough 1099184 at bugs.launchpad.net
Fri Dec 20 23:15:20 UTC 2013


This affects me as well, using a Canon MG3250 over WiFi. The printer
supports both IPv4 and IPv6, but CUPS is only able to connect to it when
it chooses the IPv4 address, which appears to be about 50% of the time.

I was able to work around the problem by going to my printer's web
control panel, going to the Network Settings page, and choosing "Disable
IPv6". After a few seconds, Avahi (avahi-browse -a -t -r) no longer
reports IPv6 support for my printer, and everything works splendidly.

Obviously a fix for Avahi or CUPS would be preferable.

/var/log/cups/error.log shows the following for success:

D [20/Dec/2013:23:05:05 +0000] [Job 1433] Connecting to 192.168.0.16:631
I [20/Dec/2013:23:05:05 +0000] [Job 1433] Connecting to printer.
D [20/Dec/2013:23:05:05 +0000] [Job 1433] Set job-printer-state-message to "Connecting to printer.", current level=INFO
D [20/Dec/2013:23:05:05 +0000] Discarding unused job-progress event...
D [20/Dec/2013:23:05:05 +0000] Discarding unused printer-state-changed event...
D [20/Dec/2013:23:05:05 +0000] [Job 1433] update_reasons(attr=0(), s="-cups-certificate-error")
D [20/Dec/2013:23:05:05 +0000] [Job 1433] update_reasons(attr=0(), s="-connecting-to-device")
D [20/Dec/2013:23:05:05 +0000] [Job 1433] STATE: -connecting-to-device
I [20/Dec/2013:23:05:05 +0000] [Job 1433] Connected to printer.
D [20/Dec/2013:23:05:05 +0000] [Job 1433] Set job-printer-state-message to "Connected to printer.", current level=INFO
D [20/Dec/2013:23:05:05 +0000] [Job 1433] Connected to 192.168.0.16:631...

and the following for failure:

D [20/Dec/2013:23:05:05 +0000] [Job 1433] Connecting to 192.168.0.16:631
I [20/Dec/2013:23:05:05 +0000] [Job 1433] Connecting to printer.
D [20/Dec/2013:23:05:05 +0000] [Job 1433] Set job-printer-state-message to "Connecting to printer.", current level=INFO
D [20/Dec/2013:23:05:05 +0000] Discarding unused job-progress event...
D [20/Dec/2013:23:05:05 +0000] Discarding unused printer-state-changed event...
D [20/Dec/2013:23:05:05 +0000] [Job 1433] update_reasons(attr=0(), s="-cups-certificate-error")
D [20/Dec/2013:23:05:05 +0000] [Job 1433] update_reasons(attr=0(), s="-connecting-to-device")
D [20/Dec/2013:23:05:05 +0000] [Job 1433] STATE: -connecting-to-device
I [20/Dec/2013:23:05:05 +0000] [Job 1433] Connected to printer.
D [20/Dec/2013:23:05:05 +0000] [Job 1433] Set job-printer-state-message to "Connected to printer.", current level=INFO
D [20/Dec/2013:23:05:05 +0000] [Job 1433] Connected to 192.168.0.16:631...

I am using CUPS 1.5.3 on Ubuntu 12.04LTS.

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to avahi in Ubuntu.
https://bugs.launchpad.net/bugs/1099184

Title:
  Avahi reports IPv6/IPv4 and "dnssd" CUPS backend only tries IPv6, no
  IPv4 fallback

Status in “avahi” package in Ubuntu:
  Confirmed

Bug description:
  lsb_release -rd
  Description:    Ubuntu 12.04.1 LTS
  Release:        12.04
  ---------------------------------
  avahi-daemon 0.6.30-5ubuntu2
  cups 1.5.3-0ubuntu6
  --------------------------------

  
  Avahi for  default publishes services also in IPv6 as in /etc/avahi/avahi-daemon.conf there is
  use-ipv6=yes

  At the same time services are listening on IPv4 addresses only.

  Cups is able to discover published printers via dnssd protocol but its
  ipp backend prints only on the IPv6 resolved address which does not
  answer and it does not try the IPv4 address.

  ------------------------------------
  Excerpt from "avahi-browse -a -t -r"  to show the IPv6 and IPv4 addresses

  +  wlan0 IPv6 Hewlett-Packard HP LaserJet 1100 @ hjemme     Internet Printer     local
  +  wlan0 IPv4 Hewlett-Packard HP LaserJet 1100 @ hjemme     Internet Printer     local
  +  wlan0 IPv6 MobilIgor5a [00:26:82:9d:b9:6d]               Workstation          local
  +  wlan0 IPv6 hjemme [00:40:f4:ff:55:32]                    Workstation          local

  [....]

  =  wlan0 IPv6 Hewlett-Packard HP LaserJet 1100 @ hjemme     Internet Printer     local
     hostname = [hjemme.local]
     address = [fe80::240:f4ff:feff:5532]
     port = [631]
     txt = ["printer-type=0x900E" "printer-state=3" "Scan=F" "Sort=F" "Bind=F" "Punch=F" "Collate=F" "Copies=F" "Staple=F" "Duplex=F" "Color=T" "Fax=F" "Binary=F" "Transparent=F" "TLS=1.2" "UUID=1577ef95-eecb-3eae-6d02-aa29003eb546" "URF=DM3" "pdl=application/octet-stream,application/pdf,application/postscript,image/jpeg,image/png,image/urf" "product=(HP LaserJet 1100xi Printer)" "priority=0" "note=hjemme" "adminurl=http://hjemme.local:631/printers/Hewlett-Packard-HP-LaserJet-1100" "ty=HP LaserJet 1100, hpcups 3.12.2" "rp=printers/Hewlett-Packard-HP-LaserJet-1100" "qtotal=1" "txtvers=1"]
  =  wlan0 IPv6 hjemme                                        Remote Disk Management local
     hostname = [hjemme.local]
     address = [fe80::240:f4ff:feff:5532]
     port = [22]
     txt = []
  =  wlan0 IPv6 hjemme [00:40:f4:ff:55:32]                    Workstation          local
     hostname = [hjemme.local]
     address = [fe80::240:f4ff:feff:5532]
     port = [9]
     txt = []
  =  wlan0 IPv4 Hewlett-Packard HP LaserJet 1100 @ hjemme     Internet Printer     local
     hostname = [hjemme.local]
     address = [192.168.1.2]
     port = [631]
     txt = ["printer-type=0x900E" "printer-state=3" "Scan=F" "Sort=F" "Bind=F" "Punch=F" "Collate=F" "Copies=F" "Staple=F" "Duplex=F" "Color=T" "Fax=F" "Binary=F" "Transparent=F" "TLS=1.2" "UUID=1577ef95-eecb-3eae-6d02-aa29003eb546" "URF=DM3" "pdl=application/octet-stream,application/pdf,application/postscript,image/jpeg,image/png,image/urf" "product=(HP LaserJet 1100xi Printer)" "priority=0" "note=hjemme" "adminurl=http://hjemme.local:631/printers/Hewlett-Packard-HP-LaserJet-1100" "ty=HP LaserJet 1100, hpcups 3.12.2" "rp=printers/Hewlett-Packard-HP-LaserJet-1100" "qtotal=1" "txtvers=1"]

  ----------------
  Excerpt from /var/log/cups/error_log to show that only IPv6 address is tried

  I [13/Jan/2013:18:02:55 +0100] [Job 61] Started backend /usr/lib/cups/backend/dnssd (PID 7179)
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Resolving "Hewlett-Packard HP LaserJet 1100 @ hjemme._ipp._tcp.local"...
  D [13/Jan/2013:18:02:55 +0100] [Job 61] STATE: +connecting-to-device
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Resolving "Hewlett-Packard HP LaserJet 1100 @ hjemme", regtype="_ipp._tcp", domain="local."...
  D [13/Jan/2013:18:02:55 +0100] [Job 61] PPD uses qualifier 'Gray.Plain.'
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Calling FindDeviceById(LaserJet_1100xi_Printer)
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Failed to send: org.freedesktop.ColorManager.Failed:device id 'LaserJet_1100xi_Printer' does not exists
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Failed to get profile filename!
  I [13/Jan/2013:18:02:55 +0100] [Job 61] no profiles specified in PPD
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Set job-printer-state-message to "no profiles specified in PPD", current level=INFO
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Ghostscript command line: /usr/bin/gs -dQUIET -dPARANOIDSAFER -dNOPAUSE -dBATCH -dNOINTERPOLATE -sDEVICE=cups -sstdout=%stderr -sOutputFile=%stdout -sMediaType=Plain -sOutputType=0 -r600x600 -dMediaPosition=7 -dDEVICEWIDTHPOINTS=595 -dDEVICEHEIGHTPOINTS=841 -dcupsBitsPerColor=1 -dcupsColorOrder=0 -dcupsColorSpace=3 -dcupsRowCount=1 -dcupsRowStep=2 -dcupsInteger0=26 -scupsPageSizeName=A4 -I/usr/share/cups/fonts -c -f -_
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[0]="CUPS_CACHEDIR=/var/cache/cups"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[1]="CUPS_DATADIR=/usr/share/cups"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[2]="CUPS_DOCROOT=/usr/share/cups/doc-root"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[3]="CUPS_FONTPATH=/usr/share/cups/fonts"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[4]="CUPS_REQUESTROOT=/var/spool/cups"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[5]="CUPS_SERVERBIN=/usr/lib/cups"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[6]="CUPS_SERVERROOT=/etc/cups"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[7]="CUPS_STATEDIR=/var/run/cups"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[8]="HOME=/var/spool/cups/tmp"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[9]="PATH=/usr/lib/cups/filter:/usr/bin:/usr/sbin:/bin:/usr/bin"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[10]="SERVER_ADMIN=root at MobilIgor5a"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[11]="SOFTWARE=CUPS/1.5.3"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[12]="USER=root"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[13]="CUPS_SERVER=/var/run/cups/cups.sock"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[14]="CUPS_ENCRYPTION=IfRequested"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[15]="IPP_PORT=631"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[16]="CHARSET=utf-8"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[17]="LANG=en_US.UTF-8"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[18]="PPD=/etc/cups/ppd/LaserJet_1100xi_Printer.ppd"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[19]="RIP_MAX_CACHE=128m"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[20]="CONTENT_TYPE=application/pdf"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[21]="DEVICE_URI=dnssd://Hewlett-Packard%20HP%20LaserJet%201100%20%40%20hjemme._ipp._tcp.local/cups"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[22]="PRINTER_INFO=LaserJet_1100xi_Printer"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[23]="PRINTER_LOCATION=MobilIgor5a"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[24]="PRINTER=LaserJet_1100xi_Printer"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[25]="PRINTER_STATE_REASONS=none"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[26]="CUPS_FILETYPE=document"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[27]="FINAL_CONTENT_TYPE=printer/LaserJet_1100xi_Printer"
  D [13/Jan/2013:18:02:55 +0100] [Job 61] envp[28]="AUTH_INFO_REQUIRED=none"
  I [13/Jan/2013:18:02:55 +0100] [Job 61] Start rendering...
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Set job-printer-state-message to "Start rendering...", current level=INFO
  I [13/Jan/2013:18:02:55 +0100] [Job 61] Processing page 1...
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Set job-printer-state-message to "Processing page 1...", current level=INFO
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Resolved as "ipp://[fe80::240:f4ff:feff:5532]:631/printers/Hewlett-Packard-HP-LaserJet-1100"...
  D [13/Jan/2013:18:02:55 +0100] [Job 61] STATE: -connecting-to-device,offline-report
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Executing backend "/usr/lib/cups/backend/ipp"...
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Sending stdin for job...
  D [13/Jan/2013:18:02:55 +0100] [Job 61] update_reasons(attr=0(), s="+connecting-to-device")
  d [13/Jan/2013:18:02:55 +0100] [Job 61] op='+', new_reasons=1, state_reasons=1
  D [13/Jan/2013:18:02:55 +0100] [Job 61] STATE: +connecting-to-device
  D [13/Jan/2013:18:02:55 +0100] [Job 61] Looking up "fe80::240:f4ff:feff:5532"...
  D [13/Jan/2013:18:02:55 +0100] [Job 61] PAGE: 1 1
  D [13/Jan/2013:18:02:57 +0100] [Job 61] prnt/hpcups/HPCupsFilter.cpp 686: First raster data plane..DEBUG2: hrDeviceDesc="Unknown"
  D [13/Jan/2013:18:02:59 +0100] [Job 61] prtGeneralCurrentLocalization type is 0, expected 2!
  D [13/Jan/2013:18:02:59 +0100] [Job 61] backendWaitLoop(snmp_fd=6, addr=0x7f9b29cfde68, side_cb=0x7f9b28cb8040)
  D [13/Jan/2013:18:02:59 +0100] [Job 61] Connecting to fe80::240:f4ff:feff:5532:631
  I [13/Jan/2013:18:02:59 +0100] [Job 61] Connecting to printer.
  D [13/Jan/2013:18:02:59 +0100] [Job 61] Set job-printer-state-message to "Connecting to printer.", current level=INFO
  D [13/Jan/2013:18:02:59 +0100] [Job 61] Connection error: Invalid argument
  E [13/Jan/2013:18:02:59 +0100] [Job 61] The printer is not responding.
  D [13/Jan/2013:18:02:59 +0100] [Job 61] Set job-printer-state-message to "The printer is not responding.", current level=ERROR

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/avahi/+bug/1099184/+subscriptions



More information about the foundations-bugs mailing list