# [Solved] usb scanner and dymo printer visible but don't work

## becon

Hello,

I just reinstalled Gentoo. Previously, I had my HP usb scanner working without any problem. The Dymo Labelwriter Turbo 330 was working as well.

Now xsane doesn't see the scanner. Cups sees the Dymo printer but Open Office can't print to it.

Here is the result of "# lsusb"

```

# lsusb

Bus 001 Device 005: ID 03f0:0401 Hewlett-Packard ScanJet 5200c

Bus 001 Device 003: ID 0424:2504 Standard Microsystems Corp.

Bus 001 Device 002: ID 0922:0008 Dymo-CoStar Corp.

Bus 001 Device 001: ID 0000:0000

```

Here is my emerge --info

```

Portage 2.1.2.7 (default-linux/amd64/2007.0/desktop, gcc-4.1.2, glibc-2.5-r3, 2.6.21-gentoo-r3 x86_64)

=================================================================

System uname: 2.6.21-gentoo-r3 x86_64 AMD Athlon(tm) 64 X2 Dual Core Processor 4800+

Gentoo Base System release 1.12.9

Timestamp of tree: Tue, 19 Jun 2007 00:50:01 +0000

ccache version 2.4 [enabled]

dev-lang/python:     2.4.4-r4

dev-python/pycrypto: 2.0.1-r5

dev-util/ccache:     2.4-r7

sys-apps/sandbox:    1.2.17

sys-devel/autoconf:  2.13, 2.61

sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10

sys-devel/binutils:  2.16.1-r3

sys-devel/gcc-config: 1.3.14

sys-devel/libtool:   1.5.22

virtual/os-headers:  2.6.17-r2

ACCEPT_KEYWORDS="amd64"

AUTOCLEAN="yes"

CBUILD="x86_64-pc-linux-gnu"

CFLAGS="-march=k8 -O2 -pipe"

CHOST="x86_64-pc-linux-gnu"

CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"

CONFIG_PROTECT_MASK="/etc/env.d /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c"

CXXFLAGS="-march=k8 -O2 -pipe"

DISTDIR="/usr/portage/distfiles"

FEATURES="ccache distlocks metadata-transfer sandbox sfperms strict"

GENTOO_MIRRORS="http://gentoo.osuosl.org/ ftp://ftp.gtlib.gatech.edu/pub/gentoo ftp://ftp.ussg.iu.edu/pub/linux/gentoo http://gentoo.chem.wisc.edu/gentoo/ http://cudlug.cudenver.edu/gentoo/ http://mirrors.acm.cs.rpi.edu/gentoo/ http://open-systems.ufl.edu/mirrors/gentoo http://prometheus.cs.wmich.edu/gentoo http://mirror.usu.edu/mirrors/gentoo/ ftp://lug.mtu.edu/gentoo http://mirror.mcs.anl.gov/pub/gentoo/ http://gentoo.cites.uiuc.edu/pub/gentoo/ http://mirror.utdlug.org/linux/distributions/gentoo/ ftp://mirror.utdlug.org/linux/distributions/gentoo/ "

MAKEOPTS="-j3"

PKGDIR="/usr/portage/packages"

PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*"

PORTAGE_TMPDIR="/var/tmp"

PORTDIR="/usr/portage"

SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"

USE="X acl acpi alsa amd64 arts berkdb bitmap-fonts cairo cdr cli cracklib crypt cups dbus dri dvd dvdr dvdread eds emboss encode esd evo fam firefox flash fortran gdbm gif gnome gnuplot gpm gstreamer gtk hal iconv ipv6 isdnlog jpeg kde kerberos ldap libg++ lirc mad midi mikmod mmx mp3 mpeg mplayer mudflap ncurses nls nptl nptlonly nsplugin ogg opengl openmp oss pam pcre pdf perl png pppd python qt3 qt3support qt4 quicktime readline reflection sdl session spell spl sse sse2 ssl svg tcl tcpd tiff tk truetype truetype-fonts type1-fonts unicode vorbis xinerama xml xorg xv" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="apm ark chips cirrus cyrix dummy fbdev glint i128 i810 mach64 mga neomagic nv r128 radeon rendition s3 s3virge savage siliconmotion sis sisusb tdfx tga trident tseng v4l vesa vga via vmware voodoo"

Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY

```

Could there be a kernel option that I missed? Unplugging the scanner and then plugging it back in gives the following dmesg response:

