Score:0

/var keeps filling up

ca flag

I am on Ubuntu 22.04. My /dev/sda2 partition keeps running out of space. I delete files here and there as temporary fixes. I have deleted journal files and did auto-remove as well, but now these options aren't enough either. I still can't figure out what is causing /var to fill up.

 df -Th | grep '^/dev'

gives

/dev/sda2      ext4    23G   21G  764M  97% /
/dev/nvme0n1p1 vfat   146M  104M   43M  72% /boot/efi
/dev/sda4      ext4   863G   31G  789G   4% /home

and running

lsblk /dev/sda

gives

NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINTS
sda      8:0    0 931.5G  0 disk 
├─sda1   8:1    0    16M  0 part 
├─sda2   8:2    0  23.3G  0 part /var/snap/firefox/common/host- 
hunspell
│                                /
├─sda3   8:3    0  30.5G  0 part [SWAP]
└─sda4   8:4    0 877.7G  0 part /home

'/dev/sda2' is the one running out of space. Thanks in advance.

FedKad avatar
cn flag
9 GB of `/var` is normal. The reason it is filling up, is probably that you have allocated a very small sized partition for `/var`, which was wrong at the first place. You should increase the size of the `/var` partition. Even completely deleting the separate partition for `/var` and consolidating it into the root partition, may be something advisable.
Sanjiv avatar
ca flag
@FedKad actually the partition is 23 GB, so something else is the problem in this case? I haven't found a way to list the sizes of files by partition. Any leads on that? Thanks!
FedKad avatar
cn flag
You question lacks extra information. At least the output of `df -Th | grep '^/dev'` and `lsblk /dev/sda` should be included in your question. Please [edit] your question to add extra info.
Sanjiv avatar
ca flag
@FedKad thanks, i have added the suggested information
user535733 avatar
cn flag
Check logfile sizes in /var/log/ . If any are discovered, they are merely a symptom. Read the logfile to determine the actual cause that must be fixed.
pl flag
`sudo apt install ncdu` then `sudo ncdu /var` and this will reveal chunky files to investigate.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.