My first go with OpenSuse, I’ve been a Windows man for years and had a go recently with Ubuntu. Suse is amazing! I’m blown away with the desktop, Yast is brilliant and the range of software is great.
I need to be able to write from a Windows rig to my new Suse machine so I followed the instructions here:
I have two other Windows machines, 7 and XP and have the same problem on each: I can read the shared directory but not write to it. I’m really not sure about user permissions. Here’s my Samba config file:
*# smb.conf is the main Samba configuration file. You find a full commented
version at /usr/share/doc/packages/samba/examples/smb.conf.SUSE if the
samba-doc package is installed.
Date: 2011-11-02
[global]
workgroup = WORKGROUP
passdb backend = tdbsam
printing = cups
printcap name = cups
printcap cache time = 750
cups options = raw
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
netbios name = linux-xoe9
security = user
usershare max shares = 100
wins server =
wins support = No
[homes]
comment = Home Directories
valid users = %S, %D%w%S
browseable = No
read only = No
inherit acls = Yes
[profiles]
comment = Network Profiles Service
path = %H
read only = No
store dos attributes = Yes
create mask = 0600
directory mask = 0700
[users]
comment = All users
path = /home
read only = No
inherit acls = Yes
veto files = /aquota.user/groups/shares/
[groups]
comment = All groups
path = /home/groups
read only = No
inherit acls = Yes
[printers]
comment = All Printers
path = /var/tmp
printable = Yes
create mask = 0600
browseable = No
[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]*
The folder I’m trying to share is my “Documents” folder.
I used Dolphin to change the permissions tab options to “Can view and modify Content”
On the Share tab I ticked “Share with Samba” and “Allow Guests”. In this tab my user name (dad) I gave “Full Control” but “Everyone” keeps defaulting back to “Read Only”
You are trying to use the Dolphin GUI to change the contents of smb.conf so that directory /home/dad/Documents is shared. Here’s a quick way: open smb.conf in a text editor and make the necessary changes direct to the file.
This command in a konsole window will open the file for editing (just like “notepad” does in windows):
kdesu kwrite /etc/samba/smb.conf
Then type (or copy/paste) this text at the bottom:
[Documents]
path = /home/dad/Documents
guest ok = yes
read only = no
force user = dad
In summary you have to remove the RPM sysvinit-init. You can do that in Yasy → software → software management → search → use the trem sysvinit-init. Delete it (and it will auto install systemd-sysvinit as well). That will fix the bug.
>
> My first go with OpenSuse, I’ve been a Windows man for years and had a
> go recently with Ubuntu. Suse is amazing! I’m blown away with the
> desktop, Yast is brilliant and the range of software is great.
>
> I need to be able to write from a Windows rig to my new Suse machine so
> I followed the instructions here:
>
<snip>
> I have two other Windows machines, 7 and XP and have the same problem
> on each: I can read the shared directory but not write to it. I’m
> really not sure about user permissions. Here’s my Samba config file:
>
<snip>
>
> The folder I’m trying to share is my “Documents” folder.
>
> I used Dolphin to change the permissions tab options to “Can view and
> modify Content”
>
> On the Share tab I ticked “Share with Samba” and “Allow Guests”. In
> this tab my user name (dad) I gave “Full Control” but “Everyone” keeps
> defaulting back to “Read Only”
>
> Thanks in anticipation.
>
Suseclues;
I’m guessing that the Linux permission on your Documents directory does not
permit the “other users” to write. Samba must obey the Linux permissions.
When a user authenticates as guest on Samba they are identified as the Linux
user “nobody” and thus among the “other users”. As such the guest user will
not be able to write. One way around this is to give “other” write
permission:
su
chmod o+w <path to share>
Alternatively, you could use a traditional share and write your share
definition in /etc/samba/smb.conf. For example:
[YourShareName]
path = <full path to your share>
force user = Suseclues
read only = No
inherit acls = Yes
guest ok = yes
I followed Swerdna’s instructions with no success and venzkep’s with no success (I edited Swerdna’s additions to reflect venzkep’s), please see below:
# smb.conf is the main Samba configuration file. You find a full commented
# version at /usr/share/doc/packages/samba/examples/smb.conf.SUSE if the
# samba-doc package is installed.
# Date: 2011-11-02
[global]
workgroup = WORKGROUP
passdb backend = tdbsam
printing = cups
printcap name = cups
printcap cache time = 750
cups options = raw
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
netbios name = linux-xoe9
security = user
usershare max shares = 100
wins server =
wins support = No
name resolve order = bcast host lmhosts
[homes]
comment = Home Directories
valid users = %S, %D%w%S
browseable = No
read only = No
inherit acls = Yes
[profiles]
comment = Network Profiles Service
path = %H
read only = No
store dos attributes = Yes
create mask = 0600
directory mask = 0700
[users]
comment = All users
path = /home
read only = No
inherit acls = Yes
veto files = /aquota.user/groups/shares/
[groups]
comment = All groups
path = /home/groups
read only = No
inherit acls = Yes
[printers]
comment = All Printers
path = /var/tmp
printable = Yes
create mask = 0600
browseable = No
[print$]
comment = Printer Drivers
path = /var/lib/samba/drivers
write list = @ntadmin root
force group = ntadmin
create mask = 0664
directory mask = 0775
[Documents]
path = /home/dad/Documents
guest ok = yes
read only = no
force user = dad
inherit acls = yes
## Share disabled by YaST
# [netlogon]
I am able to write from Windows by adding a Samba user the same as my main user id (dad) but then I can see and edit everything on my Suse machine