LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-22-2004, 11:54 PM   #1
Titan_X
LQ Newbie
 
Registered: Feb 2004
Location: Florida, USA
Distribution: Ubuntu; Ubuntu Netbook Remix
Posts: 17

Rep: Reputation: 0
Can't get HP DeskJet on lp0 as Samba share...


Hi folks!

I'm not completely new to Linux. I've been using it off and on for a couple of years, but recently I installed Red Hat Linux 9 to my old PC to play around with it to get some good knowledge I can take into the IT world.

I just got Samba running on it and am already able to share directories. I've been trying to share a printer, but haven't had any luck.

I have an old HP DeskJet 697C attached to the parallel port on my Linux box, and I'm able to print from Linux without a problem. I've set the share for the spool in Red Hat printer manager, added the printer information to smb.conf, and added the network printer to my Windows XP Pro box, but I always either get an "Unable to connect, Access denied" error, or when it says "Ready", I try to print a test page and it says it can't add it to the spool.

I'm not sure if I might have something wrong with my syntax, but I've tried everything I know to remedy this problem. If anybody can offer me any suggestions, I'd greatly appreciate them!

Here is my samba.conf file for reference:

[global]
workgroup = brunner
encrypt passwords = yes
printcap name = /etc/printcap
[homes]
comment = %u's Home
browsable = no
read only = no
[printers]
printable = yes
printing = BSD
print command = /usr/bin/lpr -P%p -l -r %s
path = /var/spool/cups
min print space = 2000
public = yes

I plan on changing the public = yes as soon as I'm confident the printer will work.

Also, here's the output for the testparm on smb.conf:

Load smb config files from /etc/samba/smb.conf
Processing section "[homes]"
Processing section "[printers]"
Loaded services file OK.
Press enter to see a dump of your service definitions
...
...
[printers]
path = /var/spool/cups
guest ok = Yes
min print space = 2000
printable = Yes
print command = /usr/bin/lpr -P%p -l -r %s
browseable = No

Last edited by Titan_X; 02-23-2004 at 11:04 AM.
 
Old 02-23-2004, 08:00 AM   #2
ScooterB
Member
 
Registered: Sep 2003
Location: NW Arkansas
Distribution: Linux Redhat 9.0, Fedora Core 2,Debian 3.0, Win 2K, Win95, Win98, WinXp Pro
Posts: 344

Rep: Reputation: 31
Re: Can't get HP DeskJet on lp0 as Samba share...

Quote:
Originally posted by Titan_X
Hi folks!

[printers]
path = /var/spoolcups
guest ok = Yes
min print space = 2000
pritnable = Yes
print command = /usr/bin/lpr -P%p -l -r %s
browseable = No
I am not sure but if this is a direct output from your file you may have some syntax errors.

Quote:

path = /var/spoolcups
should that not be:
path = /var/spool/cups

also,
Quote:
pritnable = Yes
should that not be:
printable = Yes



Try making those changes and see what you get.
 
Old 02-23-2004, 11:03 AM   #3
Titan_X
LQ Newbie
 
Registered: Feb 2004
Location: Florida, USA
Distribution: Ubuntu; Ubuntu Netbook Remix
Posts: 17

Original Poster
Rep: Reputation: 0
Re: Re: Can't get HP DeskJet on lp0 as Samba share...

Quote:
Originally posted by ScooterB
I am not sure but if this is a direct output from your file you may have some syntax errors.

should that not be:
path = /var/spool/cups

also,
should that not be:
printable = Yes



Try making those changes and see what you get.
Nope, it's not direct output from smb.conf. I didn't copy and paste it; the actual file is exactly as you said.

Editing the original post...
 
Old 02-23-2004, 11:43 AM   #4
ScooterB
Member
 
Registered: Sep 2003
Location: NW Arkansas
Distribution: Linux Redhat 9.0, Fedora Core 2,Debian 3.0, Win 2K, Win95, Win98, WinXp Pro
Posts: 344

Rep: Reputation: 31
I am looking in Samba unleashed and it states that Samba is extremely sensitive to file permissions when it comes to printing. check your permissions on your path /var/spool/cups. It recommends that you give it a full 777 with the sticky bit set (this prevents user a from deleting print jobs from user b). It next says to test your printer share by: "smbclient -NL (insert your server name) The return should show the printers correctly as shares and identified as printers. It next says to try and run a print job from dos (on your windoze machine): C:\> echo Hello^L > \\yourservername\your printer name. The ^L control charecter is the ASCII formfeed charecter (hit Ctrl & L). This should print out a page with the word "Hello" on it. This will rule out everything but the windoze printer definition and the application.
 
Old 02-26-2004, 12:15 PM   #5
Titan_X
LQ Newbie
 
Registered: Feb 2004
Location: Florida, USA
Distribution: Ubuntu; Ubuntu Netbook Remix
Posts: 17

Original Poster
Rep: Reputation: 0
I got it working! All it took was removing the following bolded lines:

[printers]
printable = yes
printing = BSD
print command = /usr/bin/lpr -P%p -l -r %s
path = /var/spool/cups
min print space = 2000
public = yes

Thanks for all your help, though.
 
  


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
Simple Samba Setup, Share & Not Share timmywo Linux - Software 4 07-30-2004 08:27 AM
Samba DeskJet Problems Lister Linux - Networking 0 03-25-2004 10:16 AM
HP Deskjet (USB) & CUPS & Slackware 9.1: Unable to open USB device "usb:/dev/usb/lp0&qu arnostienen Slackware 2 01-29-2004 04:22 PM
HP DeskJet 3320 USB, RH7.3, samba, network share, blank pages shahriars Linux - Hardware 3 10-23-2003 01:43 PM
Samba Printing to XP HP DeskJet nbin Linux - Software 0 07-15-2003 09:28 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:58 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