Mark
asked on
need help configuring samba for no password
Seems like I mess up every samba configuration I touch! I'm trying to configure samba 3.0.25b for no password. Here's the smb.conf I have:
This is a modified version of a smb.conf, with passwords, that worked. Before, I had 'security = user', and 'valid users' in the service sections, and did not have 'guest ok', or 'guest only' in these sections. The previous version worked, but I had to login in with ID and PW.
Now, when I try to map the drive from my XP workstation, I get the error "An extended error has occured." The contents of my /var/log/samba.192.168.0.4 6 are:
One thing I notice is that it is trying to connect using the username COMMON1, which is the computer name of the XP Workstation I am trying to map from. Why? I have almost this exact same smb.conf in another Linux computer and it appears to use the guest account ID, not the computer name.
My designated guest account: ohprso, is in /etc/passwd and also in the samba password file. I've tried removing 'preferred master' and 'wins support', but that didn't help.
Need help ... again!
[global]
netbios name = WEBSERVER
workgroup = WORKGROUP
security = share
hosts allow = 192.168.0. 127.
load printers = no
printcap name = /dev/null
printing = bsd
disable spoolss = yes
guest account = ohprso
log file = /var/log/samba.%m
max log size = 50
passdb backend = tdbsam
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
preferred master = yes
wins support = yes
dns proxy = no
[website]
path = /srv/tomcat/webapps/ohprs
public = yes
guest ok = yes
guest only = yes
writeable = yes
browseable= yes
printable = no
create mask = 0660
[xfer]
path = /home/ohprs/xfer
public = yes
guest ok = yes
guest only = yes
writeable = yes
browseable= yes
printable = no
create mask = 0660
This is a modified version of a smb.conf, with passwords, that worked. Before, I had 'security = user', and 'valid users' in the service sections, and did not have 'guest ok', or 'guest only' in these sections. The previous version worked, but I had to login in with ID and PW.
Now, when I try to map the drive from my XP workstation, I get the error "An extended error has occured." The contents of my /var/log/samba.192.168.0.4
[2012/08/29 12:17:27, 3] smbd/oplock.c:init_oplocks(863)
init_oplocks: initializing messages.
[2012/08/29 12:17:27, 3] smbd/oplock_linux.c:linux_init_kernel_oplocks(276)
Linux kernel oplocks enabled
[2012/08/29 12:17:27, 10] lib/util_sock.c:read_smb_length_return_keepalive(623)
got smb length of 68
[2012/08/29 12:17:27, 3] lib/access.c:check_access(312)
check_access: no hostnames in host allow/deny list.
[2012/08/29 12:17:27, 2] lib/access.c:check_access(323)
Allowed connection from (192.168.0.46)
[2012/08/29 12:17:27, 6] smbd/process.c:process_smb(1067)
got message type 0x81 of len 0x44
[2012/08/29 12:17:27, 3] smbd/process.c:process_smb(1068)
Transaction 0 of length 72
[2012/08/29 12:17:27, 2] smbd/reply.c:reply_special(324)
netbios connect: name1=WEBSERVER name2=COMMON1
[2012/08/29 12:17:27, 2] smbd/reply.c:reply_special(331)
netbios connect: local=webserver remote=common1, name type = 0
[2012/08/29 12:17:27, 5] lib/username.c:Get_Pwnam_alloc(131)
Finding user common1
[2012/08/29 12:17:27, 5] lib/username.c:Get_Pwnam_internals(75)
Trying _Get_Pwnam(), username as lowercase is common1
[2012/08/29 12:17:27, 5] lib/username.c:Get_Pwnam_internals(93)
Trying _Get_Pwnam(), username as uppercase is COMMON1
[2012/08/29 12:17:27, 5] lib/username.c:Get_Pwnam_internals(102)
Checking combinations of 0 uppercase letters in common1
[2012/08/29 12:17:27, 5] lib/username.c:Get_Pwnam_internals(108)
Get_Pwnam_internals didn't find user [common1]!
One thing I notice is that it is trying to connect using the username COMMON1, which is the computer name of the XP Workstation I am trying to map from. Why? I have almost this exact same smb.conf in another Linux computer and it appears to use the guest account ID, not the computer name.
My designated guest account: ohprso, is in /etc/passwd and also in the samba password file. I've tried removing 'preferred master' and 'wins support', but that didn't help.
Need help ... again!
I put this in my config
map to guest = bad user
Then it doesn't matter what credentials you pass,
because if they fail you'll get logged in as guest.
map to guest = bad user
Then it doesn't matter what credentials you pass,
because if they fail you'll get logged in as guest.
For anyone else reading this ticket normally you'd need this too
guest account = nobody
But I see "jmarkfoley" already has it set to something.
guest account = nobody
But I see "jmarkfoley" already has it set to something.
You have passdb=tdbsam
This might suggest that SMb might be configured as a samba
You may need to add the user
Check your other to see whether you have the difference in the passdb.
This might suggest that SMb might be configured as a samba
You may need to add the user
Check your other to see whether you have the difference in the passdb.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
arnold: not sure I understand your comments ...
> You have passdb=tdbsam
> This might suggest that SMb might be configured as a samba
Configured as a samba ... what?
> You may need to add the user
This user is already in the passdb file
> Check your other to see whether you have the difference in the passdb.
Check my other ... what?
I don't know how to query the password file. man smbpasswd doesn't say how.
mtsdemo: I tried installing an upgraded version of samba (3.6.7) since the 3.5.8 version on another machine seems to work fine. However, I was not successful in the install; could never get nmbd to run, don't really know why.
So, I'll give the patch idea a shot, but I've been to that site you referenced and don't see any link for downloading a patch. Am I missing something?
> You have passdb=tdbsam
> This might suggest that SMb might be configured as a samba
Configured as a samba ... what?
> You may need to add the user
This user is already in the passdb file
> Check your other to see whether you have the difference in the passdb.
Check my other ... what?
I don't know how to query the password file. man smbpasswd doesn't say how.
mtsdemo: I tried installing an upgraded version of samba (3.6.7) since the 3.5.8 version on another machine seems to work fine. However, I was not successful in the install; could never get nmbd to run, don't really know why.
So, I'll give the patch idea a shot, but I've been to that site you referenced and don't see any link for downloading a patch. Am I missing something?
ASKER
mtsdemo: how about giving me the whole procedure at once. I've not patched anything before so I don't know what to do with the attachment you've referenced.
Try this
patch -p1 < "downloaded_patch_file"
patch -p1 < "downloaded_patch_file"
ASKER
patch: **** strip count i is not a number
should I be in some particular working directory?
should I be in some particular working directory?
ASKER
Ah, my bad. I did 'patch -p1 patchfile', not 'patch -p1 <patchfile' (stdin) ... let me try again.
ASKER
OK, here what I got when I ran 'patch -p1 <patchfile'
1 15:02:49 root@webserver:/etc/samba
> patch -p1 <patchfile
can't find file to patch at input line 8
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|Index: nsswitch/winbindd_ads.c
|========================= ========== ========== ========== ========== ==
|RCS file: /home/cvs/samba/source/nss witch/winb indd_ads.c ,v
|retrieving revision 1.43.2.26
|diff -u -r1.43.2.26 winbindd_ads.c
|--- nsswitch/winbindd_ads.c 13 Oct 2003 14:03:06 -0000 1.43.2.26
|+++ nsswitch/winbindd_ads.c 11 Nov 2003 00:47:53 -0000
--------------------------
File to patch:
Thoughts? This appears to be wanting to patch C source files. Does that seem right?
1 15:02:49 root@webserver:/etc/samba
> patch -p1 <patchfile
can't find file to patch at input line 8
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|Index: nsswitch/winbindd_ads.c
|=========================
|RCS file: /home/cvs/samba/source/nss
|retrieving revision 1.43.2.26
|diff -u -r1.43.2.26 winbindd_ads.c
|--- nsswitch/winbindd_ads.c 13 Oct 2003 14:03:06 -0000 1.43.2.26
|+++ nsswitch/winbindd_ads.c 11 Nov 2003 00:47:53 -0000
--------------------------
File to patch:
Thoughts? This appears to be wanting to patch C source files. Does that seem right?
ASKER
As you say - it must be a samba 3 bug. Upgrading the samba version did the trick (still samba 3, though). I was not successful in figuring out the patch thing; probably best! :)
it drove me nuts too. I also had a hell of time patching. I fumbled through it, but I did not want to drag you through all the thorns I crawled trough.
Its good the update fixed it. When it happened to me, the update was not available so I had to patch.
Its good the update fixed it. When it happened to me, the update was not available so I had to patch.
https://bugzilla.samba.org/show_bug.cgi?id=722
There is a patch at that link.