LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-28-2006, 03:24 AM   #1
fof3
Member
 
Registered: Nov 2003
Distribution: Debian - Lenny
Posts: 174

Rep: Reputation: 30
Cannot print


I have lprng and cups on my system. I get messages like the one below when trying to print. How can I stop/remove cups, to see if it is causing the conflict?


hebrews:~$ lpq
Printer: lp1@hebrews 'HP OfficeJet 5500'
Queue: 1 printable job
Server: pid 1562 active
Unspooler: pid 1570 active
Status: waiting for subserver to exit at 04:21:36.001
Rank Owner/ID Pr/Class Job Files Size Time
active(attempt-2) epjh@hebrews+556 A 556 (STDIN) 180446 04:21:34
 
Old 04-28-2006, 06:43 AM   #2
maroonbaboon
Senior Member
 
Registered: Aug 2003
Location: Sydney
Distribution: debian
Posts: 1,495

Rep: Reputation: 48
You can stop CUPS with the command (as root)

# /etc/init.d/cupsys stop

or uninstall with

# apt-get remove cupsys

Do you have a reason for preferring lprng to CUPS? I'm not familiar with the procedure for setting up a printer on lprng but I've generally found CUPS to work well (with a few hassles along the way).
 
Old 04-28-2006, 03:01 PM   #3
fof3
Member
 
Registered: Nov 2003
Distribution: Debian - Lenny
Posts: 174

Original Poster
Rep: Reputation: 30
Cannot print

I did /etc/init.d/cupsys stop
but still no printing.
The error message was:

hebrews:~$ lpq
Printer: lp1@hebrews 'HP OfficeJet 5500'
Queue: 1 printable job
Server: pid 2920 active
Unspooler: pid 2928 active
Status: attempt 2, sleeping 10 before retry at 15:55:02.712
Rank Owner/ID Pr/Class Job Files Size Time
active(attempt-2) epjh@hebrews+915 A 915 (STDIN) 112941 15:55:02
 
Old 04-28-2006, 07:59 PM   #4
maroonbaboon
Senior Member
 
Registered: Aug 2003
Location: Sydney
Distribution: debian
Posts: 1,495

Rep: Reputation: 48
You might find it hard to get help with lprng, as I think most people here just use CUPS. Also you have not said what you did to set your printer up for use with lprng. For example:

Do you have some sort of filter chain in place? Before CUPS the standard thing was for the application to generate Postscript, which got filtered through ghostscript with the appropriate driver. This was typically all set up by manually editing the /etc/printcap file, although some distributions would supply a wizard of some sort to help.

Do you have the USB system set up correctly, with the usblp kernel module loaded?

On the other hand, you could try CUPS instead.
 
Old 04-28-2006, 09:38 PM   #5
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Willoughby, Ohio
Distribution: linuxdebian
Posts: 7,232
Blog Entries: 5

Rep: Reputation: 190Reputation: 190
CUPS is pretty easy to setup

Fire up your web browser and point it to http://localhost:631

Login as root when the auth box pops up, select MANAGE PRINTERS, ADD PRINTER and step through the config..

here is my CUPS config for a Network Laserjet 4..
Code:
Name:  	        HPLaser
Location: 	Network	
Description: 	HP Laserjet
Device: 	LPD/LPR Host or Printer
Device URL: 	lpd://192.168.2.3/raw
Make: 		HP
Model: 		HP Laserjet 4 Series - CUPS+Gutenprint v5.0.0-rc2 (en)
Here is information from HP on port names for the Jetdirect cards.. raw is probably what you wnt..
http://h20000.www2.hp.com/bizsupport...ectID=bpj07058

CUPS is really pretty easy to configure.
 
Old 04-28-2006, 09:56 PM   #6
fof3
Member
 
Registered: Nov 2003
Distribution: Debian - Lenny
Posts: 174

Original Poster
Rep: Reputation: 30
Cannot print

After I stopped cupsys, as noted, I tried to print using lprng. I then stopped lprng, and restarted cupsys; but with still no printing.
How do you work with CUPS?
 
Old 04-28-2006, 10:30 PM   #7
maroonbaboon
Senior Member
 
Registered: Aug 2003
Location: Sydney
Distribution: debian
Posts: 1,495

Rep: Reputation: 48
How is the printer attached to the computer?

Are you using KDE or Gnome desktop, or something else?

KDE Control Center has a print management wizard which is quite nice. Not sure what Gnome has. Otherwise there is a web interface to CUPS at browser address

http://localhost:631/admin

I like the KDE thing myself.
 
Old 04-29-2006, 07:23 AM   #8
fof3
Member
 
Registered: Nov 2003
Distribution: Debian - Lenny
Posts: 174

Original Poster
Rep: Reputation: 30
Cannot print

To answer two of your questions:
(1)
less /etc/printcap
# Entry edited Tue Nov 25 18:11:02 2003 by foomatic-configure.
# Additional configuration atop /etc/foomatic/lpd/lp1.ppd
lp1||HP OfficeJet 5500|:\
:filter_options= --lprng $J $Z /etc/foomatic/lpd/lp1.ppd:\
:lf=/var/log/lp-errs:\
pdfile=/etc/foomatic/lpd/lp1.ppd:\
:sd=/var/spool/lpd/lp1:\
:lp=/dev/usb/lp0:\
:if=/usr/bin/foomatic-rip:\
:sh:\
:force_localhost:\
:mx#0:
(2)
I am using the X Window system
 
Old 04-29-2006, 07:36 AM   #9
fof3
Member
 
Registered: Nov 2003
Distribution: Debian - Lenny
Posts: 174

Original Poster
Rep: Reputation: 30
Cannot print

What is http://localhost:631; and what is the username and password they are asking for? farslayer said to log in as root??? I don't want to enter my root password outside of my own system.
 
Old 04-29-2006, 10:09 AM   #10
maroonbaboon
Senior Member
 
Registered: Aug 2003
Location: Sydney
Distribution: debian
Posts: 1,495

Rep: Reputation: 48
From the /etc/printcap file it looks like you did something to configure the printer with lprng. It looks quite different to the file generated by CUPS.

If you want to lprng again you could have a look in the log file /var/log/lp-errs to see if there is anything useful.

You could also try to verify that the printer is set up correctly on /dev/usb/lp0. Unplug the printer from the usb port, plug it in again and run 'dmesg' in a console. The last dozen or so lines should give some relevant information.

http://localhost:631 is the address of the CUPS admin tool, running as a web server on your own machine and listening on port 631. Installations may vary on what privileges you need to use this. Typically you need to log in as root to add a printer.