```

usb 1-6.2: USB disconnect, address 4

usb 1-6.2: new full speed USB device using ohci_hcd and address 5

usb 1-6.2: configuration #1 chosen from 1 choice

usb 1-6.2: USB disconnect, address 5

usb 1-6.2: new full speed USB device using ohci_hcd and address 6

usb 1-6.2: configuration #1 chosen from 1 choice

```

Any help in trouble shooting this problem would be most appreciated. 

Thank you.Last edited by becon on Thu Jun 21, 2007 11:34 pm; edited 1 time in total

----------

## didymos

What versions of cups and sane do you currently have?  Also, any error messages from OO or /var/log/cups would be useful.

----------

## becon

Thanks for your response. Here is the error from Cups. I am running Cups 1.2.10, sane-backends 1.0.18-r2, xsane 0.994, and OO 2.2.

```

E [18/Jun/2007:21:24:33 -0500] Filter "foomatic-rip" for printer "DYMO_LabelWriter_330_Turbo_USB_1" not available: No such file or directory

```

I have the ppd file located in /usr/share/cups/model/.

```

# ls /usr/share/cups/model

Dymo-CoStar-LabelWriter_XLplus-pbm2lwxl.ppd  okidata9.ppd

PostscriptColor.ppd                          pxlcolor.ppd

deskjet.ppd                                  pxlmono.ppd

deskjet2.ppd                                 stcolor.ppd

dymo.ppd                                     stcolor2.ppd

epson24.ppd                                  stphoto.ppd

epson9.ppd                                   stphoto2.ppd

foomatic-ppds                                zebra.ppd

hp_color_LaserJet_4650.ppd                   zebraep1.ppd

laserjet.ppd                                 zebraep2.ppd

okidat24.ppd

```

The permissions are the same as all other ppd files.  The foomatic-ppds directory is empty.

Thanks again.

----------

## becon

I forgot to mention that when I first reinstalled Gentoo, I used the gentoo-sources-2.6.20-r8 for the kernel.

But when I was having trouble with the USB, I went to the forums and found that some people were having trouble with that version of the kernel and USB. So I upgraded the kernel to gentoo-sources-2.6.21-r3. I have not re-emerged the system after installing the new kernel. Do you think that would help? The only module that I know of that needs to be emerged each time the kernel is compiled is the nvidia-drivers.

----------

## didymos

No, you don't need to re-emerge the system for a kernel upgrade.  It's usually recommended when you update glibc or gcc or maybe binutils. However, even then, it's not necessarily necessary (yes, that's deliberate).  My rule of thumb is to do it for gcc and glibc, but only if it's a fairly big upgrade, like from gcc-4.0 to gcc-4.1.  linux-headers updates are also a good time for it, since you need to rebuild glibc for any of the new stuff in the headers to be usable.

----------

## didymos

What foomatic packages do you currently have installed?

----------

## becon

I didn't have any of the foomatic packages installed, so I installed the following:

```

 net-print/foomatic-db

      Latest version available: 20060720

      Latest version installed: [ Not Installed ]

      Size of files: 12,055 kB

      Homepage:      http://www.linuxprinting.org/foomatic.html

      Description:   Printer information files for foomatic-db-engine to generate ppds

      License:       GPL-2

*  net-print/foomatic-db-engine

      Latest version available: 3.0.20060720

      Latest version installed: [ Not Installed ]

      Size of files: 306 kB

      Homepage:      http://www.linuxprinting.org/foomatic.html

      Description:   Generates ppds out of xml foomatic printer description files

      License:       GPL-2

*  net-print/foomatic-db-ppds

      Latest version available: 20060720

      Latest version installed: [ Not Installed ]

      Size of files: 12,055 kB

      Homepage:      http://www.linuxprinting.org/foomatic.html

      Description:   linuxprinting.org PPD files for postscript printers

      License:       GPL-2

*  net-print/foomatic-filters

      Latest version available: 3.0.20060720

      Latest version installed: 3.0.20060720

      Size of files: 161 kB

      Homepage:      http://www.linuxprinting.org/foomatic.html

      Description:   Foomatic wrapper scripts

      License:       GPL-2

*  net-print/foomatic-filters-ppds

      Latest version available: 20070501

      Latest version installed: 20070501

      Size of files: 12,143 kB

      Homepage:      http://www.linuxprinting.org/foomatic.html

      Description:   linuxprinting.org PPD files for non-postscript printers

      License:       GPL-2

```

I restarted /etc/init.d/cupsd and then tried to print the test page on the Dymo printer. Here is the error_log output:

```

I [19/Jun/2007:18:58:55 -0500] Loading job cache file "/var/cache/cups/job.cache"...

I [19/Jun/2007:18:58:55 -0500] Full reload complete.

I [19/Jun/2007:18:58:55 -0500] Listening to 127.0.0.1:631 on fd 2...

I [19/Jun/2007:18:58:55 -0500] Listening to ::1:631 on fd 3...

I [19/Jun/2007:18:58:55 -0500] Listening to /var/run/cups/cups.sock on fd 4...

I [19/Jun/2007:18:59:10 -0500] commptr="?op=print-test-page"

I [19/Jun/2007:18:59:10 -0500] Started "/usr/libexec/cups/cgi-bin/printers.cgi" (pid=170

30)

I [19/Jun/2007:18:59:10 -0500] Adding start banner page "none" to job 12.

I [19/Jun/2007:18:59:10 -0500] Adding end banner page "none" to job 12.

I [19/Jun/2007:18:59:10 -0500] Job 12 queued on "DYMO_LabelWriter_330_Turbo_USB_1" by "r

oot".

I [19/Jun/2007:18:59:10 -0500] Started filter /usr/libexec/cups/filter/pstops (PID 17031

) for job 12.

I [19/Jun/2007:18:59:10 -0500] Started filter /usr/libexec/cups/filter/foomatic-rip (PID

 17032) for job 12.

I [19/Jun/2007:18:59:10 -0500] Started backend /usr/libexec/cups/backend/usb (PID 17033)

 for job 12.

E [19/Jun/2007:18:59:10 -0500] PID 17032 (/usr/libexec/cups/filter/foomatic-rip) stopped

 with status 1!

I [19/Jun/2007:18:59:10 -0500] Hint: Try setting the LogLevel to "debug" to find out mor

e.

I [19/Jun/2007:18:59:12 -0500] commptr=""

I [19/Jun/2007:18:59:12 -0500] Started "/usr/libexec/cups/cgi-bin/printers.cgi" (pid=170

47)

```

What is foomatic-rip? I don't ever remember doing this for cups before, has it changed?

The error_log output below shows a problem with the "renderer" ? I just pushed the test page button. I assume that the Dymo test page is smaller than the regular test page for a regular printer.

I turned debugging on and retried printing the test page. A portion of the error log is posted below. Thanks again for your help.

