[Samba] Missing execute permission


I’m using an external hdd with my raspberry 2 and activated the smb service and nearly all is fine. The only problem ist, that I’m not able to execute a video file from the smb share over the network with my windows notebook. I access the network share with the default user (osmc:osmc).

The security tab of a video file show me that there is not set up the execute permission. How can I do this?

Video files are not executed, they are “read”. You cannot set them as executable.

But I can’t execute/read the file over the network. Also I’m not able to change permissions with my windows notebook. Maybe I can took over the permissions and set it up on my own. But it might be better that osmc manage the permisson. So is it possible to add the execute permission for osmc user? At least for a test? I don’t know how.

This is the error from VLC:

You cannot make a file type that is not executable to be executable.

ok, but were is the problem with opening any video file?

  1. Let go from the idea that the file need to be “executable” as only files that are executed by the OS need to be executable (ok, not 100% accurate as in Linux also directories need to be executable).

  2. Try to copy the file over to your windows machine and try to play it locally to see if maybe the file has no proper video content

  1. Ok I might be wrong with the execute permission behaviour.
  2. I already done this. The file is ok and after copying it to my notebook, I’m able to play it.

Ok than I guess you are impacted by a bug that crashes samba when upper case letters are in the disk label.
You have two options:

  1. Change the disk label to lower case, the tool to do that depends on the filesystem
  2. edit on OSMC /etc/samba/smb.conf and put a # in front of the line usershare template share = automount template

hm… I had just opened the file again and again with vlc. The third time I tried to open the file, the file is played. So i checked this behaviour with other files and come to the following conclusion:

Some files can then be played after second or third try, others not or they start to play and the vlc error return. So could this be a network problem? It is also very very slow to copy files over the network to or from the hdd connected to the raspberry.

ok, know I do the smb.conf change you suggested and did a reboot. this seems to do the trick. Just to doublecheck I removed the suggested change and reboot. Still it works !?? this is so strange.

When you remove the # either restart samba or reboot.
You also can check dmesg you will see a crash message from samba

ok thank you. i will have an eye on it and do a check with dmesg if the problem occurs again.
thank you!