Share a folder between Linux host and Windows guest VM

qemusambashared-foldersvirt-managervirtual machine

I'm trying to share a folder between my main OS (openSUSE 42.1) to a guest Windows 7 virtual machine, but I'm unable to set it up properly.

I access the VM from virt-manager, and I've read that the best way to accomplish this is to use Samba.

I've added this section to my /etc/samba/smb.conf

[shared]
    comment = my shared folder
    guest ok = Yes
    inherit acls = Yes
    path = /home/user/shared
    read only = No
    browseable = Yes

and I set the permissions of /home/user/shared to drwxrwxrwx, and made sure that smb.service is up and running.

But when I run the Windows VM and I try to connect to the shared folder, I can't neither access or even see it.

How can I solve this?

Best Answer

The problem was that the Firewall was blocking the connections on the ports used by Samba.

I had to add the necessary exceptions and now it works as expected.

Related Question