Install qBittorrent via Dietpi-Software
Qbittorrent log files should be in dietpi-ramlog to save write cycles on SD or eMMC
qBittorrent logs are stored in~/.local/share/data/qBittorrent/
Tried moving the logs to /var/log by adding the following in /home/qbittorrent/.config/qBittorrent/qBittorrent.conf:
[Application]
FileLogger\Enabled=true
FileLogger\Age=6
FileLogger\DeleteOld=true
FileLogger\Backup=true
FileLogger\AgeType=1
FileLogger\Path=/var/log
FileLogger\MaxSize=10
based on this post but no change after a service qbittorrent restart
question is if this needs to be solved by qBittorrent or if , as a workaround we could include ~/.local/share/data/qBittorrent/ in the ramlog?
@GvY85
Many thanks for your report.
Indeed it would be great to have those logs in RAM. If there is a way to disable file logging completely and instead use system log (systemd-journald/journalctl), this would be even better IMO. I'll have a closer look for v6.30.
No chance to log to stdout or syslog currently: https://github.com/qbittorrent/qBittorrent/issues/10077
/var/log RAMlog is best option for now. We'll leave internal rotation option active. If DietPi-RAMlog is disabled, this is reasonable, however it requires to log to a subdir with proper permissions.
I pushed for a similar change with samba last year (documented at https://github.com/MichaIng/DietPi/issues/2396)
@GvY85 just for the sake of convenience on this discussion, check the "writing to SD" monitoring commands I used. Tweaking here and there you can mostly avoid any writing to SD/eMMC.
As @MichaIng said, permissions on /var/log are usually the issue with some apps running on normal users ids, just create a subfolder with proper permissions via sudo inside, redirect your log file in the apps setting and everything should work.
Done: https://github.com/MichaIng/DietPi/commit/30e6371756ac43f13b334d230325096be8853d77
Effective for new installs only.
@WolfganP
Do you know about an overview/documentation of all settings? I only found one for the GUI, but not for the config file 馃.
@MichaIng I don't know of any doc for the .conf file, but I always use https://github.com/qbittorrent/qBittorrent/blob/master/src/base/preferences.h as reference when trying to check something in my headless setup as an starting point, and then... the search box :-)
Jep, I used the application source for this [Application] settings. Works somehow but a bid tedious to check and track where/how the values are used in the end, and I wanted to find out about FileLogger\MaxSize and FileLogger\MaxSizeBytes, the first seems to be deprecated/removed and replaced be the second. Since we need to support Stretch until Buster, we either need to know if the first still works, is e.g. translated somewhere else or otherwise alter this setting based on qbittorrent version. However I didn't add it for now to let the default take place. Having some table with old and new settings, with which version they were added, deprecated or removed etc would be nice, also to e.g. bring our default config in shape. Currently this would be a huge effort to check all of them via source files and derive for every single changed one when it was changed, to know in which case to alter etc etc...
What if you include both in the config file? I don't think they will collide/interact in the app settings, and that way you'll support both versions easily (add a note on Cleanup needed in the future and that will be it)
You're right, invalid settings are simply ignored. But not needed to put those logging options inside, since it anyway has no effect with RAMdisk and hourly clean (files will not become that large). If someone has RAMdisk disabled, the defaults are probably fine anyway.
Best would be to reduce the default config to a minimum and give a link to a config overview, if it exists. But anyway you can as well configure most things via web UI.