If there was no protection someone else on your local network (or anywhere in the world, if you don't have a firewall) could contact your computer on port 631 and change your printer settings.
 
Old 04-29-2006, 08:38 PM   #11
fof3
Member
 
Registered: Nov 2003
Distribution: Debian - Lenny
Posts: 174

Original Poster
Rep: Reputation: 30
Cannot print

less /var/log/lp-errs
2005-08-07-16:32:50.230 hebrews lp1: Print_job: job 'epjh@hebrews+171', cannot o
pen data file 'dfA171hebrews.jesus-is.org'


hebrews:/dev/usb# file lp0
lp0: character special (180/0)

dmesg
usb 1-1: new full speed USB device using ohci_hcd and address 2
ohci_hcd 0000:00:02.2: GetStatus roothub.portstatus [0] = 0x00100103 PRSC PPS PES CCS
usb 1-1: ep0 maxpacket = 8
usb 1-1: default language 0x0409
usb 1-1: new device strings: Mfr=1, Product=2, SerialNumber=3
usb 1-1: Product: officejet 5500 series
usb 1-1: Manufacturer: hp
usb 1-1: SerialNumber: MY381B202Q96
usb 1-1: adding 1-1:1.0 (config #1, interface 0)
usbserial_generic 1-1:1.0: usb_probe_interface
usbserial_generic 1-1:1.0: usb_probe_interface - got id
usb 1-1: adding 1-1:1.1 (config #1, interface 1)
usblp 1-1:1.1: usb_probe_interface
usblp 1-1:1.1: usb_probe_interface - got id
drivers/usb/class/usblp.c: usblp0: USB Bidirectional printer dev 2 if 1 alt 0 proto 2 vid 0x03F0 pid 0x3A11
drivers/usb/core/file.c: looking for a minor, starting at 0
usb 1-1: adding 1-1:1.2 (config #1, interface 2)
usbserial_generic 1-1:1.2: usb_probe_interface
usbserial_generic 1-1:1.2: usb_probe_interface - got id
hub 1-0:1.0: state 5 ports 3 chg 0000 evt 0002
hub 1-0:1.0: state 5 ports 3 chg 0000 evt 0002
ohci_hcd 0000:00:02.2: GetStatus roothub.portstatus [0] = 0x00030100 PESC CSC PPS
hub 1-0:1.0: port 1, status 0100, change 0003, 12 Mb/s
usb 1-1: USB disconnect, address 2
usb 1-1: usb_disable_device nuking all URBs
usb 1-1: unregistering interface 1-1:1.0
usb 1-1: unregistering interface 1-1:1.1
drivers/usb/core/file.c: removing 0 minor
drivers/usb/class/usblp.c: usblp0: removed
usb 1-1: unregistering interface 1-1:1.2
usb 1-1: unregistering device
hub 1-0:1.0: debounce: port 1: total 100ms stable 100ms status 0x100
hub 1-0:1.0: state 5 ports 3 chg 0000 evt 0002
ohci_hcd 0000:00:02.2: GetStatus roothub.portstatus [0] = 0x00010101 CSC PPS CCS
hub 1-0:1.0: port 1, status 0101, change 0001, 12 Mb/s
hub 1-0:1.0: debounce: port 1: total 100ms stable 100ms status 0x101
ohci_hcd 0000:00:02.2: GetStatus roothub.portstatus [0] = 0x00100103 PRSC PPS PES CCS
usb 1-1: new full speed USB device using ohci_hcd and address 3
ohci_hcd 0000:00:02.2: GetStatus roothub.portstatus [0] = 0x00100103 PRSC PPS PES CCS
 
Old 04-30-2006, 12:28 AM   #12
maroonbaboon
Senior Member
 
Registered: Aug 2003
Location: Sydney
Distribution: debian
Posts: 1,495

Rep: Reputation: 48
One strange thing is that /etc/printcap seems to be spooling files in /var/spool/lpd/lp1 and printing on /dev/usb/lp0. Dmesg mentions usblp0. Some confusion between lp0 and lp1 seems possible. Hard to know how to fix it without knowing how it got there in the first place.

I think I would be inclined to remove both lprng and cups and reinstall just one.
 
Old 04-30-2006, 05:52 AM   #13
fof3
Member
 
Registered: Nov 2003
Distribution: Debian - Lenny
Posts: 174

Original Poster
Rep: Reputation: 30
Cannot print

I removed both, and reinstalled lprng, and got this:

Printer: lp1@hebrews 'HP OfficeJet 5500'
Queue: no printable jobs in queue
Server: no server active
Status: job 'epjh@hebrews+964' saved at 15:56:04.312
Rank Owner/ID Pr/Class Job Files Size Time
error epjh@hebrews+964 A 964 ERROR: too many errors
 
Old 04-30-2006, 06:45 AM   #14
maroonbaboon
Senior Member
 
Registered: Aug 2003
Location: Sydney
Distribution: debian
Posts: 1,495

Rep: Reputation: 48
I gotta say it is pretty hard to figure out what is going on here. Not using lprng myself nothing looks familiar.

When lprng is reinstalled the print server should get started, but apparently it didn't. You don't say exactly what you did to reinstall lprng. Did you have to supply any information in the process?

At this point I would suggest switching to CUPS.
 
Old 04-30-2006, 11:10 AM   #15
fof3
Member
 
Registered: Nov 2003
Distribution: Debian - Lenny
Posts: 174

Original Poster
Rep: Reputation: 30
Cannot print

hebrews:~$ sudo apt-get --reinstall install lprng
Password:
Reading Package Lists... Done
Building Dependency Tree... Done
0 upgraded, 0 newly installed, 1 reinstalled, 0 to remove and 402 not upgraded.
1 not fully installed or removed.
Need to get 0B/1821kB of archives.
After unpacking 0B of additional disk space will be used.
Do you want to continue? [Y/n]
Preconfiguring packages ...
(Reading database ... 106198 files and directories currently installed.)
Preparing to replace lprng 3.8.28-4 (using .../lprng_3.8.28-4_i386.deb) ...
Stopping LPRNG printer spooler: lpd.
Unpacking replacement lprng ...
Setting up xemacs21-mule (21.4.18-3) ...
emacs-install xemacs21
install/a2ps: Handling install for emacsen flavor xemacs21
/usr/lib/emacsen-common/packages/install/a2ps: line 42: xemacs21: command not found
emacs-install: /usr/lib/emacsen-common/packages/install/a2ps xemacs21 failed at /usr/lib/emacsen-common/emacs-install line 28, <TSORT> line 3.
dpkg: error processing xemacs21-mule (--configure):
subprocess post-installation script returned error exit status 127
Setting up lprng (3.8.28-4) ...
Starting LPRNG printer spooler: lpd.

Errors were encountered while processing:
xemacs21-mule
E: Sub-process /usr/bin/dpkg returned an error code (1)


How do I switch to CUPS?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Print-to-file print driver to print PDF Bill Fox Linux - General 3 05-02-2006 04:15 PM
Print jobs repeat infinetly on lpd printer attached to axis print server linux-who? Linux - Hardware 0 03-28-2006 11:24 AM
HP PS7150: text doesn't print in OOO and Abiword!, but I can print test page & w MzFF gabba Mandriva 6 10-31-2005 11:10 AM
OfficeJet G85, CUPS Web based Admin test print works, lpr/lp dose not. ptal-print OK. NLR Linux - Hardware 2 09-20-2004 02:59 PM
Mozilla problems: Print/print preview doesn't work, not recording sites in history... andy_g_gray Linux - Software 3 01-23-2004 06:27 AM


All times are GMT -5. The time now is 01:10 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration