LinuxQuestions.org
Visit the LQ Articles and Editorials section
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 01-31-2004, 10:46 PM   #1
WarrenWright
LQ Newbie
 
Registered: Dec 2003
Location: Dallas
Distribution: Fedora Core 1
Posts: 21

Rep: Reputation: 15
Can't print from win2k to Fedora w/Samba + CUPS


Hi all,

I'm running Fedora, and have an HP Deskjet 3820 hooked up to it. I can print from my Fedora server perfectly.

I've spent quite a lot of time today configuring samba to allow my wife's WinXP laptop and my Win2k laptop to print on this HP 3820 that is attached to my Fedora box. I'm using a netbios name of "Samba_Server" for the Fedora box.

I've made progress, but gotten stuck. From the windows laptops I can browse to \\Samba_Server and access the shared folders without issue. I can also see the shared hp_deskjet_3820 printer and connect to it.

However, if I try to print on the 3820 from a windows laptop the test page never prints, and I get error messages in my samba log files. Here is an excerpt:

Quote:
[2004/01/31 22:30:35, 1] smbd/ipc.c:api_fd_reply(284)
api_fd_reply: INVALID PIPE HANDLE: 703f
[2004/01/31 22:32:47, 0] passdb/pdb_smbpasswd.c:build_sam_account(1179)
build_sam_account: smbpasswd database is corrupt! username pcguest with uid 0 is not in unix passwd database!
[2004/01/31 22:32:47, 1] auth/auth_util.c:make_server_info_sam(818)
User pcguest in passdb, but getpwnam() fails!
[2004/01/31 22:33:03, 0] passdb/pdb_smbpasswd.c:build_sam_account(1179)
build_sam_account: smbpasswd database is corrupt! username pcguest with uid 0 is not in unix passwd database!
[2004/01/31 22:33:03, 1] auth/auth_util.c:make_server_info_sam(818)
User pcguest in passdb, but getpwnam() fails!
[2004/01/31 22:33:03, 0] smbd/service.c:make_connection(850)
w4530010-2 (192.168.2.5) couldn't find service ::{2227a280-3aea-1069-a2de-08002b30309d}
lpr: unable to print file: client-error-document-format-not-supported
I see 2 problems in the log. The first, and maybe the biggest, is the complaints about pcguest. The second, the message that actually occurs when I try to print the test page, is the "client-error-document-format-not-supported" message.

My non-administrative account on the fedora box is "warren", and I've added a line like "warren = sx020ww" to /etc/samba/smbusers. I'm not sure if that is necessary or useful....sx020ww is the use account I'm using on my win2k laptop.

To summarize, I've followed several online documents on how to set this up by editing the smb.conf file. I'm able to access shared directories on the linux box. I'm able to browse to and see the HP 3820 printer from my windows laptops, but can't print test files (or any other file).

Thanks for any direction you can give me. I'm really enjoying my first linux installation, particularly the rich command line (compared to DOS), but this is the first major issue that has driven me up the wall a bit.

Regards,

Warren Wright
Dallas, Texas
 
Old 01-31-2004, 11:46 PM   #2
swiftnet
Member
 
Registered: Aug 2003
Location: Florida, USA
Distribution: Mandrake, Knoppix, Yoper
Posts: 97

Rep: Reputation: 19
Ok,

The best way to connect to a samba printer from WinNT5 (2k/XP) is to select a local port and type in the url:

\\samba_server\theprinter

Windows NT5 can print directly to the cups server, thus bypassing samba. It is http printing in WIndows speak. This is preferred method.
 
Old 02-01-2004, 09:35 AM   #3
WarrenWright
LQ Newbie
 
Registered: Dec 2003
Location: Dallas
Distribution: Fedora Core 1
Posts: 21

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by swiftnet
The best way to connect to a samba printer from WinNT5 (2k/XP) is to select a local port and type in the url:

\\samba_server\theprinter

Windows NT5 can print directly to the cups server, thus bypassing samba. It is http printing in WIndows speak. This is preferred method.
Alright. So, under Win2k, I entered the "Add Printer" wizard, and instead of type the printer name directly I selected the "Connect to Printer on your intranet or the internet" option and typed in \\Samba_Server\hp_deskjet_3820.

Now, when viewing my printers it shows that one, but says "Access denied, unable to connect". Further, if I try to print a test page I get the following messages in the CUPS error_log file:

Quote:
E [01/Feb/2004:09:24:01 -0600] print_job: Unsupported format 'application/octet-stream'!
I [01/Feb/2004:09:24:01 -0600] Hint: Do you have the raw file printing rules enabled?
Thanks for any help,

Warren
 
Old 02-01-2004, 01:39 PM   #4
swiftnet
Member
 
Registered: Aug 2003
Location: Florida, USA
Distribution: Mandrake, Knoppix, Yoper
Posts: 97

Rep: Reputation: 19
What you need to do is add printer/use a local port/then type in the url. Do not choose a network printer. Printing directly to cups is the better option, printing to samba is really only necessary when you jhave 9x clients, although it (samba) will work with all versions of networked Windows.
 
Old 02-02-2004, 02:34 PM   #5
WarrenWright
LQ Newbie
 
Registered: Dec 2003
Location: Dallas
Distribution: Fedora Core 1
Posts: 21

Original Poster
Rep: Reputation: 15
Any recommended documents or sites that provide explanations of how to configure CUPS and any other necessary machine permissions to allow this?

I tried choosing local printer, then local host, then using the URL http://Samba_Server/hp_deskjet_3820, but still get the errors listed above.

Perhaps there is further CUPS configuration needed.

Also, what machine-wide permissions need to be set? Aren't there permissions that determine which machines are allowed to access printers through CUPS?

Thanks,

Warren Wright
Dallas
 
Old 02-02-2004, 02:35 PM   #6
WarrenWright
LQ Newbie
 
Registered: Dec 2003
Location: Dallas
Distribution: Fedora Core 1
Posts: 21

Original Poster
Rep: Reputation: 15
As an addendum to the above post, I have searched and am searching for good documents on this over the web, but most of the good documents I find try to address print sharing through SAMBA.

Warren
 
Old 02-02-2004, 09:36 PM   #7
swiftnet
Member
 
Registered: Aug 2003
Location: Florida, USA
Distribution: Mandrake, Knoppix, Yoper
Posts: 97

Rep: Reputation: 19
For clarity: Connecting directly to Cups bypasses Samba. First I'll show how to connect the samba printer, next I linked two articles with info on connecting W2k PC's directly to Cups.

Connecting to a printer via samba:

add printer/select local port/new port/enter the printer url (//sambaserver/printername)
these lines should be in the smb.conf ( I snipped 'em out from a generic smb.conf)

Global
# if you want to automatically load your printer list rather
# than setting them up individually then you'll need this
printcap name = cups
load printers = yes
printing = cups
printer admin = @adm

Shares
[printers]
comment = All Printers
path = /var/spool/samba3
browseable = no
# to allow user 'guest account' to print.
guest ok = yes
writable = no
printable = yes
create mode = 0700
# =====================================
# print command: see above for details.
# =====================================
print command = lpr-cups -P %p -o raw %s -r # using client side printer drivers.

Below is the preferred method:


To Connect Windows Computers to Cups Print Server (via internet printing)

http://networking.earthweb.com/netse...0951_2236011_2

or

http://www-jerry.oit.duke.edu/commun...p_printer.html
 
  


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
Samba/Cups print sharing problems (/var/spool/samba files) Gates1026 Linux - General 9 06-23-2013 01:33 AM
SAMBA host... print with cups? hraposo Slackware 22 01-02-2006 01:09 PM
Samba/Win2K printing ignores print quantity ahz10 Linux - Software 0 05-17-2005 06:36 PM
?How to print from Redhat 3.0 to Win2k (Samba) zednrita Linux - Networking 4 07-26-2004 10:52 AM
Suse 8.1,Samba,Cups print to Win2k printer mithrin Linux - Networking 1 03-14-2003 04:42 PM


All times are GMT -5. The time now is 12:53 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration