Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 02-05-2016, 11:00 AM   #1
LQ Newbie
Registered: Sep 2015
Posts: 6

Rep: Reputation: Disabled
Question samba - anonymous + write for user

hello, may I ask you for help about samba?

I want my samba server to have shares which are Read accessible to anyone (without any logging, just doubleclick) and also RW accessible for me (I have admin account there).

there will be me connecting on linux mint, windows xp and windows 7 and about 15 other people with no accounts on server, running everything possible. They are not the same people, so giving them account on server is nonsense.

So far I can see the shares on my win 7 computer but I cant open them without asking for permissions.

samba is running on raspbian jessie.
Old 02-06-2016, 11:19 PM   #2
LQ Sage
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,661

Rep: Reputation: Disabled
I'd use webfs to give read-only access over HTTP instead.
Old 02-06-2016, 11:46 PM   #3
Ser Olmy
Senior Member
Registered: Jan 2012
Distribution: Slackware
Posts: 3,332

Rep: Reputation: Disabled
There are two sets of permissions to consider here:
  • the permissions on the Samba share, as specified in smb.conf, and
  • the file system permissions on the directory to be shared
Both have to allow access for the directory to become available.

For anonymous access, you will need to map "Bad User" to guest, allow guest access to the share, and make sure the guest account has at least read permissions on the directory. Then you'll have to add your own account to the "valid users" list for the share.

You can handle the read vs. write permissions issue in (at least) two ways:
  1. Give all users write permissions on the share with the "read only = no" parameter, and control access using Unix permissions on the underlying files and directories
  2. Specify "read only = yes" on the share, and then list relevant accounts/groups that are to have write access using the "write list = <account> [<account>]" parameter
If you're not using the AD/Domain Controller functionality in Samba, using "write list" is probably the easiest way to accomplish what you want.

Should you find that you need to ask further questions regarding the actual implementation, please post the (sanitized if necessary) contents of smb.conf as well as the output of ls -l <directory> for the directory you're trying to share.
Old 02-13-2016, 03:53 PM   #4
LQ Newbie
Registered: Sep 2015
Posts: 6

Original Poster
Rep: Reputation: Disabled
Thank you. I recently set up webfs, because I consider it easier and faster. It was quite straightforward, I spent most time with permissions. Right now it's working as expected.

I am going to set up samba in next two weeks. I have a lot of (nearly 15) unsuccessful attempts with samba configuring - every time something was not quite what it should be, so I will gladly use of any help.


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
Where does SAMBA-SWAT write user info? Cerephim Linux - Server 4 01-21-2014 01:10 PM
Cups and Samba ppd printer anonymous user? nl1at Slackware 7 10-16-2009 05:40 AM
samba group user write kashif2131971 Linux - Newbie 2 06-03-2008 09:57 AM
Mount samba share at boot with user write permissions Wynd Linux - Software 2 08-22-2006 12:48 AM
Slackware 10.0 Samba: root can write, user cannot bhicks Slackware 15 11-19-2004 12:46 AM > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 04:20 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration