2

Because of a low-graphics error I am not able to log into my system any more, or at least I am not seeing any graphical interface (solutions here How to fix "The system is running in low-graphics mode" error? have been tried).

df -h revealed that my /dev/sda6 partition is full:

Filesystem Size Used Avail Use% Mounted on
/dev/sda6 7.4G 6.6G 398M 95% /
udev 1.9G 4.0K 1.9G 1% /dev
tmpfs 762M 424K 762M 1% /run
none 5.0M 0 5.0M 0% /run/lock
none 1.9G 0 1.9G 0% /run/shm
overflow 1.0M 4.0K 1020K 1% /tmp
/dev/sda7 449G 266G 161G 63% /home
/dev/sda1 447M 115M 308M 28% /boot

and

sudo du -kxa / | sort -nr | head leads to the output

sort: write failed: /tmp/sortXXXXXX (X = any number or letter): 
No space left on device

Therefore my question, how do I clean this /tmp/sortXXXXXX folder or directory with terminal commands and how do I set permission flags for that folder or directory to the standard value? I assume I messed up this permissions and now every process is writing to tmp.

2
  • Added df -h output.
    – Stockfisch
    Feb 9, 2013 at 16:30
  • That question does have answers about low disk space
    – Zanna
    May 14, 2017 at 20:33

2 Answers 2

1

Your problems it isn't the /tmp, your problem is the full partition.

The sort command use a file to store temporal data, you haven't space to do it.

Try to make some space deleting old logs:

sudo find /var/log/ -name "*.gz" -exec rm -v {} \; 
sudo find /var/log/ -name "*.0" -exec rm -v {} \; 
sudo find /var/log/ -name "*.1" -exec rm -v {} \;

You can do more space cleaning the apt cached files: sudo apt-get clean sudo apt-get autoclean

3
  • Thanks! Did that. The first command deleted quite some files but still; sudo du -kxa / | sort -nr | head gives me sort: write failed: /tmp/sortGA4Fww: No space left on device. How may I see what exactly is taking up the space there?
    – Stockfisch
    Feb 9, 2013 at 16:33
  • Can you check if you have space with the command?: "df -h" Did you have /tmp mounted at other filesystem. Can you copy and paste the output of the comand "mount" and "df -h"
    – xkill
    Feb 9, 2013 at 16:44
  • As /tmp is on its own partition deleting those files in /var/ doesn't help. Feb 9, 2013 at 16:52
0

You have /tmp as virtual RAM disk, disable it by editing the file /etc/fstab and comment or remove the line that start with /tmp. Reboot your computer.

Not the answer you're looking for? Browse other questions tagged .