LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 09-17-2004, 11:39 AM   #1
fader
Member
 
Registered: Feb 2004
Location: Farmville, VA
Distribution: Desktop: Ubuntu 8.04, Beowulf: Slackware & Dragonfly BSD, Tablet: Fedora 9, Toughbook: Arch Current
Posts: 98

Rep: Reputation: 16
Slackware 10, CUPS, HP Officejet 600


Hi guys including all the Slackware Gurus out there!

I've had an HP Officejet 600 for quite a while running on XP Pro, but I always was hesitant to get it to work in Slackware. On the Stealth Desktop Part III I just read this morning, I here the generic kernel doesn't come with the loadable modules for Parallel Printer Support. My Officejet is a parallel printer so that means I'll have to install the module into /lib/modules. But that's no biggie.

The hard part is ptal-init and CUPS in Slackware. A while ago, I tried to install the printer in Slackware 9.1 but I couldn't get it to work, so I gave up on that. Now, I actually have a need for a Printer in Linux.

Here's the problem (once I have Parallel Printer all working and stuff):

1.) I ./configure, make, make install hpijs. This part is just fine. This isn't hard to do.
2.) Secondly, I have to install hpoj fine source, which builds just fine, EXCEPT for the SystemV init deal. I'm not too familiar of how Slackware deals with SystemV init scripts.
3.) I probe the printer and ptal-init recognizes it and everything is just fine. The hard part is to get the ptal-init to start before CUPS at Startup and end after CUPS at reboot or shutdown.

I've installed a PSC 2210 on a Xandros and Xandros uses SystemV scripts, but Slackware doesn't.

At installation, I checked that rc.cups should startup at boot time, which it does, but I'm not that familiar with the BSD-style init scripts Slackware used. This includes the stuff in /etc, which are namely rc.S, rc.M, rc.6 .... rc.cups, rc.sysvinit (whatever it is). Is there any way make cups start as a system V script along with ptal-init. Someone just gimme that lowdown from the beginning. Thanks!
 
Old 09-17-2004, 12:07 PM   #2
gbonvehi
Senior Member
 
Registered: Jun 2004
Location: Argentina (SR, LP)
Distribution: Slackware
Posts: 3,145

Rep: Reputation: 53
You don't have to install the modules, just uncommend the line to load them (modprobe parport_pc and modprobe lp) in /etc/rc.d/rc.modules. You have packages for cups and gimp-print (the two you need to print) in default slackware cds if you made a full install, or you can get them in any slackware mirror.

Last edited by gbonvehi; 09-17-2004 at 12:08 PM.
 
Old 09-17-2004, 12:29 PM   #3
Nikon01
Member
 
Registered: Jul 2003
Distribution: Slackware 10.0
Posts: 196

Rep: Reputation: 30
Well at least people are reading my posts
 
Old 09-17-2004, 01:26 PM   #4
fader
Member
 
Registered: Feb 2004
Location: Farmville, VA
Distribution: Desktop: Ubuntu 8.04, Beowulf: Slackware & Dragonfly BSD, Tablet: Fedora 9, Toughbook: Arch Current
Posts: 98

Original Poster
Rep: Reputation: 16
Getting Parallel To Work Isn't Really A Problem, but thanks for that anyway. The root of the problem is getting ptal-init to start before CUPS somehow in the System Init Scripts. Is it safe for me to delete rc.cups and add a link to cupsd somewhere else preferably in rc.sysvinit in the rc.S, rc.6 files etc.?
 
Old 09-17-2004, 09:09 PM   #5
carboncopy
Senior Member
 
Registered: Jan 2003
Location: Malaysia
Posts: 1,210
Blog Entries: 4

Rep: Reputation: 45
What I would do is:
Code:
mkdir /etc/rc.d/delay
mv /etc/rc.d/rc.cups /etc/rc.d/delay
emacs rc.local
(add this line) /etc/rc.d/delay/rc.cups
 
Old 09-17-2004, 10:33 PM   #6
r_jensen11
Senior Member
 
Registered: Apr 2003
Location: Minnesota, USA
Distribution: Slack 10.0 w/2.4.26
Posts: 1,032

