LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 01-18-2007, 08:29 PM   #1
Niceman2005
Member
 
Registered: Nov 2004
Distribution: Fedora Core 2
Posts: 330

Rep: Reputation: 30
Samba: Cannot access share files from win98 but winxp ok


Dear friends,

I have configured my smb.conf as follow:
[global]
workgroup = ABC
netbios name = pc1
security = user
encrypt password = yes

[Music]
path = /MyMusic
valid users = user1
guest ok = yes
writable = yes

When i access from WinXP, it works fine with the username=user1 and password, but when i access from win98 it prompt a box that automatically fill the username with //pc1/11 and password request me to fill in. When i fill in the password of user1 it didnt work and reprompt. Why does it work on WINXP while win98 seems not working with the same configuration file? any idea ? or is there way i can configure so it will just allow access rather than ask for username and password?

thanks for taking time helping!

Regards
Y
 
Old 01-19-2007, 01:47 AM   #2
cyberfreaker2k
LQ Newbie
 
Registered: Nov 2003
Location: Bangalore
Distribution: Fedora core 6
Posts: 19

Rep: Reputation: 1
win9x does not suport user security with encryption i beleive
try security=share
and encryption=no
 
Old 01-19-2007, 08:24 AM   #3
doc.nice
Member
 
Registered: Oct 2004
Location: Germany
Distribution: Debian
Posts: 274

Rep: Reputation: 34
NACK, cyberfreaker2k: Win 98 can use encrypted passwords with user mode, this is the default setting in Win98, you must explictily change a registy value to use unencrypted passwords!

You have to use a username that exists on the samba server, so in your case, you could use username "user1". Wehen these credentials will work from winXP, they also should work from Win 98.
To use the user 11 from machine pc1 (//pc1/11) you would have to create it on the linux machine using adduser AND smbpasswd. (as you did with user1 i assume)

excerpts from man smb.conf ([X] you want to read the whole manpage)
Quote:
encrypt passwords (G)
This boolean controls whether encrypted passwords will be negotiated
with the client. Note that Windows NT 4.0 SP3 and above and also
Windows 98 will by default expect encrypted passwords unless a reg-
istry entry is changed. To use encrypted passwords in Samba see the
chapter "User Database" in the Samba HOWTO Collection.

MS Windows clients that expect Microsoft encrypted passwords and
that do not have plain text password support enabled will be able to
connect only to a Samba server that has encypted password support
enabled and for which the user accounts have a valid encrypted pass-
word. Refer to the smbpasswd command man page for information
regarding the creation of encrypted passwords for user accounts.

The use of plain text passwords is NOT advised as support for this
feature is no longer maintained in Microsoft Windows products. If
you want to use plain text passwords you must set this parameter to
no.

In order for encrypted passwords to work correctly smbd(8) must
either have access to a local smbpasswd(5) file (see the smb-
passwd(8) program for information on how to set up and maintain this
file), or set the security = [server|domain|ads] parameter which
causes smbd to authenticate against another server.

Default: encrypt passwords = yes

[...]

security (G)
[...]
The default is security = user, as this is the most common setting
needed when talking to Windows 98 and Windows NT.
you may also be interested in this (specially the HOWTO): http://de.samba.org/samba/docs/
 
Old 01-21-2007, 09:45 PM   #4
cyberfreaker2k
LQ Newbie
 
Registered: Nov 2003
Location: Bangalore
Distribution: Fedora core 6
Posts: 19

Rep: Reputation: 1
Sorry about the Wrong Info

Thanks doc.nice for shedding Light!!
 
Old 01-22-2007, 12:47 AM   #5
Niceman2005
Member
 
Registered: Nov 2004
Distribution: Fedora Core 2
Posts: 330

Original Poster
Rep: Reputation: 30
Hi Guys,

Thanks a lot for your replies. Continue on my initial thread, the configuration i did works well with XP, when trying to access the pc1, it authenticates me for username and password. By entering the username=user1 and password, i managed to access the samba server.
However the same configuration didnt work for win98...what happens is, when i try to access the samba server from win98, it prompts me with following:

Enter Network password

You must supply a password to make this connection:
Resource: \\pc1\IPC$ (This is not editable)
Password: (This is editable)


Ok
Cancel


Weird, no matter how i change the configuration, the Resource tag is always there and not editable, contrasting to Win xp, xp enquires username and password, i dont understnad why win98 keep prompting with the Resouce tag and password.
I have tried to simplify the smb.conf very simple....still not working...

thanks a lot for taking time helping,

Regards
Y
 
Old 01-22-2007, 06:24 AM   #6
doc.nice
Member
 
Registered: Oct 2004
Location: Germany
Distribution: Debian
Posts: 274

Rep: Reputation: 34
check this:
in smb.conf, you should set "Map to Guest = Bad User" in Global section

The default is "Never", but Win98 will try to connect to IPC$ (the share list etc.) with the currently logged on user. So you may have two ways to solve your problem:
1) Enable map to guest = bad user to allow your win98-client to get access to ipc$
2) create an linux+smb user with same username as your win 98 user

