1

I am trying to connect windows 10 and CentOS 8 using Samba. These are the commands I have user

yum install samba samba-client samba-common -y 

These are the configurations in /etc/samba/smb.conf

[global]
workgroup = WORKGROUP
server string = Samba Server %v
netbios name = centos
security = user
map to guest = bad user
dns proxy = no
#============================ Share Definitions ==============================
[Anonymous]
path = /samba/anonymous
browsable =yes
writable = yes
guest ok = yes
read only = no

This is the folder I have created to be shared

mkdir -p /samba/anonymous

Added the service to the firewall

firewall-cmd --permanent --zone=public --add-service=samba

Changed the permission and context

chmod -R 0755 anonymous/
chown -R nobody:nobody anonymous/
chcon -t samba_share_t anonymous/

Now I am able to see the folder in both the windows and CentOS, but when I create anything in windows system I am not able to see it in the centOS shared folder. What went wrong here? I am new to this so I have no clue other than this.

6
  • Have you tested by mounting on CentOS and creating a file? So that you can see if it is network/windows problem or linux problem. Oct 13, 2021 at 5:31
  • 1
    How to mount? I think samba used to work without any of that Oct 13, 2021 at 5:36
  • I mean can you create a file when you login from the same machine where the share resides? Oct 13, 2021 at 5:39
  • Yes I can create a file in CentOS in the same folder Oct 13, 2021 at 6:22
  • You created it over samba? Then it may be a windows problem. Oct 13, 2021 at 7:05

1 Answer 1

1

I was able to solve this by creating /home/anonymous directory. I changed the path option in smb.conf to point to this directory, and the problem was solved

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .