broodwich82 Posted December 11, 2018 Posted December 11, 2018 Hello, I've searched through various threads on here and can find no comprehensive answer on how to disable log2ram completely, forever, and preferably end up with only one /var/log with mainstream logrotate settings. This is for a situation where I'm using an actual hard drive and don't need to worry about destroying flash memory. I suspect it is more involved than just 'systemctl disable log2ram'. Any additional pointers would be very helpful, thank you!
sfx2000 Posted December 12, 2018 Posted December 12, 2018 If you must... armbian-ramlog is a good place to start looking, along with armbian-zramconfig
sfx2000 Posted December 13, 2018 Posted December 13, 2018 The ones to look for... again, it's there for a good reason, just like armbian-zram-config.service (which some might be aware of as docker and k8 can have issues with swap in general) $ systemctl list-unit-files | grep armbian* armbian-firstrun-config.service enabled armbian-firstrun.service disabled armbian-hardware-monitor.service enabled armbian-hardware-optimize.service enabled armbian-ramlog.service disabled armbian-resize-filesystem.service disabled armbian-zram-config.service disabled to disable the ramlog service - systemctl disable armbian-ramlog.service as sudo
broodwich82 Posted December 23, 2018 Author Posted December 23, 2018 (edited) Thanks for the responses, folks. Why would it be a problem to disable ramlog on a system that has / on a spinning disk? I want the 50MB of RAM back. Edit: also, I'm using this as a development box for something that generates a lot of logs, 50MB was not enough for more than a week before it was filling up, etc ... so I just want logging to work how it does on a vanilla linux box, seeing as I've got a real disk, unless there's a good reason. Edited December 23, 2018 by broodwich82 forgot a thing
broodwich82 Posted February 6, 2019 Author Posted February 6, 2019 Didn't get to this and found /var/log full again... still wondering if there is a reason I shouldn't disable log2ram when using a spinning disk?
broodwich82 Posted February 7, 2019 Author Posted February 7, 2019 FYI neither of the above answers was correct because ram logging is provided by log2ram on the Cubieboard2 image I am using. I found the answer as to how to disable it elsewhere: http://www.orangepi.org/orangepibbsen/forum.php?mod=viewthread&tid=3448 Quote # systemctl stop rsyslog.service # systemctl stop syslog.socket # lsof /var/log (make sure it's empty) # systemctl stop log2ram # systemctl disable log2ram # mv /var/log /var/oldlog # rsync -avPHAXx /var/oldlog /var/log # reboot After the reboot, remove /var/oldlog if you don't really need it
Recommended Posts