I’ve also posted this question over at the QNAP forum found on page 2 of the first link above
Thought you guys could help me out aswell.
I can run and update Sonarr fine on my QNAP, that is until I add any series. Generally I’ve found when I try to add all my existing series’ what I presume is some sort of temp file fills up and Sonarr starts misbehaving. When this happens I get errors trying to add, edit or delete any series and in my QNAP web client page I get all sorts of errors about not being able to write logs and such. The system basically falls over and a restart of the NAS is required to set things straight. When I restart Sonarr is completely empty as if It has been installed fresh with all series and settings wiped out.
The error messages I get in my QNAP web page are attached.
I realize this is not the QNAP forum but maybe some of you are running Sonarr on a QNAP and can help.
Thanks in advance
Not sure how you would check, I don’t have a QNAP.
I am wondering where the AppData directory actually lives, it shouldn’t live on a ram disk and should be on permanent storage, but maybe its not. Thats really the only reason I can think of that would cause Sonarr to fill it up.
This is because the AppData folder is located under /share/homes/admin/.config/NzbDrone dir. /share/homes/ dir does not exist until mono and/or sonarr creates them. This is not the right location on a QNAP device.
The proper location depending on the device configuration is /share/MD0_DATA (which is where the HDD’s are mounted). /share/MD0_DATA/homes/admin is where the real admin home dir is located.
In the case of qpkg packages it should probably go under /share/MD0_DATA/.qpkg/Sonarr/config/ (which is an empty folder). I think this was the idea. But the qpkg was not setup properly I think.
I honestly don’t know yet where to change the location of the AppData dir.
It uses the home directory, or at least something based off of it.
The exact path Sonarr looks for in the non-Windows world is: Environment.SpecialFolder.ApplicationData which on most systems is ~/.config (where ~ is the home directory). At the moment you can’t change the path directly with Sonarr, but you could symlink the folder the the location where you want it stored or alter the home directory path.
Is it possible that the mono QPKG package configured the home directory wrong?
The reason I ask is that /share/homes gets wiped after each reboot. But /share/MD0_DATA/homes/ doesn’t. Which tells me that the home directory that Sonarr receives is not the real home directory.
I’m not altering the package. I’m just altering the init script.
QNAP’s are kind of weird when it comes to system users. By default all QPKG’s run under the admin user account.
But the QPKG’s AppData and configs are located under /share/MD0_DATA/.qpkg/. Nothing is suppose to be installed in the home directory of the user. There seems to be an issue with the mono or Sonarr QPKG’s that does this incorrectly IMO. But I contacted the mono QPKG creator. Waiting on a reply.
But I will try to use the argument, will let you know how that works out.
Thanks
UPDATE:
The argument seems to be working as expected!
Thanks for you help
It appears that the QNAP had an issue with a missing symlink /share/homes to /share/MD0_DATA/homes.
And the whole confusion with /root was another bug where the SSH daemon is using the wrong home dir. So only when SSHing would give false home dir /root