Migration centos from 6 to 7 - Samba config - can access file but can't get permission

General support questions
Post Reply
cassanovade
Posts: 4
Joined: 2019/04/26 03:24:42

Migration centos from 6 to 7 - Samba config - can access file but can't get permission

Post by cassanovade » 2022/07/28 08:26:49

Hi everyone...,
need for your help.

before im using samba from Centos 6, and now want to setup into centos 7.
everything is ok when im use file sharing from samba service centos 6 - access from windows.
in short, when i applied my config from centos 6, into centos 7 (made approach as my samba on sentos 6 before), when im access from windows the folder share, it comes some warning:

" Windows Cannot Access \\ip.address\folder" You do not have permission to access etc..."
Screenshot 2022-07-28 103345.png
Screenshot 2022-07-28 103345.png (34.47 KiB) Viewed 478 times
here is my config :

Code: Select all


[global]
	workgroup = FILE SERVER
	security = user
	passdb backend = tdbsam
	netbios name = giserver
	log file = /var/log/samba/%m.log
	max log size = 5000
	local master = yes
	os level = 33
	preferred master = yes
	hide unreadable = yes
	hide dot files = yes
	encrypt passwords = yes
	guest ok = yes
	guest account = nobody
	usershare allow guests = yes

[homes]
	comment = Home Directories
	browseable = No
	read only = No
	inherit acls = Yes
	writable = yes
	valid users = %S
	create mask =0755
	directory mask =0755
	
[Cm]
	comment = Share Data CM
	path = /share/CM
	read only = yes
	public = no
	browseable = yes	
	valid users = @cm @ci @ etc....
	write list = atikah,clara, etc
	force group = cm
	force create mode = 0775
	force directory mode = 0775
	create mask = 0775
	directory mask = 0775
......
...
..
...
......

i have some user which is they are in one group called "cm", also i'm already setup the priviledge.
Screenshot 2022-07-28 113059.png
Screenshot 2022-07-28 113059.png (42.87 KiB) Viewed 478 times
this one is in Group config file :

Code: Select all

....
......
atikah:x:1014:
......
...
pck:x:1124:userpck1,userpck2, etc...
cm:x:1125:atikah,clara, etc...
sample:x:1126:usersample1,usersample2, etc ...
...
.....
this is the user i've created, this one is in passwd config file :

Code: Select all

 
...
......
atikah:x:1014:1014::/home/atikah:/bin/bash
......
...
the /home/atikah priviledge was :
Screenshot 2022-07-28 114511.png
Screenshot 2022-07-28 114511.png (26.19 KiB) Viewed 478 times

And the result still is, can't access the folder sharing from windows.
do you have any suggestion for my configuration ?

User avatar
TrevorH
Site Admin
Posts: 33216
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Migration centos from 6 to 7 - Samba config - can access file but can't get permission

Post by TrevorH » 2022/07/28 15:11:47

Did you read /etc/samba/smb.conf.example for instructions on how to set up selinux to allow sharing?
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

cassanovade
Posts: 4
Joined: 2019/04/26 03:24:42

Re: Migration centos from 6 to 7 - Samba config - can access file but can't get permission

Post by cassanovade » 2022/07/29 08:11:38

aaah..., thanks alot, finnaly found the blank spot. :)

actually im already doing the selinux command to change the context samba directory, my thought, it's just need one time to do that into home directory, while i already made a lot of sub directory in home/. But when i check, all of my sub directory in home, need to change also :mrgreen:

Post Reply