```

D [19/Jun/2007:19:07:14 -0500] [Job 13] Loading NimbusRomNo9L-Regu font from /usr/share/fonts/default/ghostscript/n021003l.pfb... 3223288 1809529 2053944 766348 1 done.

D [19/Jun/2007:19:07:14 -0500] [Job 13] Loading NimbusSanL-ReguCondItal font from /usr/share/fonts/default/ghostscript/n019063l.pfb... 3256568 1923023 2094312 802266 1 done.

D [19/Jun/2007:19:07:14 -0500] Discarding unused job-progress event...

D [19/Jun/2007:19:07:14 -0500] [Job 13] sh: pbm2lwxl: command not found

D [19/Jun/2007:19:07:14 -0500] [CGI] Template file is "/usr/share/cups/templates/test-page.tmpl"...

D [19/Jun/2007:19:07:14 -0500] [CGI] Starting at file position 0...

D [19/Jun/2007:19:07:14 -0500] [CGI] "{SECTION}" at 48...

D [19/Jun/2007:19:07:14 -0500] [CGI] "{printer_name}" at 63...

D [19/Jun/2007:19:07:14 -0500] [CGI] "{printer_name}" at 80...

D [19/Jun/2007:19:07:14 -0500] [CGI] "{job_id}" at 89...

D [19/Jun/2007:19:07:14 -0500] [CGI] Returning at file position 99 on EOF...

D [19/Jun/2007:19:07:14 -0500] [CGI] cgiCopyTemplateLang(tmpl="trailer.tmpl")

D [19/Jun/2007:19:07:14 -0500] [CGI] locale="en_us"...

D [19/Jun/2007:19:07:14 -0500] [CGI] Template file is "/usr/share/cups/templates/trailer.tmpl"...

D [19/Jun/2007:19:07:14 -0500] [CGI] Starting at file position 0...

D [19/Jun/2007:19:07:14 -0500] [CGI] Returning at file position 614 on EOF...

D [19/Jun/2007:19:07:14 -0500] [Job 13] renderer return value: 127

D [19/Jun/2007:19:07:14 -0500] [Job 13] renderer received signal: 127

D [19/Jun/2007:19:07:14 -0500] [Job 13] tail process done writing data to STDOUT

D [19/Jun/2007:19:07:14 -0500] [Job 13] KID4 finished

D [19/Jun/2007:19:07:14 -0500] [Job 13] KID4 exited with status 0

D [19/Jun/2007:19:07:14 -0500] [Job 13] KID3 exited with status 1

D [19/Jun/2007:19:07:14 -0500] [Job 13] Renderer exit stat: 1

D [19/Jun/2007:19:07:14 -0500] [Job 13] Process dying with "The renderer command line returned an unrecognized error code 127.", exit stat: 1

D [19/Jun/2007:19:07:14 -0500] [Job 13] error: Illegal seek (29)

D [19/Jun/2007:19:07:14 -0500] [Job 13] The renderer command line returned an unrecognized error code 127.

D [19/Jun/2007:19:07:14 -0500] [Job 13] Renderer process finished

D [19/Jun/2007:19:07:14 -0500] [Job 13] Killing process 17113 (KID3)

D [19/Jun/2007:19:07:14 -0500] [Job 13] Process dying with "Error closing renderer", exit stat: 1

D [19/Jun/2007:19:07:14 -0500] [Job 13] error: Bad file descriptor (9)

D [19/Jun/2007:19:07:14 -0500] [Job 13] Error closing renderer

E [19/Jun/2007:19:07:14 -0500] PID 17108 (/usr/libexec/cups/filter/foomatic-rip) stopped with status 1!

D [19/Jun/2007:19:07:14 -0500] PID 17109 (/usr/libexec/cups/backend/usb) exited with no errors.

D [19/Jun/2007:19:07:14 -0500] [Job 13] File 0 is complete.

D [19/Jun/2007:19:07:14 -0500] Discarding unused printer-state-changed event...

D [19/Jun/2007:19:07:14 -0500] Discarding unused job-stopped event...

D [19/Jun/2007:19:07:15 -0500] Unloading job 13...

D [19/Jun/2007:19:07:16 -0500] cupsdReadClient: 8 GET /printers/DYMO_LabelWriter_330_Turbo_USB_1 HTTP/1.1

D [19/Jun/2007:19:07:16 -0500] cupsdReadClient: 8 Browser asked for language "en-us.utf-8"...

D [19/Jun/2007:19:07:16 -0500] cupsdAuthorize: username="root"

I [19/Jun/2007:19:07:16 -0500] commptr=""

D [19/Jun/2007:19:07:16 -0500] CGI /usr/libexec/cups/cgi-bin/printers.cgi started - PID = 17122

I [19/Jun/2007:19:07:16 -0500] Started "/usr/libexec/cups/cgi-bin/printers.cgi" (pid=17122)

D [19/Jun/2007:19:07:16 -0500] cupsdSendCommand: 8 file=13

D [19/Jun/2007:19:07:16 -0500] cupsdAcceptClient: 14 from localhost (Domain)

D [19/Jun/2007:19:07:16 -0500] cupsdReadClient: 14 POST / HTTP/1.1

D [19/Jun/2007:19:07:16 -0500] cupsdAuthorize: No authentication data provided.

D [19/Jun/2007:19:07:16 -0500] CUPS-Get-Default

D [19/Jun/2007:19:07:16 -0500] cupsdProcessIPPRequest: 14 status_code=0 (successful-ok)

D [19/Jun/2007:19:07:16 -0500] [CGI] show_printer(http=0x543810, printer="DYMO_LabelWriter_330_Turbo_USB_1")

D [19/Jun/2007:19:07:16 -0500] cupsdReadClient: 14 POST / HTTP/1.1

D [19/Jun/2007:19:07:16 -0500] cupsdAuthorize: No authentication data provided.

D [19/Jun/2007:19:07:16 -0500] Get-Printer-Attributes ipp://localhost/printers/DYMO_LabelWriter_330_Turbo_USB_1

D [19/Jun/2007:19:07:16 -0500] cupsdProcessIPPRequest: 14 status_code=0 (successful-ok)

D [19/Jun/2007:19:07:16 -0500] [CGI] cgiCopyTemplateLang(tmpl="header.tmpl")

D [19/Jun/2007:19:07:16 -0500] [CGI] locale="en_us"...

D [19/Jun/2007:19:07:16 -0500] [CGI] Template file is "/usr/share/cups/templates/header.tmpl"...

D [19/Jun/2007:19:07:16 -0500] [CGI] Starting at file position 0...

....................

```

And here is the tail end....

```

D [19/Jun/2007:19:07:24 -0500] [CGI] Starting "{SETTINGS_ERROR?" at 1850, result=0...

D [19/Jun/2007:19:07:24 -0500] [CGI] Skip first part...

D [19/Jun/2007:19:07:24 -0500] [CGI] Starting at file position 1850...

D [19/Jun/2007:19:07:24 -0500] [CGI] "{SETTINGS_MESSAGE}" at 1871...

D [19/Jun/2007:19:07:24 -0500] [CGI] "{SETTINGS_ERROR}" at 1904...

D [19/Jun/2007:19:07:24 -0500] [CGI] Returning at file position 1918 on character ':'...

D [19/Jun/2007:19:07:24 -0500] [CGI] Output second part...

D [19/Jun/2007:19:07:24 -0500] [CGI] Starting at file position 1918...

D [19/Jun/2007:19:07:24 -0500] [CGI] "{?remote_printers}" at 2117...

D [19/Jun/2007:19:07:24 -0500] [CGI] "{?share_printers}" at 2223...

D [19/Jun/2007:19:07:24 -0500] [CGI] "{?remote_admin}" at 2337...

D [19/Jun/2007:19:07:24 -0500] [CGI] "{?user_cancel_any}" at 2435...

D [19/Jun/2007:19:07:24 -0500] [CGI] "{?debug_logging}" at 2552...

D [19/Jun/2007:19:07:24 -0500] [CGI] Returning at file position 2706 on character '}'...

D [19/Jun/2007:19:07:24 -0500] [CGI] Finished "{SETTINGS_ERROR?", out=0x2b03f593c760...

D [19/Jun/2007:19:07:24 -0500] [CGI] Returning at file position 2728 on EOF...

D [19/Jun/2007:19:07:24 -0500] [CGI] cgiCopyTemplateLang(tmpl="trailer.tmpl")

D [19/Jun/2007:19:07:24 -0500] [CGI] locale="en_us"...

D [19/Jun/2007:19:07:24 -0500] [CGI] Template file is "/usr/share/cups/templates/trailer.tmpl"...

D [19/Jun/2007:19:07:24 -0500] [CGI] Starting at file position 0...

D [19/Jun/2007:19:07:24 -0500] [CGI] Returning at file position 614 on EOF...

D [19/Jun/2007:19:07:28 -0500] cupsdReadClient: 8 GET /admin/log/error_log HTTP/1.1

D [19/Jun/2007:19:07:28 -0500] cupsdReadClient: 8 Browser asked for language "en-us.utf-8"...

D [19/Jun/2007:19:07:28 -0500] cupsdAuthorize: username="root"

```

Thanks again.

----------

## becon

Okay, I used the other Dymo ppd file and the printer is now working. I am not sure if that was the only problem, but I am glad that I am getting a response. 

Thanks again for your help. I really do appreciate your taking the time to help a stranger.

Do you have any ideas about the scanner?  They have changed the kernel options regarding hotplugging and scanners. The scanner use to work. 

Thanks again.

----------

## didymos

No, not sure about the scanner.  As to foomatic-rip, it a sort of universal wrapper/filter that works with cups,lpr,lprng, etc.  It also translates PostScript into whatever language the printer actually uses.  The ppd files are the instructions on how to translate for a particular printer. I'm pretty sure CUPS has always used it, but maybe the ebuild dependencies changed and the foomatic stuff didn't get pulled in.  Oh, wait, I just checked your emerge --info.  You don't have "ppds" in USE.  That's why they weren't pulled in.

----------

## becon

Ah! I forgot the USE flag for ppds. It's always the little things that'll get you. Thanks for catching it.

----------

## becon

I got my scanner to work. Again it was a small thing I had forgotten. I did not have my USB use flag set when I emerged sane-backends. Once I corrected for this everything worked fine. 

Regarding the Dymo printer, it turns out that I did have the ppds flag set. Switching ppd files seemed to do the job.

Thanks again for the help.

----------

