Help on dietpi configuration settings

Subbiya

Active Member
Joined
May 2, 2014
Messages
156
Points
28
Location
Chennai, India.
Hi,

Can anyone tell me, why this error occurs when I try to access files from external usb or network server. I'm using dietpi and using ompd media player.
 

Attachments

  • IMG_20240304_232529.jpg
    IMG_20240304_232529.jpg
    43.2 KB · Views: 11
Hi,

Can anyone tell me, why this error occurs when I try to access files from external usb or network server. I'm using dietpi and using ompd media player.
The error is happening because it doesn't find the directory /mnt/samba or it cannot access the directory /mnt/samba due to permission issue.

Most likely you have configured /mnt/samba somewhere in the config for mounting external drives. But the drive is not mounted.

Login to your raspberry PI or whatever linux box you have installed dietpi. Then in terminal run two commands

1) /bin/ls -l /mnt/samba
What does the above command show?

2) df -k
What is the output of the above commands

The fact that you have printed a screenshot instead of cut pasting the error implies that most likely you are a windows user and not familiar with linux. But it is nothing to be scared of. If this is true, then install putty on your PC or laptop and access your raspberry pi using putty. After that you will be able to run the above commands and quickly able to troubleshoot and fix the issue. Using putty you can quickly cut paste lines on your terminal and paste it in the hifivision post without the long process involved in taking a screenshot, saving the image and then uploading it. ompd is a web based frontend to mpd. The real player on dietpi, volumio, moode, etc is mpd. There are plenty of clients which interface with mpd (apart from ompd). These clients are available for almost all platforms. Instead of ompd you can install cantata music player on your laptop and access all your music on the raspberry pi's mpd.

Feel free to post your issues here. You can also ask @Kannan from your city. I saw him become an expert in putty in just few minutes. He also installed cantata on his laptop and is able to access his music using cantata.
 
Last edited:
Hi, Please see the output below

root@DietPi:~# /bin/ls -l /mnt/samba

total 254677
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 '12 B (Saregama) [2003-ACDRip-FLAC]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 '20BiggestHitsHarrisJayarajVol.1(SonyMusic'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 '20BiggestHitsHarrisJayarajVol.2(SonyMusic)[2017-DIGITALRip-FLAC'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 '24 (Tamil) (Eros Music) [2016-ACDRip-FLAC]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 3_Moonu_SonyMusic
drwxrwx--- 0 dietpi dietpi 0 Sep 16 20:53 '7G Rainbow Colony (Five Star) [1st Edition] [2004-ACDRip] [Desihires.com]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'Virumbugiren (UA) [2002-ACDRip-FLAC]'
drwxrwx--- 0 dietpi dietpi 0 Mar 16 2018 'Vivegam [24-Bit HD] (Sony Music) [2017-DIGITALRip-WAV]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'Walter Vetrivel (1993) (Raaja Diigital) (ACD-1986-Flac)'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 Whistle_Kosmic
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'Whistle_Kosmic (1)'
drwxrwx--- 0 dietpi dietpi 0 Apr 3 2018 WillSheComeOver_Pyramid
drwxrwx--- 0 dietpi dietpi 0 Mar 16 2018 'Yaaradi Nee Mohini [24-Bit HD] (Sony Music) [2008-DIGITALRip-WAV]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 Yaaradi_Nee_Mohini_ThinkMusic
drwxrwx--- 0 dietpi dietpi 0 Sep 16 20:52 'Yai Nee Romba Azhaga Irukey (Tamil) [HIT Musics] [2002-ACDRip] [Desihires.com]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'Youth (HIT Music) [2003-ACDRip-FLAC]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'Yuddham Sei (Sony Music) [2011-DIGITALRip-FLAC]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 '[WAV]Siva'
-rwxrwx--- 0 dietpi dietpi 121 Nov 28 2019 download.txt
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'vaaranam aayiram'
root@DietPi:~#

root@DietPi:~# df -k
Filesystem 1K-blocks Used Available Use% Mounted on
udev 10240 0 10240 0% /dev
/dev/mmcblk0p2 61385340 2457708 56416400 5% /
tmpfs 506596 0 506596 0% /dev/shm
tmpfs 202640 3312 199328 2% /run
tmpfs 5120 4 5116 1% /run/lock
tmpfs 4096 0 4096 0% /sys/fs/cgroup
tmpfs 1048576 0 1048576 0% /tmp
tmpfs 51200 28 51172 1% /var/log
/dev/mmcblk0p1 49026 7978 41048 17% /boot
/dev/sda1 7815660 71736 7743924 1% /mnt/CC0CFE730CFE57C2
//192.168.1.6/HiRes 823158780 594110412 229048368 73% /mnt/samba
root@DietPi:~#

Pls see the error below
1709579359820.png
 
Last edited:
Hi, Please see the output below

root@DietPi:~# /bin/ls -l /mnt/samba

total 254677
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 '12 B (Saregama) [2003-ACDRip-FLAC]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 '20BiggestHitsHarrisJayarajVol.1(SonyMusic'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 '20BiggestHitsHarrisJayarajVol.2(SonyMusic)[2017-DIGITALRip-FLAC'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 '24 (Tamil) (Eros Music) [2016-ACDRip-FLAC]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 3_Moonu_SonyMusic
drwxrwx--- 0 dietpi dietpi 0 Sep 16 20:53 '7G Rainbow Colony (Five Star) [1st Edition] [2004-ACDRip] [Desihires.com]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'Virumbugiren (UA) [2002-ACDRip-FLAC]'
drwxrwx--- 0 dietpi dietpi 0 Mar 16 2018 'Vivegam [24-Bit HD] (Sony Music) [2017-DIGITALRip-WAV]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'Walter Vetrivel (1993) (Raaja Diigital) (ACD-1986-Flac)'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 Whistle_Kosmic
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'Whistle_Kosmic (1)'
drwxrwx--- 0 dietpi dietpi 0 Apr 3 2018 WillSheComeOver_Pyramid
drwxrwx--- 0 dietpi dietpi 0 Mar 16 2018 'Yaaradi Nee Mohini [24-Bit HD] (Sony Music) [2008-DIGITALRip-WAV]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 Yaaradi_Nee_Mohini_ThinkMusic
drwxrwx--- 0 dietpi dietpi 0 Sep 16 20:52 'Yai Nee Romba Azhaga Irukey (Tamil) [HIT Musics] [2002-ACDRip] [Desihires.com]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'Youth (HIT Music) [2003-ACDRip-FLAC]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'Yuddham Sei (Sony Music) [2011-DIGITALRip-FLAC]'
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 '[WAV]Siva'
-rwxrwx--- 0 dietpi dietpi 121 Nov 28 2019 download.txt
drwxrwx--- 0 dietpi dietpi 0 Mar 15 2018 'vaaranam aayiram'
root@DietPi:~#

root@DietPi:~# df -k
Filesystem 1K-blocks Used Available Use% Mounted on
udev 10240 0 10240 0% /dev
/dev/mmcblk0p2 61385340 2457708 56416400 5% /
tmpfs 506596 0 506596 0% /dev/shm
tmpfs 202640 3312 199328 2% /run
tmpfs 5120 4 5116 1% /run/lock
tmpfs 4096 0 4096 0% /sys/fs/cgroup
tmpfs 1048576 0 1048576 0% /tmp
tmpfs 51200 28 51172 1% /var/log
/dev/mmcblk0p1 49026 7978 41048 17% /boot
/dev/sda1 7815660 71736 7743924 1% /mnt/CC0CFE730CFE57C2
//192.168.1.6/HiRes 823158780 594110412 229048368 73% /mnt/samba
root@DietPi:~#

Pls see the error below
View attachment 83265
There is no issue with mounting of the disk. The shared drive 192.168.1.6/HiRes is mounted as /mnt/samba as seen in the df -k command

You can do one thing. I had dietpi ages ago when I had purchased allo piano dac. IIRC removing ompd in the software selection and then again adding it back fixed such configuration issues. Also the php script has been badly written. Linux always returns the exact error when opening a file. Such errors are usually ENOENT - No such file or directory, EACCES - Permission denied, etc. Instead the script is returning a generic error and not using the system variable errno or sys_errlist. You can find where this file include/config.local.inc.php is by running the command

find / -name config.local.inc.php -print

The above command will print the full path of the file. let us say it is full_path_of_file. Then you can run the ls command to see the file permission

ls -l full_path_of_file

It should show that it is owned by user dietpi. If it isn't then you can change the owner to dietpi by running the command

chown dietpi full_path_of_file.

But the thing that you are getting this error indicates a bug in the dietpi scripts and may cause you trouble now and then.

Another way is to directly edit /etc/mpd.conf or /usr/local/etc/mpd.conf (I believe dietpi uses the later). In that file you will see the setting
music_directory. See what value it has. You can update the mpd database (this is what ompd will do) by running the command

mpc update

Let me know how it goes. The best is to do away with all these 3rd party distributions and use the official Raspberry PI OS directly and install mpd by running the command apt-get install mpd. But that can be done later if you are not able to fix the dietpi issues.
 
Last edited:
There is no issue with mounting of the disk. The shared drive 192.168.1.6/HiRes is mounted as /mnt/samba as seen in the df -k command

You can do one thing. I had dietpi ages ago when I had purchased allo piano dac. IIRC removing ompd in the software selection and then again adding it back fixed such configuration issues. Also the php script has been badly written. Linux always returns the exact error when opening a file. Such errors are usually ENOENT - No such file or directory, EACCES - Permission denied, etc. Instead the script is returning a generic error and not using the system variable errno or sys_errlist. You can find where this file include/config.local.inc.php is by running the command

find / -name config.local.inc.php -print

The above command will print the full path of the file. let us say it is full_path_of_file. Then you can run the ls command to see the file permission

ls -l full_path_of_file

It should show that it is owned by user dietpi. If it isn't then you can change the owner to dietpi by running the command

chown dietpi full_path_of_file.

But the thing that you are getting this error indicates a bug in the dietpi scripts and may cause you trouble now and then.

Another way is to directly edit /etc/mpd.conf or /usr/local/etc/mpd.conf (I believe dietpi uses the later). In that file you will see the setting
music_directory. See what value it has. You can update the mpd database (this is what ompd will do) by running the command

mpc update

Let me know how it goes. The best is to do away with all these 3rd party distributions and use the official Raspberry PI OS directly and install mpd by running the command apt-get install mpd. But that can be done later if you are not able to fix the dietpi issues.
the file config.local.inc.php is owned by root user

root@DietPi:~# find / -name config.local.inc.php -print
/var/www/ompd/include/config.local.inc.php
root@DietPi:~# ls -l /var/www/ompd/include/config.local.inc.php
-rw-r--r-- 1 root root 443 Mar 4 09:49 /var/www/ompd/include/config.local.inc.php
root@DietPi:~#
 
the file config.local.inc.php is owned by root user

root@DietPi:~# find / -name config.local.inc.php -print
/var/www/ompd/include/config.local.inc.php
root@DietPi:~# ls -l /var/www/ompd/include/config.local.inc.php
-rw-r--r-- 1 root root 443 Mar 4 09:49 /var/www/ompd/include/config.local.inc.php
root@DietPi:~#
Then it is EPERM - permission denied error. I suspect all files in /var/www/ompd/include will be owned by root.

You can change permissions for just config.local.inc.php by doing

chown dietpi:dietpi /var/www/ompd/include/config.local.inc.php

If that works, good. Else you can change permissions of all files by doing

chown -R dietpi:dietpi /var/www/ompd/include
worst case you might have to do
chown -R dietpi:dietpi /var/www/ompd
 
@mbhangui
I might need your help in building Allo Boss (original release) + Pi2 based media player.
I also tried sparky + Allo Boss , but they are physically incompatible, as the super cap underneath Allo Boss comes in the way of sparky's heatsink.
OS Diet Pi
Thanks in advance
 
@mbhangui
I might need your help in building Allo Boss (original release) + Pi2 based media player.
I also tried sparky + Allo Boss , but they are physically incompatible, as the super cap underneath Allo Boss comes in the way of sparky's heatsink.
OS Diet Pi
Thanks in advance
sure. Let me know when we can do it. We can do it over skype as this requires a bit of hand holding and talking to give instructions is faster than back and forth exchanging messages.
 
Order your Rega Turntables & Amplifiers from HiFiMART.com - India's reputed online dealer.
Back
Top