Rep: Reputation: 45
Quote:
Originally posted by fader
Getting Parallel To Work Isn't Really A Problem, but thanks for that anyway. The root of the problem is getting ptal-init to start before CUPS somehow in the System Init Scripts. Is it safe for me to delete rc.cups and add a link to cupsd somewhere else preferably in rc.sysvinit in the rc.S, rc.6 files etc.?
Wouldn't do that. What you could do is a bunch of different options:

1: insert lines into rc.cups that load ptal-init

2: (what I did) create a script called rc.ptal (just an example, what mine is named) and have that script run before rc.cups (put in the code to have it executed in rc.M I believe it is)

here's an excerpt from my rc.M file:
Code:
# Start ptal
if [ -x /etc/rc.d/rc.ptal ]; then
  echo "Starting ptal-init (ptal-init start)"
  . /etc/rc.d/rc.ptal start
fi

# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.
if [ -x /etc/rc.d/rc.cups ]; then
  # Start CUPS:
  /etc/rc.d/rc.cups start
elif [ -x /etc/rc.d/rc.lprng ]; then
  # Start LPRng (lpd):
  . /etc/rc.d/rc.lprng start
fi
and here is my /etc/rc.d/rc.ptal:
Code:
rob@4300:~$ cat /etc/rc.d/rc.ptal
#!/bin/sh
#
# /etc/rc.d/rc.httpd
#
# Start/stop/restart the Apache web server.
#
# To make Apache start automatically at boot, make this
# file executable:  chmod 755 /etc/rc.d/rc.httpd
#

case "$1" in
   'start')
      /usr/local/sbin/ptal-init start ;;
   'stop')
      /usr/local/sbin/ptal-init stop ;;
   'restart')
      /usr/local/sbin/ptal-init restart ;;
   *)
      echo "usage $0 start|stop|restart" ;;
esac
chmod rc.ptal to 755 and you shouldn't have any problems. My only grief is that I have to have the printer turned on before the scripts run (not sure if it's ptal, cups, or hotplug, I restart all of them if I forget to turn the printer on, just in case). It might just be a 2.6.8.1 glitch though, I'm finding several glitches with my kernel.
 
Old 09-17-2004, 11:25 PM   #7
eelriver
Member
 
Registered: May 2004
Location: san francisco
Distribution: Slackware 10.2 kernel 2.6.13, Gentoo amd64, Some mish-mash of programs that started with slack 9.0
Posts: 165

Rep: Reputation: 30
The newer rc.M scripts already have a hpoj script in them.
Code:
#Initialize HP Officejet support
if [-x /etc/rc.d/rc.hpoj ]; then
/etc/rc.d/rc.hpoj start
However, this is in the wrong order in the script and needs to be moved to start before cups.
This is my rc.hpoj script:
Code:
#!/bin/sh
#
#
# Startup for HP printer and scanner drivers
/usr/local/sbin/ptal-init start
 
Old 09-18-2004, 08:22 AM   #8
fader
Member
 
Registered: Feb 2004
Location: Farmville, VA
Distribution: Desktop: Ubuntu 8.04, Beowulf: Slackware & Dragonfly BSD, Tablet: Fedora 9, Toughbook: Arch Current
Posts: 98

Original Poster
Rep: Reputation: 16
Okay, so it's been cleare that startup scripts are fine, but what about the kill scripts? Do I even have to deal with rc.sysvinit? Do I have to kill CUPS in rc.6 before ptal as well? Thanks All.

Last edited by fader; 09-18-2004 at 08:23 AM.
 
  


Reply



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
DISCUSSION: Printing from Linux to an HP OfficeJet 5510 on XP Pro via CUPS wrw3 LinuxAnswers Discussion 4 01-12-2006 12:51 PM
Printing from Linux to HP OfficeJet 5500 on XP Pro via CUPS wrw3 LinuxQuestions.org Member Success Stories 3 06-08-2004 01:56 PM
Problems w/ CUPS & OfficeJet 6110xi goulartca Linux - Hardware 2 04-02-2004 03:11 PM
HP officejet d135 - CUPS - Win XP driver problem comprei Linux - Hardware 0 03-01-2004 02:41 PM
Cups and an HP OfficeJet 710 Sm0k3 Slackware 2 09-11-2003 10:35 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 10:39 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
Open Source Consulting | Domain Registration