[12.04] [ Precise] .xsession-errors getting spammed filling up the disk.
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
lightdm (Ubuntu) |
Triaged
|
Medium
|
Unassigned |
Bug Description
The problem really is that .xsession-errors file in the /home/<user> directory is allowed to grow to an unlimited size. On my system this file got filled with error messages from indicator-weather and filled up my entire disk.
manjo@lazy:~$ df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda2 44G 42G 353M 100% /
udev 7.8G 4.0K 7.8G 1% /dev
tmpfs 3.2G 1016K 3.2G 1% /run
none 5.0M 0 5.0M 0% /run/lock
none 7.8G 604K 7.8G 1% /run/shm
/dev/sda1 95M 118K 95M 1% /boot/efi
overflow 1.0M 92K 932K 9% /tmp
manjo@lazy:~$
Of which .xsession-
-rw------- 1 manjo manjo 5.4K May 17 09:13 .xsession-errors
-rw------- 1 manjo manjo 31G May 16 21:03 .xsession-
You might be able to solve this problem if you delete the .xsessions-errors file once it grows to say 1GB or even better create it in /tmp so that it is removed on shutdown and does not eat up my full disk space. This bug renders the system useless, I cant even file a bug with ubuntu-bug, and it is very hard to find out what is eating up the disk space since .xsession-error.old is a hidden file any normal user will have no clue what just eat up his disk.
Changed in xorg (Ubuntu): | |
importance: | Undecided → Critical |
assignee: | nobody → Timo Aaltonen (tjaalton) |
summary: |
- [12.04] .xsession-errors getting spammed filling up the disk. + [12.04] [ Precise] .xsession-errors getting spammed filling up the disk. |
The Xsession script already includes functionality for truncating the log:
# truncate ERRFILE if it is too big to avoid disk usage DoS
if [ "`stat -c%s \"$ERRFILE\"`" -gt 500000 ]; then
T=`mktemp -p "$HOME"`
tail -c 500000 "$ERRFILE" > "$T" && mv -f "$T" "$ERRFILE" || rm -f "$T"
fi
However I believe this only runs at startup.