Iam new to the samba, so can anyone please give basic information to configure smb.conf.

And also how it provides permissions and authentication?

link|improve this question
feedback

2 Answers

The portion of smb.conf that creates an actual share looks like this:

[foobar]
   comment = the foobar directory
   path = /usr/local/foobar

There are a lot more options that can be set for shares in smb.conf, but the above is the basic skeleton.

There are also many options that can be set in smb.conf that relate to general operation, and those control the authentication mechanism as well as much else. To give an exhaustive list would be difficult in a single answer, but the samba project's own how-to collection is a very good place to start.

As for permissions, once you have the authentication model set up, a rule of thumb that has served me well is: samba wants to associate your file-sharing connection with a specific unix user, and that will usually be the user that you authenticate as. samba will not let you do anything to a file that you couldn't do anyway if you were just logged in to the server as that user.

Even that can be configured to be untrue, but more times than I can count I've sorted out samba permissions problems by going into the server as that user and showing that e.g. write to the file doesn't work, or the directory is not listable (browsable).

link|improve this answer
feedback

In CentOS/Red Hat/Fedora systems you can use system-config-samba to easily configure samba service. If you want just a public shared, use preferences -> server configuration -> security -> authentication mode = shared. For user based authentication use user mode. Add the directories to be shared and the users permissions too.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.