Solved

Samba configuration cannot open folders

Posted on 2012-03-09
5
379 Views
Last Modified: 2012-06-21
Hi,
I'm taking a class on Linux.  This week we are learning about Samba.  Trying to set it up so that I can r/w files on the share.  Using Centos 5.7.

I can view the \\servername\sharename from my Win 7 device.  I cannot open the folder.

I set up a Linux user.
I setup a Samba user.
I matched passwords from my Win7 box to the 2 Linux passwords.

I can't figure this out.

I am using the Samba Server Configuration and the Samba Web Administration Tool.

Please advise.

And thank you to all who post...
0
Comment
Question by:svillardi
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 16

Expert Comment

by:santoshmotwani
ID: 37704245
can u please paste the output of cat /etc/samba/smb.conf

thanks
0
 
LVL 1

Expert Comment

by:backhaul
ID: 37704930
Please provide more basic configuration as well as output so that we may help you with your configuration.

If you need help with what to give us (besides the smb.conf) please ask and we will gladly provide the commands and ways to give us output.
0
 

Author Comment

by:svillardi
ID: 37705046
Yes, I will need to know those commands.  I am learning this in school and I'm struggling...

Here's the smb.conf:

[admin@Centos ~]$ cat /etc/samba/smb.conf
# Samba config file created using SWAT
# from 127.0.0.1 (127.0.0.1)
# Date: 2012/03/07 23:51:11

[global]
        workgroup = workgroup
        server string = Samba Server Version %v
        passdb backend = tdbsam
        username map = /etc/samba/smbusers
        cups options = raw
        security = share
;       encrypt passwords = yes
;       guest ok = no
;       guest account = nobody

[printers]
        comment = All Printers
        path = /var/spool/samba
        printable = Yes
        browseable = No

[scott]
        path = /home/scott
        writeable = yes
;       browseable = yes
        guest ok = yes
0
 
LVL 7

Accepted Solution

by:
chandranjoy earned 500 total points
ID: 37706697
Hi,
Please make sure that you have followed the given below steps to share folders from Linux to windows.

Ex:
[global]
workgroup = PUTIEVILLE
server string = My Lil Linux Box
hosts allow = 192.168. 127.
log file = /var/log/samba/%m.log
security = user
encrypt passwords = yes
smb passwd file = /etc/samba/smbpasswd
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192

[Downloads]
comment = Downloads
path = /home/windisk/Downloads
browseable = yes
writable = yes
public = yes
read only = no 

Open in new window


Samba Users

Since we're using user level security (the best option when connecting to a WinNT based machine, such as Windows 2000 or Windows XP), we need to set up samba users.

First, lets create the smbpasswd file that we defined in the smb.conf file. The best way to go about this is to create it based on your existing /etc/passwd file. In other words, samba users are created based on existing linux users:

   
cat /etc/passwd | mksmbpasswd.sh > /etc/samba/smbpasswd

Open in new window


Chmod 600 this file (/etc/samba/smbpasswd) so that only root has read and write permissions.

However, this file only copies over Linux users to samba users. It doesn't copy over their passwords, as well. Therefore, use the following command to set each samba user's password:

   
smbpasswd username

Open in new window


Obviously, replace username with each of your user's usernames. You will then be prompted to enter a password for this user account. I like to set my samba user's passwords the same as their linux user counterparts. However, this isn't necessary.

Samba Service

Now that everything has been configured, the final step is to start the samba service. Samba runs in the background as a linux daemon. Therefore, it can be controlled by typing:

   
 service smb start
    service smb stop
    service smb restart

Open in new window


Note that once the computer is restarted or shutdown, the samba service won't start up again the next time. I use the GUI (xwindows) program serviceconf to set up all my services to execute automatically.

Reference URL:
http://www.daniweb.com/hardware-and-software/linux-and-unix/linux-kernel-and-hardware-setup/threads/1741


Thanks,
Jay
0
 

Author Comment

by:svillardi
ID: 37786957
No good.  Still doesn't work.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

rdate is a Linux command and the network time protocol for immediate date and time setup from another machine. The clocks are synchronized by entering rdate with the -s switch (command without switch just checks the time but does not set anything). …
Using 'screen' for session sharing, The Simple Edition Step 1: user starts session with command: screen Step 2: other user (logged in with same user account) connects with command: screen -x Done. Both users are connected to the same CLI sessio…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question