You are not logged in.

#1 2022-03-04 20:13:14

Registered: 2021-07-16
Posts: 25

delete or disable log files

Hi Guys

I have a living room pc connected to Tv autologin enabled on it no server functions just kids watching disney++ with Kodi and youtube with
gtk-pipe-viewer and gaming with Snes9x and Scummvm.
Every 2 month the autologin stuck in a loop i have to login on a terminal to delete the /var/log files to fix it. I am looking for a better automated way to deal with it. Is there a way to switch off the log file creation or set up a size limit to not go over it? Maybe empty the log files from crontab at every login?
What you guys think which is the best way?


#2 2022-03-04 20:36:00

From: Sweden/Vasterbotten/Rusfors
Registered: 2016-08-11
Posts: 1,513

Re: delete or disable log files

Do you have a ill configured logrotate installed? I have never touched default settings...

Is /var on same partition as /? Not much space on the root partition?
For 2 months ago, on my server, I had to symlink /var to /data (/var/spool, had grown to big).

// Regards rbh

Please read before requesting help: Guide to getting help,
Introduction to the Bunsenlabs Lithium Desktop and other help topics under "Help Resources" on the BunsenLabs menu


#3 2022-03-04 20:50:00

Registered: 2021-07-16
Posts: 25

Re: delete or disable log files

yes /var is on the system partition and yes only 1 Gb space left on the partition, its a multiboot machine. I did not tried logrotate yet. I will install it, i am open to any ideas.


#4 2022-03-05 09:58:14

Back to the roots 1.9
From: #! BL
Registered: 2015-10-31
Posts: 1,762

Re: delete or disable log files

^I have this "problem" here in siduction with the file ~/.xsession-errors
In some installations it also fills up without any sense. That's why I apply these two solutions depending on my taste:

with an autostart-script

if [ ! -h /home/user/.xsession-errors ]; then
	rm /home/user/.xsession-errors
	ln -s /dev/null /home/user/.xsession-errors

or with logrotate, if you don't want to be so rough after all   smile
/etc/logrotate.d/xsession (Example adapt to your circumstances at path $HOME)

$HOME/.xsession-errors {
  rotate 2


#5 2022-03-05 14:42:01

Registered: 2018-05-22
Posts: 873

Re: delete or disable log files

^ When Lilidog was still based from lxde, the xsession-errors file displayed only the opening dbus lines, and then ignored any other messages. I wish I could reproduce that.

At the time, I didn't know enough to try to figure it, but probably/maybe? can now.

I'll try a task-lxde-desktop task build without any extras and see if I can figure out what they are doing.  Hopefully just a modified /etc/X11/Xsession or a crond boot entry.

* EDIT - No such luck;) Looks like the system may redirect to ~/.cache.

Last edited by sleekmason (2022-03-05 18:01:58)


Board footer

Powered by FluxBB