Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
05-20-2003, 03:38 PM
|
#1
|
LQ Newbie
Registered: May 2003
Posts: 2
Rep:
|
Print sharing with samba
I have been searching for this problem for several days now and still do not have it working.
I have redhat 9.0
The printer works fine from within linux.
File sharing works fine and I can see the printer from within windows (2000 and xp)
When I try to print in windows I don't get any kind of error the printer just sits there. I know that the file is actually being transfered because I have watched the printer path directory and can see the file being tranfered. So the only thing that can be wrong is something in the smb.conf file, correct?
If anyone has any ideas I would appreciate it.
I will include my smb.conf
I have screwed with every setting I know of and get nothing
Thanks
Katarn
# NOTE: Whenever you modify this file you should run the command "testparm"
# to check that you have not made any basic syntactic errors.
#
#======================= Global Settings =====================================
[global]
# workgroup = NT-Domain-Name or Workgroup-Name
workgroup = apartment
# server string is the equivalent of the NT Description field
server string = samba server
# if you want to automatically load your printer list rather
# than setting them up individually then you'll need this
printcap name = /etc/printcap
load printers = yes
# It should not be necessary to spell out the print system type unless
# yours is non-standard. Currently supported print systems include:
# bsd, sysv, plp, lprng, aix, hpux, qnx, cups
printing = [bsd|sysv|plp|lprng|aix|hpux|qnx|cups]
# this tells Samba to use a separate log file for each machine
# that connects
log file = /var/log/samba/%m.log
# Put a capping on the size of the log files (in Kb).
max log size = 0
# You may wish to use password encryption. Please read
# ENCRYPTION.txt, Win95.txt and WinNT.txt in the Samba documentation.
# Do not enable this option unless you have read those documents
encrypt passwords = yes
smb passwd file = /etc/samba/smbpasswd
# The following are needed to allow password changing from Windows to
# update the Linux system password also.
# NOTE: Use these with 'encrypt passwords' and 'smb passwd file' above.
# NOTE2: You do NOT need these to allow workstations to change only
# the encrypted SMB passwords. They allow the Unix password
# to be kept in sync with the SMB password.
unix password sync = Yes
passwd program = /usr/bin/passwd %u
passwd chat = *New*password* %n\n *Retype*new*password* %n\n *passwd:*all*authentication*tokens*updated*successfully*
# You can use PAM's password change control flag for Samba. If
# enabled, then PAM will be used for password changes when requested
# by an SMB client instead of the program listed in passwd program.
# It should be possible to enable this without changing your passwd
# chat parameter for most setups.
pam password change = yes
# This parameter will control whether or not Samba should obey PAM's
# account and session management directives. The default behavior is
# to use PAM for clear text authentication only and to ignore any
# account or session management. Note that Samba always ignores PAM
# for authentication in the case of encrypt passwords = yes
obey pam restrictions = yes
# Most people will find that this option gives better performance.
# See speed.txt and the manual pages for details
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
# Browser Control Options:
# set local master to no if you don't want Samba to become a master
# browser on your network. Otherwise the normal election rules apply
local master = yes
# OS Level determines the precedence of this server in master browser
# elections. The default value should be reasonable
os level = 33
# Domain Master specifies Samba to be the Domain Master Browser. This
# allows Samba to collate browse lists between subnets. Don't use this
# if you already have a Windows NT domain controller doing this job
domain master = yes
# Preferred Master causes Samba to force a local browser election on startup
# and gives it a slightly higher chance of winning the election
preferred master = yes
# Enable this if you want Samba to be a domain logon server for
# Windows95 workstations.
domain logons = yes
# DNS Proxy - tells Samba whether or not to try to resolve NetBIOS names
# via DNS nslookups. The built-in default for versions 1.9.17 is yes,
# this has been changed in version 1.9.18 to no.
username map = /etc/samba/smbusers
dns proxy = no
#============================ Share Definitions ==============================
[homes]
comment = Home Directories
browseable = no
writeable = yes
valid users = %S
create mode = 0664
directory mode = 0775
[deskjet670c]
valid users = root administrator
printable = yes
writable = yes
public = yes
printer = deskjet670c
path = /storage
guest ok = yes
print ok = yes
[storage]
comment = maxtor 80 gig storage drive
path = /storage
writeable = yes
valid users = root
public = no
printable = no
guest ok = no
|
|
|
05-21-2003, 09:43 AM
|
#2
|
LQ Newbie
Registered: May 2003
Posts: 5
Rep:
|
I had all kinds of problems setting up printing using the standard tools that came with RH. I guess they should have worked, but after beating my head against a brick wall for long enough, I installed LPRngtool. I used it to set all my printers up. In the smb.conf file, all you need is a few entries to get things rolling.
In the [Global] section, printing = lprng
In the [Printers] section, I have the following;
path = /var/spool/lpd/samba
guest ok = yes
printable = yes
print command = lpr -P%p -r %s
lpq command = lpq -P%p
lppause commmand = lpc hold %p %j
lpresume command = lpc release %p %j
queuepause command = lpc stop %p
queueresume command = lpc start %p
browseable = no
And thats it. And most of that is written for you when you install lprng. In our network we have mostly jetdirect/socketed printers, although we have one or two direct lpt:1 printers. It handles them all. A few words on some of the shortcomings I've noticed, though.
The included driver files/filter files are mostly laser type. There is hardly mention of dot matrix printer support. I've found one driver/filter that I use for all of our dot matrix/line printers, and it works well. It is the necp2x.upp filter (NEC 2PX). This seems to work well for me.
Another issue is the problem of lf/cr not being interpreted correctly. This is a windows/dos/linux issue. They do include a filter to correctly add a carriage return to all line feeds (lpf), and this fixes that. So, for all the printers that needed it, I first send them a spool that filters for line feeds/cr, then I send them to the spool that applies the normal driver filtering/formatting. No big deal.
It does come with a handy gui for your x-windows, and plenty of instructions on how to get things rolling. I found it very easy to use.
Good luck!
|
|
|
05-21-2003, 10:40 AM
|
#3
|
LQ Newbie
Registered: May 2003
Posts: 2
Original Poster
Rep:
|
Thanks for the advice, I will try it out.
So that would be a substitution for cups, which I think I'm using?
I will also include that I am using an HP Deskjet670c if that matters, which it could for driver availibility.
Thanks again
Katarn
|
|
|
All times are GMT -5. The time now is 10:42 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|