Replies: 1 comment 1 reply
-
It's certainly not nice if this happens. navidrome/scanner/tag_scanner.go Line 87 in a7a4fb5 Can you please check if there were indeed 0 files and 0 subfolders in your MusicFolder when this happened to you? That said: |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello everyone,
I recently ran into an issue where my database was lost following a power failure. The reason for this was not data corruption but rather that upon restarting of my servers the network share on which my music is stored failed to mount. When navidrome started up and ran its first media scan it detected that the music was "removed" and tossed all tracks from its database causing me to lose my song ratings, favorites and playlists.
I am aware that this is something that can and probably should be prevented on the layer of the OS itself but it would be nice to have another failsafe in the application for scenarios like this. For now I added the successful mounting of the network share to the requirements for the docker service to start up.
What I would propose as a failsafe in navidrome itself is that when the application detects a number of songs above a configurable threshold have been removed from the filesystem, a backup of the database is created first before removing those songs.
Edit:
For those interested in making docker require a successful network mount, this is what I did. Note the comment to the accepted reply which contains a command to list the required mount point name. I added this name to the systemd service file for docker.
Beta Was this translation helpful? Give feedback.
All reactions