Music on NAS not showing up in library

Hi,

I installed Volumio on my Raspberry Pi and mounted a music folder on a Synology NAS via NFS. According to the web interface, the folder seems to be properly mounted:
Screen Shot 2014-07-20 at 20.12.07 .png

the ‘mount’ command gives me:

192.168.178.38://volume1/music on /mnt/NAS/music type nfs (ro,noatime,vers=3,rsize=131072,wsize=131072,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.168.178.38,mountvers=3,mountport=892,mountproto=udp,local_lock=none,addr=192.168.178.38)

However, there’s no music showing up in the library. Anyone has any clues how I could solve this? :frowning:

Thank you!
Yves

Already updated your library with mpd?
With library, you mean the browse tab or the library tab?
There is a bug with the library:
if you have over 10000 files, you will see an empty screen
See this Thread: http://volumio.org/forum/library-empty-after-scanning-18232-m4a-files-t1385.html for help

Yes, I updated the library. I don’t have that many files in my folder. Mostly WAVs and FLACs. I wanted to start with a small collection.

They neither show up in the browse, nor in the library tab.

Hi,

Is there already a solution for this? I have the same problem:

configuration:

  • Raspberry Pi with a hifiberry DAC; uname -a gives “Linux volumio 3.10.36+ #662 PREEMPT Fri Apr 4 18:31:16 BST 2014 armv6l GNU/Linux”
  • Synology DS214se NAS, running DSM 5.0-4493 Update 4
  • mounted Volumio via NFS to the Synology with these options: nfsvers=3,rw,noatime and as user volumio
  • I synchronized the UID and GID of user volumio on both the Synology and the Pi

Volumio works fine, radio works and a few sample albums on a USB stick are playing perfect, but no music from the Synology.

The mount is successful, in a shell I can see the mounted directory. I can even create a file from the Pi on the Synology. All music belongs to user volumio.

But when I look at the Browse tab on Volumio and go to NAS, I only see the stupid default Flac ditectory that is empty, and no directory on the Synology. Update MPD database does not help.

Please can anyone help in this matter because it frustrates very much!

Thanks in advance, Frans Joseph

I have the exact same issue - If I ssh into rasberry pi I can see and browse the mount using shell; The mount is there in “/mnt/NAS/”
yet when I try to use web interface nothing apart from “/mnt/NAS/Flac” which is empty.
Ive tried different users - pi, volumio and in ach time I can use shell to view files yet the browse function not showing any files.

mount uses
//192.168.1.20/Music on /mnt/NAS/Lounge_22 type cifs (ro,noatime,vers=1.0,sec=ntlmssp,cache=strict,username=volumio,domain=REIDHOUSE-MUSIC,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.1.20,unix,posixpaths,serverino,acl,rsize=8048,wsize=8096,actimeo=1)”

volumio works - web radio workds, usb mount works, just not NAS.

I noticed that the NAS was mounted Music with user:group “pi:pi”

ls -la
total 4100
drwxrwx— 263 pi pi 0 Sep 7 21:53 .
drwxrwxrwx 3 pi pi 4096 Sep 11 17:36 …
drwxrwx— 4 pi pi 0 Jun 16 2013 10,000 Maniacs
drwxrwx— 3 pi pi 0 Oct 11 2013 Above and Beyond
drwxrwx— 4 pi pi 0 Jun 16 2013 Adele
drwxrwx— 7 pi pi 0 Mar 19 10:04 Air
drwxrwx— 3 pi pi 0 Jun 16 2013 Alanis Morissette

Could this be issue ? Note sure what user reads NAS mount - perhaps user can’t “see” mount ?

which explicit mount options did you use? have you checked this thread?
smb-cifs-shares-volumio-t1461.html

//192.168.1.20/Music on /mnt/NAS/Lounge_22 type cifs (ro,noatime,vers=1.0,sec=ntlmssp,cache=strict,username=volumio,domain=REIDHOUSE-MUSIC,uid=0,noforceuid,gid=0,noforcegid,addr=192.168.1.20,unix,posixpaths,serverino,acl,rsize=8048,wsize=8096,actimeo=1)”

Thanks - The thread indicates the browse function uses file indexes - Is this the case or is it the library function which takes a time to generate or update the DB ?

In either case I’ve lfet the mount there for days and it nothing in NAS listed via Web GUI, yet bash shell (logged in as user pi) shows the mount as being there.

What permissions should /mnt/NAS/My_Music have ? and what User reads this mount.

Woody

Ok - some more information…

in file /var/log/mpd/mpd.log

Sep 12 10:46 : avahi: Service 'volumio' successfully established. Sep 12 10:48 : update: Failed to open directory /var/lib/mpd/music/NAS/Lounge_22: Permission denied

It is a permission issue …

User mpd cannot browse the NAS mount - the mount is mounted with user : group set to pi:pi

No sure how to fix this yet

I doubt you put that text in the “advanced options” in the webgui.
Which advanced options did you put in the webgui?

Also, the other thread gives you a clear set of steps to try to solve the problem, I think you haven’t tried them or you didn’t follow them accurately.

Hi all,

In my search I also found this thread in the forum of the former Raspyfi:
http://www.raspyfi.com/forum/raspyfi-install-and-troubleshooting/fail-to-generate-the-database-for-a-network-connection/

This concludes that - at least in those days - the mpd needs full access for all, so 777 for all files and directories. Otherwise it won’t work. On the comment in this forum saying that it is rather strange and not preferable to give all files these rights the admin’s reply was ‘take it or leave it’. Now I also think it is not a very nice way of setting up your system with all rights for everyone and I found it a bit a blunt answer for an admin.

However for the moment I changed the rights in 777 and now everything works. But I still would very much appreciate a solution.

Btw: my mounting flags for the nfs mount are nfsvers=3,rw,noatime

Cheers, Frans

Hi all -

you DON’T need to give MPD/Volumio full read/write permissions (777) all of your music files!

MPD needs execute permissions on the top directory where all of your music files are. Your music files themselves can be read-only.

So if your music is mounted at /mnt/NAS/music

you can do

chmod +x /mnt/NAS/music

to get MPD and Volumio to index your files.

The music files themselves can be 644!

Thanks bdouble for your answer. But still, that means you have to make all readable for the world, which should not be necessary.

To me it is very strange realizing that when:
a) both the NAS and the RPI have user ‘volumio’ and group ‘users’ with the same uid and gid respectively,
b) the RPI approaches the NAS over nfs with user volumio,
c) rights in the NAS are set to rwXrwX—

a) it IS possible to write as volumio on the NAS, and
b) it IS NOT possible for Volumio to update the MPD database…

I also tried to update the database with the files having all rights - that works of course - then changing rights to rwXrwX— for volumio:users and then no database update but just play a song: no success.

So I only can think now of other users than volumio who are the process owners of mpd update and playing music…

Regards, Frans

fransjoseph

yes - I’m having the very same issue here, its a user /permissions issue.

To get it to work I also had to expose files on share to “everyone” even though the SMB share has login and password to mount it. Im not happy about exposing files like this - its not as secure as I would like.

I think it has to do with the persmissions with user “mpd” on the raspberry pi; user “pi” and user “volumio” can read/browse share without exposing all files on share to everyone (using ssh/bash).

I don’t know password for use “mpd” to ssh using mpd user to confirm, but looking at user group information think use rmpd cant read the mount even though it is mounted.

irishwoody

You don’t need to make everything readable to everyone. My NAS has a user for volumio and other similar devices that are supposed to read only and either play movies or music. I set the permissions of the files in my share (in the NAS) as read-only for the volumio user. The music played.
I also set SMB (in the volumio options) as read-only, meaning that independently from the permissions of the files in the NAS, the whole SMB share for volumio is read-only.
It still works.

Maybe if you post the options you used in the GUI of Volumio, as I requested, we could help better.

The settings I use in mount are the default ones…

cache=strict,ro,noatime,dir_mode=0777,file_mode=0777