the first one seems to be the better choice, thats why I recommended it above...

if it doesn't help, could you please post your /var/log/log.smbd?


btw: normally, there is a sample smb.conf file in your doc folder or in /etc/samba, you should use this one and adapt it to your needs, that would give you reasonable defaults for such options like "Map to guest" etc.

HTH,
Flo
 
Old 01-22-2007, 07:16 PM   #7
Niceman2005
Member
 
Registered: Nov 2004
Distribution: Fedora Core 2
Posts: 330

Original Poster
Rep: Reputation: 30
Hi doc.nice!

Wow! thanks a lot, it works now hehe. After adding the line Map to Guest = Bad User.
Thanks a lot!

Thanks to cyberfreak too!! thanks!
 
Old 08-22-2008, 03:50 AM   #8
simke
Member
 
Registered: May 2004
Location: Malaysia
Distribution: Fedora Core 15, Open Suse 11.4, Ubuntu 11.04, Knoppix 5.1.1, Debian 6.0
Posts: 42

Rep: Reputation: 15
G'day Doc.Nice! I tried your solution but Win98 client still can't access to Samba, Win XP client OK! Here attached smb.conf:
[global]
workgroup = Workgroup
printing = cups
printcap name = cups
printcap cache time = 750
cups options = raw
load printers = Yes
use client driver = Yes
map to guest = Bad User
include = /etc/samba/dhcp.conf
logon path = \\%L\profiles\.msprofile
logon home = \\%L\%U\.9xprofile
logon drive = P:
usershare allow guests = Yes
add machine script = /usr/sbin/useradd -c Machine -d /var/lib/nobody -s /bin/false %m$
domain logons = No
domain master = No
smb ports = 139
netbios name = Suse
server string = Samba on Suse 11.0
security = User
encrypt passwords = Yes

[printers]
comment = All Printers
path = /var/tmp
printable = Yes
# create mask = 0600
create mask = 0700
browseable = No
guest ok = Yes

[print$]
comment = Printer Drivers
path = /var/lib/samba/drivers
write list = @ntadmin root
force group = ntadmin
create mask = 0664
directory mask = 0775

;
## Share disabled by YaST
# [netlogon]

[samba]
comment = Samba share on Suse 11.0
inherit acls = Yes
path = /Samba/
read only = Yes

Thanks.
 
Old 08-24-2008, 09:48 AM   #9
doc.nice
Member
 
Registered: Oct 2004
Location: Germany
Distribution: Debian
Posts: 274

Rep: Reputation: 34
Do you have a user on linux with the same name as in windows or do you try the guest version I mentioned above?

you may try if it helps creating a linux user
(using adduser or useradd) and then enabling it for samba using smbpasswd and/or pdbedit...

if it does not work, posting a smbd.log file may help identifying the problem.

another problem could be that the files or directory are not accessible by the linux nobody user that is used for the samba guest access...
try setting o+rx for the directory /Samba/ (chmod o+rx /Samba/) and at least read access for the files (chmod o+r /Samba/*, see man chmod for more).
 
Old 08-24-2008, 09:49 PM   #10
simke
Member
 
Registered: May 2004
Location: Malaysia
Distribution: Fedora Core 15, Open Suse 11.4, Ubuntu 11.04, Knoppix 5.1.1, Debian 6.0
Posts: 42

Rep: Reputation: 15
Quote:
Originally Posted by doc.nice View Post
Do you have a user on linux with the same name as in windows or do you try the guest version I mentioned above?
Simke: Yes, both.

you may try if it helps creating a linux user
(using adduser or useradd) and then enabling it for samba using smbpasswd and/or pdbedit...
Simke: Yes, did that!

if it does not work, posting a smbd.log file may help identifying the problem.

another problem could be that the files or directory are not accessible by the linux nobody user that is used for the samba guest access...
try setting o+rx for the directory /Samba/ (chmod o+rx /Samba/) and at least read access for the files (chmod o+r /Samba/*, see man chmod for more).
Simke: Yes, did that too.

G'day Doc.Nice! Sorry for not explaining clearly earlier! Here is the actual situation:
From Win98 client, it prompts me with following:

Enter Network password

You must supply a password to make this connection:
Resource: \\suse\IPC$ (This is not editable)
Password: (This is editable)

Even though I logged in Win98 client with the same username & password I did on my Win XP client, it didn't work!

Here, I attached my smbd.log:
[2008/08/23 10:42:39, 0] printing/print_cups.c:cups_connect(68)
Unable to connect to CUPS server localhost:631 - Address family not supported by protocol
[2008/08/23 10:42:39, 0] printing/print_cups.c:cups_connect(68)
Unable to connect to CUPS server localhost:631 - Address family not supported by protocol
[2008/08/23 16:03:07, 1] smbd/service.c:make_connection_snum(1188)
bis-7 (192.168.0.204) connect to service laserjet1000 initially as user simke (uid=1000, gid=100) (pid 3993)
[2008/08/23 16:04:10, 1] smbd/service.c:close_cnum(1399)
bis-7 (192.168.0.204) closed connection to service laserjet1000
[2008/08/23 16:08:21, 1] smbd/service.c:make_connection_snum(1188)
bis-7 (192.168.0.204) connect to service laserjet1000 initially as user simke (uid=1000, gid=100) (pid 9638)
[2008/08/23 16:09:45, 1] smbd/service.c:close_cnum(1399)
bis-7 (192.168.0.204) closed connection to service laserjet1000
[2008/08/23 16:11:44, 1] smbd/service.c:make_connection_snum(1188)
bis-7 (192.168.0.204) connect to service laserjet1000 initially as user simke (uid=1000, gid=100) (pid 9718)
[2008/08/23 16:12:47, 1] smbd/service.c:close_cnum(1399)
bis-7 (192.168.0.204) closed connection to service laserjet1000
[2008/08/25 08:41:19, 0] smbd/server.c:main(1208)
smbd version 3.2.0rc1-22.1-1795-SUSE-SL11.0 started.
Copyright Andrew Tridgell and the Samba Team 1992-2008

Note that on 23rd-Aug successful log-in was from Win XP client. Win98's failed attempts were not recorded at all including today 25th-Aug's attempts!
Thanks.
 
Old 08-25-2008, 05:06 PM   #11
doc.nice
Member
 
Registered: Oct 2004
Location: Germany
Distribution: Debian
Posts: 274

Rep: Reputation: 34
i will diff your config posted above with my one and will return... hold on
 
Old 08-31-2008, 11:22 AM   #12
doc.nice
Member
 
Registered: Oct 2004
Location: Germany
Distribution: Debian
Posts: 274

Rep: Reputation: 34
ok, sorry for the long time waiting.

My config file differs from yours only in some relevant settings:
I completely omitted the two following lines:
Code:
 security = User
 encrypt passwords = Yes
and my config sets
Code:
 domain logons = Yes
 os level = 65
 preferred master = Yes
 domain master = Yes
 wins support = Yes
but I think this should not be relevant for you, as I use my samba server as primary domain controller...

so sorry to help you not any more, this is all my wisdom provides...
 
Old 09-05-2008, 12:47 AM   #13
simke
Member
 
Registered: May 2004
Location: Malaysia
Distribution: Fedora Core 15, Open Suse 11.4, Ubuntu 11.04, Knoppix 5.1.1, Debian 6.0
Posts: 42

Rep: Reputation: 15
Thank you anyway for your help, Doc.Nice!
At least, now I managed to get the network printer to work with Win98 PCs.
Am still trying out ways to access those folders share on Samba!
Will post an update if there is any break through!

Regards,
 
Old 09-05-2008, 01:13 AM   #14
doc.nice
Member
 
Registered: Oct 2004
Location: Germany
Distribution: Debian
Posts: 274

Rep: Reputation: 34
I wuld be happy to read the final resolution here, thanks. Hope you will succeed...
 
Old 09-26-2008, 01:36 AM   #15
tonyoh888
LQ Newbie
 
Registered: Sep 2008
Posts: 1

Rep: Reputation: 0
Quote:
Originally Posted by simke View Post
Thank you anyway for your help, Doc.Nice!
At least, now I managed to get the network printer to work with Win98 PCs.
Am still trying out ways to access those folders share on Samba!
Will post an update if there is any break through!

Regards,
you can try to set below at global settings
username map = /etc/samba/user.map

this is contents of user.map
aaa bbb

aaa = user in linux
bbb = user in windows 98

this is to map the windows 98 user name with linux user name
 
  


Reply

Tags
guest, samba, samba users, solution



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Samba with WinXP and Win98 jbstew32 Linux - Networking 3 04-04-2004 12:30 PM
Win98 cannot acces share on Samba jonabyte Linux - Software 7 12-02-2003 08:04 AM
winxp can't access my samba share?? andrewlkho Linux - Software 2 08-29-2003 05:00 PM
Same old Problem, Win98 cannot access Samba share! mutantjazz Linux - Software 12 11-13-2002 10:51 AM
Win98 can't access Linux files, via Samba cornell Linux - General 8 07-19-2001 01:54 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 06:45 PM.

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