usb printer and cups

daringturtle

New Member


Messages: 10

I'm trying to set up my hp 6210 officejet all-in-one printer.
I just installed freebsd 7.1, am using KDE 4.1 desktop, cups 1.3.9 and hplip 2.8.2 on my Gateway (amd64 processor) computer. I built a custom kernel without "device ulpt" because my printer is connected with a usb cable. I'm new to FreeBSD and Linux. When I run hp-setup everything is fine until the end I get this message:

Code:
lpr: Unable to connect to /var/run/printer: No such file or directory           
lpr: Check to see if the master 'lpd' process is running.                       
jobs queued, but cannot start daemon.                                           
Done.
Running hp-check reveals i'm missing many dependencies. I don't know how to install them on FreeBSD. I'm not even sure this is the problem, but my best guess. After reading sideburns post"setting up usb printer" and following discussion,i'm starting to think cups is not the way to go. I found a driver with hp setup(possibly under hplip, format(?) ppd.gz), but am not sure how put it where it needs to be, if i don't use cups. I'd appreciate any help/suggestions. I'll copy hp-check results, as well as devfs.rules and rc.conf files below.

thanks in advance for any help,
Devin Barney

----------------------------------------------------------------------------------------
/etc/devfs.rules:
----------------------------------------------------------------------------------------
Code:
# cat /etc/devfs.rules
#
# created file according to directions after pkg_add -r cups
# 4/30/09
#
[system=10]
add path 'unlpt*' mode 0660 group cups
add path 'ulpt*' mode 0660 group cups
add path 'lpt*' mode 0660 group cups
add path 'usb*' group cups
add path 'usb*' mode 0660
add path 'ugen*' group cups
add path 'ugen*' mode 0660
-------------------------------------------------------------------------------------------------------------

/etc/rc.conf:
---------------------------------------------------------------------------------------------------------------
Code:
# cat /etc/rc.conf

# -- sysinstall generated deltas -- # Wed Apr 29 06:17:01 2009
# Created: Wed Apr 29 06:17:01 2009
# Enable network daemons for user convenience.
# Please make all changes to this file, not to /etc/defaults/rc.conf.
# This file now contains just the overrides from /etc/defaults/rc.conf.
hostname=".domain.actdsltmp"
ifconfig_vr0="DHCP"
ipv6_enable="YES"
keymap="us.iso"
moused_enable="NO"
moused_flags=" "
moused_port="/dev/mse0"
#
#added by djb 4/30/09
cupsd_enable="YES"
devfs_system_ruleset="system"
#
# -- sysinstall generated deltas -- # Wed Apr 29 15:49:52 2009
keymap="us.pc-ctrl"

# -- sysinstall generated deltas -- # Thu Apr 30 10:46:24 2009
keymap="us.pc-ctrl"
hpiod_enable="YES"
hpssd_enable="YES"
----------------------------------------------------------------------------------------------

Here is my hp-check results:

Code:
---------------
| SYSTEM INFO |
---------------

Basic system information:
FreeBSD .domain.actdsltmp 7.1-RELEASE FreeBSD 7.1-RELEASE #0: Thu Apr 30 12:39:11 MDT 2009     [email]root@.domain.actd[/email]sltmp:/usr/obj/usr/src/sys/MYKERNEL  amd64      

Distribution:
unknown 0.0  

HPOJ running?
No, HPOJ is not running (OK).

Checking Python version...
OK, version 2.5.2 installed

Checking PyQt version...
OK, version 3.17 installed.

Checking SIP version...
OK, Version 4.7.4 installed

Checking for CUPS...
Status: scheduler is running
Version: 1.3.9


------------------------------------
| COMPILE AND RUNTIME DEPENDENCIES |
------------------------------------

note: To check for compile-time only dependencies, re-run hp-check with the -c parameter (ie, hp-check -c).                                                     
note: To check for run-time only dependencies, re-run hp-check with the -r parameter (ie, hp-check -r).                                                         

Checking for dependency: cups - Common Unix Printing System...
OK, found.                                                    

Checking for dependency: cups-ddk - CUPS driver development kit...
warning: NOT FOUND! This is an OPTIONAL/RUNTIME ONLY dependency. Some HPLIP functionality may not function properly.                                            

Checking for dependency: cups-devel- Common Unix Printing System development files...                                                                           
error: NOT FOUND! This is a REQUIRED/COMPILE TIME ONLY dependency. Please make sure that this dependency is installed before installing or running HPLIP.       

Checking for dependency: gcc - GNU Project C and C++ Compiler...
OK, found.                                                      

Checking for dependency: GhostScript - PostScript and PDF language interpreter and previewer...                                                                 
OK, found.                                                                      

Checking for dependency: libcrypto - OpenSSL cryptographic library...
error: NOT FOUND! This is a REQUIRED dependency. Please make sure that this dependency is installed before installing or running HPLIP.                         

Checking for dependency: libjpeg - JPEG library...
error: NOT FOUND! This is a REQUIRED dependency. Please make sure that this dependency is installed before installing or running HPLIP.                         

Checking for dependency: libnetsnmp-devel - SNMP networking library development files...                                                                        
error: NOT FOUND! This is a REQUIRED dependency. Please make sure that this dependency is installed before installing or running HPLIP.                         

Checking for dependency: libpthread - POSIX threads library...
error: NOT FOUND! This is a REQUIRED dependency. Please make sure that this dependency is installed before installing or running HPLIP.                         

Checking for dependency: libtool - Library building support services...
error: NOT FOUND! This is a REQUIRED/COMPILE TIME ONLY dependency. Please make sure that this dependency is installed before installing or running HPLIP.       

Checking for dependency: libusb - USB library...
error: NOT FOUND! This is a REQUIRED dependency. Please make sure that this dependency is installed before installing or running HPLIP.                         

Checking for dependency: make - GNU make utility to maintain groups of programs...                                                                              
error: NOT FOUND! This is a REQUIRED/COMPILE TIME ONLY dependency. Please make sure that this dependency is installed before installing or running HPLIP.       

Checking for dependency: PIL - Python Imaging Library (required for commandline scanning with hp-scan)...                                                       
warning: NOT FOUND! This is an OPTIONAL/RUNTIME ONLY dependency. Some HPLIP functionality may not function properly.                                            

Checking for dependency: ppdev - Parallel port support kernel module....
error: NOT FOUND! This is a REQUIRED/RUNTIME ONLY dependency. Please make sure that this dependency is installed before installing or running HPLIP.            

Checking for dependency: PyQt - Qt interface for Python...
OK, found.                                                

Checking for dependency: python-devel - Python development files...
error: NOT FOUND! This is a REQUIRED/COMPILE TIME ONLY dependency. Please make sure that this dependency is installed before installing or running HPLIP.       

Checking for dependency: Python 2.3 or greater - Required for fax functionality...                                                                              
OK, found.                                                                      

Checking for dependency: Python 2.2 or greater - Python programming language...
OK, found.                                                                     

Checking for dependency: Reportlab - PDF library for Python...
OK, found.                                                    

Checking for dependency: SANE - Scanning library...
error: NOT FOUND! This is a REQUIRED/RUNTIME ONLY dependency. Please make sure that this dependency is installed before installing or running HPLIP.            

Checking for dependency: SANE - Scanning library development files...
error: NOT FOUND! This is a REQUIRED/COMPILE TIME ONLY dependency. Please make sure that this dependency is installed before installing or running HPLIP.       

Checking for dependency: scanimage - Shell scanning program...
OK, found.                                                    

Checking for dependency: xsane - Graphical scanner frontend for SANE...
warning: NOT FOUND! This is an OPTIONAL/RUNTIME ONLY dependency. Some HPLIP functionality may not function properly.                                            


----------------------
| HPLIP INSTALLATION |
----------------------


Currently installed HPLIP version...
HPLIP 2.8.2 currently installed in '/usr/local/share/hplip'.

Current contents of '/usr/local/etc/hp/hplip.conf' file:
# hplip.conf.  Generated from hplip.conf.in by configure.

[hpssd]
# Note: hpssd does not support dynamic ports
# Port 2207 is the IANA assigned port for hpssd
port=2207                                      

[hplip]
version=2.8.2
 

DutchDaemon

Administrator
Staff member
Administrator
Moderator
Developer

Reaction score: 2,780
Messages: 11,279

daringturtle, use code tags around system output. And don't post your email address on public forums. It's a spam magnet.
 

nikobordx

Active Member

Reaction score: 5
Messages: 107

Hi,

When you load the ulpt driver, is your printer recognized as /dev/ulpt0 ?
If yes, you can use only the ppd file from hplip, and cups.

Configure it with:
Code:
http://localhost:631
Nicolas.
 
OP
OP
D

daringturtle

New Member


Messages: 10

My printer is recognized as ugen0, i think. i removed the "device ulpt" line in my kernel. Still want to use cups so i can use scanner and printer. For now i'm going to try lpd jsut to see if i can get it to work.

thanks,
devin
 

Oko

Daemon

Reaction score: 770
Messages: 1,620

daringturtle said:
My printer is recognized as ugen0, i think. i removed the "device ulpt" line in my kernel. Still want to use cups so i can use scanner and printer. For now i'm going to try lpd jsut to see if i can get it to work.

thanks,
devin
People have reported mixed results with HPLIP on BSDs just that you know. I was able to use couple HP all-in-one devices on OpenBSD but it was major pain to trouble-shoot HPLIP (missing libraries). HPLIP is simply not written for BSDs and worst of all USB stack on FreeBSD is a mess which really doesn't help. Hopefully things will change with the release of 8.0.
 

nikobordx

Active Member

Reaction score: 5
Messages: 107

Hi,

Try to load (in root) the ulpt driver:
Code:
kldload ulpt
If your printer is recognized, try to configure with your web browser:
Code:
http://localhost:631
For the scanner, try to load the driver (i think it's already in kernel):
Code:
kldload uscanner
Don't forget to install:
Code:
/usr/ports/graphics/xsane
After in root, type in terminal: xsane

Nicolas.
 

tingo

Daemon

Reaction score: 373
Messages: 1,981

Oko said:
People have reported mixed results with HPLIP on BSDs just that you know. I was able to use couple HP all-in-one devices on OpenBSD but it was major pain to trouble-shoot HPLIP (missing libraries). HPLIP is simply not written for BSDs and worst of all USB stack on FreeBSD is a mess which really doesn't help. Hopefully things will change with the release of 8.0.
FWIW, I use HPLIP with my HP PhotoSmart 8250 printer - it works nicely. This printer isn't a MFC, so I haven't been able to test any other parts than printing.
The most difficult part with the setup of hplip was that the hp-setup program didn't work, but as long as the cups web interface did, that wasn't a problem.
 

Oko

Daemon

Reaction score: 770
Messages: 1,620

tingo said:
FWIW, I use HPLIP with my HP PhotoSmart 8250 printer - it works nicely. This printer isn't a MFC, so I haven't been able to test any other parts than printing.
That is exactly the tricky part since ulpt driver can not talk bi-directionally to all-in-one device. You have to remove from your kernel ulpt and umass driver so that all-in-one get recognized as ugen device. After the all-in-one is recognized as
ugen device you should load umass driver dynamically back into kernel because it is really needed. One thing that will not work though is your floppy drive which has to be seen during the boot but will not be seen as it need umass driver. If you have umass driver during the boot it will attach to all-in-one before ugen.

Once the all-in-one is seen as ugen HPLIP in principle should work but is very buggy peace of software so I would expect that you have to go at least trough 5 releases before your new shiny all-in-one device works. If you must have all-in-one probably the way to go is Epson since their scanner speak well known languages (most of them at least). Obviously if you must have serious all-in-one laser device HP is the way to go.
 

nikobordx

Active Member

Reaction score: 5
Messages: 107

Hi,

My printer is a HP Photosmart D5160, she's prints (of course) and has a memory card reader.

She's recognized as:
Code:
ulpt0: <HP Photosmart D5100 series, class 0/0, rev 2.00/1.00, addr 6> on usbus7
ulpt0: using bi-directional mode
umass0: <HP Photosmart D5100 series, class 0/0, rev 2.00/1.00, addr 6> on usbus7
umass0:  SCSI over Bulk-Only; quirks = 0x0000
da0 at umass-sim0 bus 0 target 0 lun 0
da0: <HP Photosmart D5100 1.00> Removable Direct Access SCSI-2 device 
da0: 40.000MB/s transfers
da0: Attempt to query device size failed: NOT READY, Medium not present
Have you tested what I said in the post of May 2 ?

Nicolas.
 

Oko

Daemon

Reaction score: 770
Messages: 1,620

nikobordx said:
Hi,

My printer is a HP Photosmart D5160, she's prints (of course) and has a memory card reader.

She's recognized as:
Code:
ulpt0: <HP Photosmart D5100 series, class 0/0, rev 2.00/1.00, addr 6> on usbus7
ulpt0: using bi-directional mode
umass0: <HP Photosmart D5100 series, class 0/0, rev 2.00/1.00, addr 6> on usbus7
umass0:  SCSI over Bulk-Only; quirks = 0x0000
da0 at umass-sim0 bus 0 target 0 lun 0
da0: <HP Photosmart D5100 1.00> Removable Direct Access SCSI-2 device 
da0: 40.000MB/s transfers
da0: Attempt to query device size failed: NOT READY, Medium not present
Have you tested what I said in the post of May 2 ?

Nicolas.
And you can not use Scanner of course. Any cheap HP inkjet will print with HPIJS drivers (attached as ulpt)
Code:
more /etc/printcap
Photosmart|HP|HP Photosmart 5250:\
        :lp=/dev/ulpt0:\
        :af=/etc/foomatic/HP-PhotoSmart_C5200.ppd:\
        :if=/usr/local/bin/foomatic-rip:\
        :sh:sd=/var/spool/output:\
        :lf=/var/log/lpd-errs:
The question is can you use scanner, sand fax, and printer status? Of course not. It has to be attached as ugen device for HPLIP to have any hope of working.

P.S. CUPS is not installed on any of my computers!
 

tingo

Daemon

Reaction score: 373
Messages: 1,981

FWIW, I just finished setting up my HP Photosmart 8250 printer with HPLIP 3.9.8 (print/hplip) on FreeBSD 8.0-stable. At first it didn't print, and I notice that $ hp-probe as my user didn't detect the printer, but # hp-probe as root did. By then I knew it was a permissions problem. In 8.0 (because of the new usb stack) /dev/usb is a directory, so you need 'x' permssion on it in order to see what's in it. I just added
Code:
add path 'usb' mode 0770
to my /etc/devfs.rules and that fixed the problem. Nice!

From $ hp-probe -busb:
Device URI Model
---------------------------------------------------- -------------------------
hp:/usb/Photosmart_8200_series?serial=MY61B3X1NC04KJ HP Photosmart 8200 series

Found 1 printer(s) on the 'usb' bus.
That's all.
 
Top