I confirm the mount is RO from volumio side (independently from settings on NAS);
I would like to set NAS permissions to 740 - prevent others from even seeing folders / files.
user name and password supplied to mount work correctly (user and password supplied are folder/file owner on NAS) - when I ssh into rasberry pi using user “volumio” I can browse /mnt/NAS/Lounge and all sub folders/directory, so moun is working - its just when I use browse from web GUI - I see no folders/files.

woody

Oh I see now.
Is it possible that the mpd database somehow got wrong permissions and cannot be modified? or, have you checked that there is space free in the SD card? I found that the logs (or something else, I forgot) were eating everything and nothing could be written.

volumio@volumio:~$ df -h
Filesystem Size Used Avail Use% Mounted on
rootfs 1.5G 535M 887M 38% /
/dev/root 1.5G 535M 887M 38% /
devtmpfs 235M 0 235M 0% /dev
tmpfs 49M 464K 49M 1% /run
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 256M 0 256M 0% /run/shm
/dev/mmcblk0p1 75M 19M 56M 25% /boot
Ramdisk 256M 0 256M 0% /run/shm

No issue with space - largest useage on any mount 38%.

What user generates mpd database ? if it is user “mpd” then this user probably has permissions issue and can’t browse the mount while user “volumio” can.
Setting the permissions on NAS to 644 or greater will allow all other users (in the pi) who have no explicit rights to browse the mount and to read the files.

btw this is case with two fresh installs of volumio 1.4beta - no online updates - no extra software installed - I just configured one mount point through the web GUI.

I have this:

[code]pi@volumio:~$ ls -l /var/lib/mpd/music/
total 4
lrwxrwxrwx 1 root root 9 Jul 13 2013 NAS -> /mnt/NAS/
lrwxrwxrwx 1 root root 8 Apr 8 20:58 RAMPLAY -> /run/shm
lrwxrwxrwx 1 root root 9 Apr 22 00:46 UPNP -> /mnt/UPNP
lrwxrwxrwx 1 pi pi 8 Jul 30 2013 USB -> /mnt/USB
drwxrwxrwx 2 pi pi 4096 Sep 7 2013 WEBRADIO

pi@volumio:~$ ls -l /var/lib/mpd/music/NAS/
total 4
drwxr-xr-x 2 root root 4096 Apr 7 00:44 Flac
drwxr-xr-x 2 root root 0 Sep 23 20:09 Xeon
[/code]

where Xeon is the name I gave to the share using the webgui.
I checked and all the files inside the NAS folder appear as root/root with rwxr-xr-x.
My mount is:
//192.168.x.y/music on /mnt/NAS/Xeon type cifs (ro,noatime,vers=1.0,sec=ntlmv2,cache=strict,username=USERNAME_FOR_VOLUMIO,domain=WORKGROUP, uid=0,noforceuid,gid=0,noforcegid,addr=192.168.x.y,file_mode=0755,dir_mode=0755, nounix,serverino,rsize=8048,wsize=8096,actimeo=1)

In the server itself, typical permissions set are:

ls -lV /tank/media/Music/ -rwxrwx---+ 1 myuser music 5419 Oct 21 2005 lyric.txt user:myuser:rwxpdDaARWcCos:fd-----:allow owner@:rwxpdDaARWcCos:fd-----:allow group@:rwxp--a-R-c--s:fd-----:allow group:musicr:r-x---a-R-c--s:fd-----:allow everyone@:rwxpdDaARWcCos:fd-----:deny

The username USERNAME_FOR_VOLUMIO belongs to the group “musicr” (music read-only) in the server. You can see that client-side permissions are complete, but actually server-side the USERNAME_FOR_VOLUMIO is restricted to read-only permission (group:musicr), therefore I don’t need to bother with Volumio too much and the setup is easier.

The server uses illumos kernel CIFS.

Hi,

I have the same issue with my NAS (MyDitto), it works correctly with the version 1.4 and 1.41 but the library page on the UI stay empty (but the files are present on the mnt/NAS folder).