Thank you for your donation!


Cloudsmith graciously provides open-source package management and distribution for our project.


Solved: OMV NAS Samba MPD scan restarting
#1
hi all,
i have a MPD "crash" when trying to scan the Music folder on my OMV Nas.

MoodeAudio 6.4.2
Raspberry P3B+
hifiberry AMP2

folder is recognised and correctly mount, i can browse using SSH and also creating folders/files on it, permissions are OK but NAS doesn't appear on WEB UI folder list.

i checked various logs and i found that:

cat /var/log/moode.log
watchdog: MPD restarted (check syslog for errors)

Code:
20200330 140326 worker: -- Start                                                                                                                                                                                                                              
20200330 140326 worker: Successfully daemonized                                                                                                                                                                                                              
20200330 140326 worker: Integrity check (passed)                                                                                                                                                                                                              
20200330 140326 worker: Session loaded                                                                                                                                                                                                                        
20200330 140326 worker: Debug logging (off)                                                                                                                                                                                                                  
20200330 140326 worker: Device raw: (0:sndrpihifiberry|1:empty|i2s:HiFiBerry Amp2)                                                                                                                                                                            
20200330 140326 worker: Device cfg: (HiFiBerry Amp2|0|0|Digital|0)                                                                                                                                                                                            
20200330 140327 worker: ALSA volume set to (0%)                                                                                                                                                                                                              
20200330 140327 worker: -- System                                                                                                                                                                                                                            
20200330 140330 worker: Host name     (moode)                                                                                                                                                                                                                
20200330 140330 worker: moOde release (6.4.2 2020-02-12)                                                                                                                                                                                                      
20200330 140330 worker: Raspbian OS   (10.2)                                                                                                                                                                                                                  
20200330 140330 worker: Linux kernel  (4.19.97-v8+ #1293)                                                                                                                                                                                                    
20200330 140330 worker: Platform      (Pi-3B+ 1GB v1.3)                                                                                                                                                                                                      
20200330 140330 worker: Architecture  (aarch64)                                                                                                                                                                                                              
20200330 140330 worker: MPD version   (0.21.16)                                                                                                                                                                                                              
20200330 140330 worker: CPU governor  (ondemand)                                                                                                                                                                                                              
20200330 140330 worker: USB boot enabled                                                                                                                                                                                                                      
20200330 140330 worker: File system not expanded yet                                                                                                                                                                                                          
20200330 140330 worker: HDMI port off                                                                                                                                                                                                                        
20200330 140331 worker: File check (OK)                                                                                                                                                                                                                      
20200330 140331 worker: -- Network                                                                                                                                                                                                                            
20200330 140331 worker: eth0 exists                                                                                                                                                                                                                          
20200330 140331 worker: IP addr (192.168.0.30)                                                                                                                                                                                                                
20200330 140331 worker: Netmask (255.255.255.0)                                                                                                                                                                                                              
20200330 140331 worker: Gateway (192.168.0.1)                                                                                                                                                                                                                
20200330 140332 worker: Pri DNS (192.168.0.1)                                                                                                                                                                                                                
20200330 140332 worker: Domain  (None)                                                                                                                                                                                                                        
20200330 140332 worker: wlan0 does not exist                                                                                                                                                                                                                  
20200330 140332 worker: -- Audio                                                                                                                                                                                                                              
20200330 140332 worker: ALSA outputs unmuted                                                                                                                                                                                                                  
20200330 140332 worker: ALSA card number (0)                                                                                                                                                                                                                  
20200330 140332 worker: Audio output (I2S audio device)                                                                                                                                                                                                      
20200330 140332 worker: Audio device (HiFiBerry Amp2)                                                                                                                                                                                                        
20200330 140332 worker: Audio formats (S16_LE, S24_LE, S32_LE)                                                                                                                                                                                                
20200330 140332 worker: ALSA mixer name (Digital)                                                                                                                                                                                                            
20200330 140332 worker: MPD volume control (software)                                                                                                                                                                                                        
20200330 140332 worker: Hdwr volume controller exists                                                                                                                                                                                                        
20200330 140332 worker: Max ALSA volume (100%)                                                                                                                                                                                                                
20200330 140332 worker: -- Services                                                                                                                                                                                                                          
20200330 140332 worker: Reset renderer active state                                                                                                                                                                                                          
20200330 140333 worker: MPD conf updated                                                                                                                                                                                                                      
20200330 140333 worker: MPD started                                                                                                                                                                                                                          
20200330 140333 worker: MPD accepting connections                                                                                                                                                                                                            
20200330 140333 worker: Configure MPD outputs                                                                                                                                                                                                                
20200330 140334 worker: MPD output 1 ALSA default (on)                                                                                                                                                                                                        
20200330 140334 worker: MPD output 2 ALSA crossfeed (off)                                                                                                                                                                                                    
20200330 140334 worker: MPD output 3 ALSA parametric eq (off)                                                                                                                                                                                                
20200330 140334 worker: MPD output 4 ALSA graphic eq (off)                                                                                                                                                                                                    
20200330 140334 worker: MPD output 5 ALSA polarity inversion (off)                                                                                                                                                                                            
20200330 140334 worker: MPD output 6 ALSA bluetooth (off)                                                                                                                                                                                                    
20200330 140334 worker: MPD output 7 HTTP stream (off)                                                                                                                                                                                                        
20200330 140334 worker: MPD crossfade (off)                                                                                                                                                                                                                  
20200330 140334 worker: Audio source (Local)                                                                                                                                                                                                                  
20200330 140334 worker: Output device (Local)                                                                                                                                                                                                                
20200330 140334 worker: Bluetooth controller started                                                                                                                                                                                                          
20200330 140334 worker: Bluetooth controller initialized                                                                                                                                                                                                      
20200330 140334 worker: Bluetooth pairing agent started                                                                                                                                                                                                      
20200330 140335 worker: LCD updater engine started                                                                                                                                                                                                            
20200330 140335 worker: Shellinabox SSH started                                                                                                                                                                                                              
20200330 140335 worker: USB auto-mounter (udisks-glue)                                                                                                                                                                                                        
20200330 140335 worker: -- Music sources                                                                                                                                                                                                                      
20200330 140335 worker: USB sources (none attached)                                                                                                                                                                                                          
20200330 140336 worker: NAS and UPnP sources (mountall initiated)                                                                                                                                                                                            
20200330 140336 worker: -- Miscellaneous                                                                                                                                                                                                                      
20200330 140336 worker: Saved MPD vol level (0)                                                                                                                                                                                                              
20200330 140336 worker: Preamp volume level (0)                                                                                                                                                                                                              
20200330 140336 worker: MPD volume level (20) restored                                                                                                                                                                                                        
20200330 140336 worker: ALSA volume level (100%)                                                                                                                                                                                                              
20200330 140336 worker: Auto-play (On)                                                                                                                                                                                                                        
20200330 140336 worker: ALSA output (closed)                                                                                                                                                                                                                  
20200330 140336 worker: Auto-playing id (1)                                                                                                                                                                                                                  
20200330 140336 worker: ALSA output (closed)                                                                                                                                                                                                                  
20200330 140336 worker: LocalUI started                                                                                                                                                                                                                      
20200330 140336 worker: Auto-shuffle service (Off)                                                                                                                                                                                                            
20200330 140336 worker: Maintenance interval (3 hrs)                                                                                                                                                                                                          
20200330 140336 worker: Screen saver activation (Never)                                                                                                                                                                                                      
20200330 140336 worker: Session permissions (OK)                                                                                                                                                                                                              
20200330 140336 worker: Watchdog started                                                                                                                                                                                                                      
20200330 140336 worker: Ready                                                                                                                                                                                                                                
20200330 141314 worker: Job rescanmpddb                                                                                                                                                                                                                      
20200330 141349 watchdog: MPD restarted (check syslog for errors)                                                                                                                                                                                            
20200330 141929 worker: Job updmpddb                                                                                                                                                                                                                          
20200330 141948 engine-mpd: Connection to MPD failed                                                                                                                                                                                                          
20200330 141948 moode.php: MPD connect failed: cmd=(playlist)                                                                                                                                                                                                
20200330 141948 engine-mpd: Connection to MPD failed                                                                                                                                                                                                          
20200330 141950 watchdog: MPD restarted (check syslog for errors)                                                                                                                                                                                            
20200330 142508 worker: Job rescanmpddb                                                                                                                                                                                                                      
20200330 142526 watchdog: MPD restarted (check syslog for errors)                                                                                                                                                                                            
20200330 142526 engine-mpd: Connection to MPD failed              

nano syslog:

Code:
Mar 30 14:13:49 moode systemd[1]: mpd.service: Main process exited, code=killed, status=7/BUS                                                                                                                                                                
Mar 30 14:13:49 moode systemd[1]: mpd.service: Failed with result 'signal'.

What's going wrong with it?
I don't think i have so many files to kill the scan.

cat /var/log/mpd/log

gives the scanned files and closes without scanning all the files (ending always at the same file) and giving no errors.
cat /var/log/moode.log

cat /var/log/moode.log
cat /var/log/moode.log
Reply
#2
If it always ends at the same file, try moving that file somewhere else out of the way and trying again. If the scan completes, then it is the file that is corrupt. Re-acquire the problem file (re-rip, download, whatever) and add it back.
----------------
Robert
Reply
#3
no luck.
it just stops the folder before the preious error.

never had this kind of issue with other players on my Pi.
Reply
#4
@Ironfly

You said

Quote:cat /var/log/mpd/log

gives the scanned files and closes without scanning all the files (ending always at the same file) and giving no errors.

MPD stops scanning when it hits a file with corrupt metadata. At the default logging level (which is the setting in moOde), MPD won't say anything. I don't recall whether you'll see anything useful about metadata at the verbose logging level.

Rather than repeat its contents here, I refer you to the ArchLinux Wiki in the subsection "MPD hangs on first startup." 

As an aside, the MPD process has to have read permission on all music files, and read+execute permission on all music directories (and all of their parent directories)?  It sounds like this may not be part of your issue, but it's worth remembering, especially because the MPD process is running as user 'mpd' and not as user 'pi'.

I've been using an OpenMediaVault NAS for some years now and it has performed flawlessly in daily use with multiple moOde players. The NAS services I've enabled include SMB shares containing ca 6 000 tracks in various encodings and NFS mounts used at various times for testing.

Regards,
Kent
Reply
#5
Thanks Kent, i will give a look at Archlinux Wiki!
Reply
#6
Fixed some tags but...nothing, still the same issue.


with mpd log to verbose, this is after the same long list of songs loaded but not all, the same error is repeated with only the port number that changes by 4 ports each error
Code:
Mar 31 18:07 : state_file: Loading state file /var/lib/mpd/state                                                                                                                                                                                              
Mar 31 18:07 : client: [0] opened from 127.0.0.1:35870                                                                                                                                                                                                        
Mar 31 18:07 : client: [0] process command "status"                                                                                                                                                                                                          
Mar 31 18:07 : client: [0] command returned 0                                                                                                                                                                                                                
Mar 31 18:07 : client: [0] process command "close"                                                                                                                                                                                                            
Mar 31 18:07 : client: [0] command returned 3                                                                                                                                                                                                                
Mar 31 18:07 : client: [0] closed
Reply
#7
It's prolly a bug in MPD or one of the libraries it uses for example ffmpeg.

You should try what @the_bertrum recommended in the earlier post http://moodeaudio.org/forum/showthread.p...0#pid18080

If you are able to identify the files that are causing MPD to crash during its scan then post some information about them.
Enjoy the Music!
moodeaudio.org | Mastodon Feed | GitHub
Reply
#8
Thanks Tim!
I will search the culprit for sure, i will never surrender!
Reply
#9
Yeah, just keep in mind that moving a problematic file out of the way means moving it completely out of any directories/subdirectories being scanned by MPD. One could use the .mpdignore file to "blind" MPD to certain files. See the MPD documentation.

I prefer looking directly at the file and at the directory in which the file lies.  We've seen people run into trouble in various ways, even with hidden (e.g. named with a leading dot) files and/or directories.


What do the file command and the mediainfo command say about the file(s), for example?

Regards,
Kent
Reply
#10
i think i found the issue.
MPD doesn't like multichannel wave files (*.wav - DTS)
but instead of skipping it, giving a warning (as SACD ISO, i know there's a fork for MPD but i don't want to use it), it stops and kill itselfs.

is it possible to fix this (skip the file without "crashing"), since i don't want to mess around with my music collection?

   
Reply


Forum Jump: