LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
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 07-22-2010, 04:43 AM   #1
windstory
Member
 
Registered: Nov 2008
Posts: 486

Rep: Reputation: 36
samba ask "password" at windows explorer


Samba ask "password" at windows 7 x64.

1. systems
192.168.0.2 - windows 7 x64
192.168.0.4 - centos 5.4 x86

2. smb.conf

Quote:
[global]
workgroup = WINDSTORY
server string = Samba Server Version %v

netbios name = mysamba

; interfaces = lo eth0 192.168.12.2/24 192.168.13.2/24
; hosts allow = 127. 192.168.12. 192.168.13.
# logs split per machine
; log file = /var/log/samba/%m.log
# max 50KB per log file, then rotate
; max log size = 50
security = share
passdb backend = tdbsam
; realm = MY_REALM
; password server = <NT-Server-Name>
; domain master = yes
; domain logons = yes
# the login script name depends on the machine name
; logon script = %m.bat
# the login script name depends on the unix user used
; logon script = %u.bat
; logon path = \\%L\Profiles\%u
# disables profiles support by specifing an empty path
; logon path =
; add user script = /usr/sbin/useradd "%u" -n -g users
; add group script = /usr/sbin/groupadd "%g"
; add machine script = /usr/sbin/useradd -n -c "Workstation (%u)" -M -d /nohome -s /bin/false "%u"
; delete user script = /usr/sbin/userdel "%u"
; delete user from group script = /usr/sbin/userdel "%u" "%g"
; delete group script = /usr/sbin/groupdel "%g"
; local master = no
; os level = 33
; preferred master = yes
; wins support = yes
; wins server = w.x.y.z
; wins proxy = yes

; dns proxy = yes

; load printers = yes
cups options = raw

; printcap name = /etc/printcap
#obtain list of printers automatically on SystemV
; printcap name = lpstat
; printing = cups

# --------------------------- Filesystem Options ---------------------------
; map archive = no
; map hidden = no
; map read only = no
; map system = no
username map = /etc/samba/smbusers
; encrypt passwords = yes
; guest ok = no
; guest account = nobody
; store dos attributes = yes


#============================ Share Definitions ==============================

[homes]
comment = Home Directories
browseable = no
writable = yes
; valid users = %S
; valid users = MYDOMAIN\%S

[printers]
comment = All Printers
path = /var/spool/samba
browseable = no
; guest ok = no
; writable = no
printable = yes

# Un-comment the following and create the netlogon directory for Domain Logons
; [netlogon]
; comment = Network Logon Service
; path = /var/lib/samba/netlogon
; guest ok = yes
; writable = no
; share modes = no


# Un-comment the following to provide a specific roving profile share
# the default is to use the user's home directory
; [Profiles]
; path = /var/lib/samba/profiles
; browseable = no
; guest ok = yes


# A publicly accessible directory, but read only, except for people in
# the "staff" group
; [public]
; comment = Public Stuff
; path = /home/samba
; public = yes
; writable = yes
; printable = no
; write list = +staff

[html]
comment = html
path = /var/www/html
writeable = yes
browseable = yes
public = yes
valid users = maestro
write list = maestro
3. windows 7 modification according to this guide
http://www.linuxplanet.com/linuxplan...orials/6911/1/

After these steps, I can view centos and html folder at network of windows 7's explorer, however when I click "html" folder window is asking user name and passwords loaded with a message "The specified network password is not correct"

please let me know how to solve this.

Thanks in advance.
 
Old 07-22-2010, 06:52 AM   #2
djsmiley2k
Member
 
Registered: Feb 2005
Location: Coventry, UK
Distribution: Home: Gentoo x86/amd64, Debian ppc. Work: Ubuntu, SuSe, CentOS
Posts: 343
Blog Entries: 1

Rep: Reputation: 72
[html]
comment = html
path = /var/www/html
writeable = yes
browseable = yes
public = yes
valid users = maestro
write list = maestro


I believe the write list is the group, not the username.

So check your 'groups' and see which your in, try setting it as users.
 
Old 07-22-2010, 06:56 AM   #3
alli_yas
Member
 
Registered: Apr 2010
Location: Johannesburg
Distribution: Fedora 14, RHEL 5.5, CentOS 5.5, Ubuntu 10.04
Posts: 559

Rep: Reputation: 92
Under the [html] share the following line is probably why you get asked for a password:

Code:
valid users = maestro
You can either:

1. Configure a password for maestro with smbpasswd or system-config-samba; OR
2. Comment it out and it should work as the other shares do. Note the previous user is correct that you should specify a group not a user as your writelist.
 
Old 07-22-2010, 07:55 AM   #4
windstory
Member
 
Registered: Nov 2008
Posts: 486

Original Poster
Rep: Reputation: 36
djsmiley2k and alli_yas/ Thanks, and I changed smb.conf as you said above

Quote:
[html-vbox]
path = /var/www/html
comment = html-vbox
; valid users = maestro
; write list = maestro
admin users = maestro
read only = no
; available = yes
; browseable = yes
; guest ok = no
; printable = no
locking = no
strict locking = no
But same result.

Last edited by windstory; 07-22-2010 at 08:05 AM.
 
Old 07-22-2010, 08:15 AM   #5
windstory
Member
 
Registered: Nov 2008
Posts: 486

Original Poster
Rep: Reputation: 36
OK, I got this debug message.
debug command,
Quote:
smbclient '\\192.168.0.2\html' -U win7backup -d=5
last part of message
Quote:
Domain=[WINDSTORY-PC] OS=[Windows 7 Ultimate 7600] Server=[Windows 7 Ultimate 6.1]
session setup ok
size=35
smb_com=0x75
smb_rcls=204
smb_reh=0
smb_err=49152
smb_flg=136
smb_flg2=51201
smb_tid=0
smb_pid=5257
smb_uid=2049
smb_mid=4
smt_wct=0
smb_bcc=0
tree connect failed: NT_STATUS_BAD_NETWORK_NAME
 
Old 07-22-2010, 08:32 AM   #6
windstory
Member
 
Registered: Nov 2008
Posts: 486

Original Poster
Rep: Reputation: 36
djsmiley2k and alli_yas/ You're right.

I found this - http://realtechtalk.com/Samba_SMB_Er...D-110-articles

Quote:
net use * /delete
At windows, I ran this command, and open "\\maestro_vb\html-vbox", then no problem!
 
Old 08-25-2010, 08:05 AM   #7
djsmiley2k
Member
 
Registered: Feb 2005
Location: Coventry, UK
Distribution: Home: Gentoo x86/amd64, Debian ppc. Work: Ubuntu, SuSe, CentOS
Posts: 343
Blog Entries: 1

Rep: Reputation: 72
Nice to know I got something right! Strangely I haven't had to make any changes for my fiance's win7 system.

Weird!
 
  


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 - windows files lose "created on" date stamp when moved to samba share on linux jaredk51 Linux - Software 5 02-19-2010 04:13 PM
About implementing "NT-style" password complexity on Samba PDC helloworld01 Linux - Server 0 11-30-2009 07:13 AM
Samba PDC: Windows NT client always displays "Welcome to windows NT" checkmate3001 Linux - Server 3 02-24-2008 04:33 AM
"Password Sync" of Samba in Debian swmok Debian 0 10-21-2006 05:18 AM
"remote explorer" needed from Windows for RH9 without GUI m-blaster Linux - Newbie 14 11-07-2004 12:26 PM


All times are GMT -5. The time now is 09:06 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration