USB volumes cannot be read via SMB

I’m trying to remotely access my local media files on a USB attached drive (FAT32).

Internal Storage and NAS shares work and are even writeable by guests (I would prefer limiting guests to read only).

The USB share mounts and shows the attached drive volume. But drive cannot be read: “The folder <volume_name> can’t be opened because you don’t have permission to see its contents.” Web & forum searches produced no relevant threads (but most of my forum searches were rejected for “too common search terms”: SMB).

I added a smb password for volumio (sudo smbpasswd -a volumio) and can connected as that user but the USB drive is still unreadable.

I have not modified any the smb config files. I’ve found the following ones but it’s unclear which ones are actually used in the custom volumio build. But I don’t see anything that looks amiss for USB share relative to the other shares. But obviously it has to do with drive volume permissions under the USB share.

/etc/samba/smb.conf /usr/share/samba/smb.conf /static/etc/samba/smb.conf /static/run/samba/upgrades/smb.conf /static/usr/share/samba/smb.conf

/etc/samba/smb.conf:

[code][global]
netbios name = Arvin
server string = Audiophile Music Player
workgroup = WORKGROUP
security = user
map to guest = Bad User
encrypt passwords = yes
wins support = yes
local master = no
preferred master = no
os level = 30

[Internal Storage]
comment = Arvin Internal Music Folder
path = /data/INTERNAL
read only = no
guest ok = yes

[USB]
comment = Arvin USB Music Folder
path = /mnt/USB
read only = no
guest ok = yes

[NAS]
comment = Arvin NAS Music Folder
path = /mnt/NAS
read only = no
guest ok = yes
[/code]

I can access the /mnt/USB/<volume_name> normally via ssh as volumio user. Read & write work as expected so it doesn’t appear to be the mount itself.

Thanks in advance.

1 Like

I’m a little confused by your post.

You say the USB drive mounts ok (btw, how did you confirm this?). but you can’t read the content, but then at the end of your post you say:

which seems to contradict what you said above.

Sorry if I wasn’t clear enough. The Volumio USB SMB share will mount/connect on the remote computer and show the USB drive as a folder (the entire contents of that share as there is only one USB drive connected), but you cannot open (read) the drive contents (as a folder under USB share) itself via SMB on the remote computer.

"The folder <volume_name> can’t be opened because you don’t have permission to see its contents."

The Volumio NAS and Internal shares mount and all contents work for read & write.

Reading the drive via Volumio (Browse > Music Library > USB > volume_name) or as a local user (via ssh) reads and writes fine. So all permissions are correct for local users, but the same username/passwd added as smb user cannot read the USB drive itself. I cannot find anywhere to set the SMB permissions for the USB drive (other than smb.conf which appears correct as fas as the USB share is concerned).

While not a true fix for the USB share, this worked to get access to the USB drive for me:

[Media Storage] comment = Volumio Media Storage path = /media/<volume_name> writeable = yes guest ok = no create mask = 0777 directory mask = 0777 force user = volumio

adding the last 3 lines to the USB share did not fix access to the drive volume in that share. Nothing changed.

I wouldn’t call it [Solved] as I still do not understand why the default USB share doesn’t work but I can remotely manage my media files now.

I checked permissions within the /media folder that the USB share links to and it’s all 0777. Likewise the permissions inside the drive look normal. The only significant delta between the shares that occurs to me is that the drive is FAT32 rather than ext4.