25

Can someone provide some background?

It seems like this folder is growing even when I'm not updating or installing any packages, but I'm not entirely sure about that.

Context: My AWS instances keep running out of disk space, and i already learned to do this periodically:

apt-get -y autoremove
apt-get -y autoclean

But I don't understand why it grows in the first place.

Also see:

EDIT: On my very new server i get this:

du -h -d1 /usr/src/ | sort -hr
266M  /usr/src/
115M  /usr/src/linux-aws-headers-4.15.0-1035
115M  /usr/src/linux-aws-headers-4.15.0-1032
19M   /usr/src/linux-headers-4.15.0-1035-aws
19M   /usr/src/linux-headers-4.15.0-1032-aws

1 Answers1

19

This is probably due to the automatic updates.

You can disable the automatic updates and even remove the unused kernel images and headers running sudo apt autoremove --purge (as you are already doing)

More info here: https://help.ubuntu.com/lts/serverguide/automatic-updates.html