Cleaning up Debian expressly used for Xen Orchestra?

So I have a small computer running Debian and use it just for the “community” version of Xen Orchestra. I went to update today and it says I don’t have enough room. I cleared out a couple of things and made enough, but I’m now back down to 700mb free. It is only a 16gb disk, again very limited use machine.

The end of the update process said leaving the last three versions of XO, and each version is slightly bigger than 500mb. Can I just delete old versions if I know I won’t be needing to go backwards? This is on my lab system so nothing will die if I completely lose this machine.

Where else should I be looking for disk bloat, seems I should have more like 3gb free. I’m using XFCE as a desktop.

Unless you need the old versions, delete them, also I would not even load a desktop to free up more space.

I still need a desktop for some things, not enough experience to get through without it yet. Yes it is a crutch.

1 Like

Throw the desktop crutch and adopt the forum crutch.

It’s safe to delete old versions. You can also edit xo-install.cfg and set preserve to lower value. It controls how many old installations are kept.

I have it set for “keep 2” now which is helping.

Yeah, on such a size restricted machine, any desktop environment will typically be the biggest “bloat” culprit - even XFCE.

So in the name of working on your cli-fu:

  • Use ncdu to scan and get an overview of what’s eating your disk usage. As root:
apt install ncdu
ncdu /
  • If using ext4, you might want to look at the filesystem reserved blocks. Usually defaults to 5%, not much to play with but might help if you’re scrounging around for a few hundreds of MB. Be careful not to set this to 0%, especially on an active root filesystem. In a pinch, you might set it to 1%, perform necessary maintenance/cleanups and revert to 5% after. Can be performed while mounted, again as root:
# view current reserved block count, assuming / is mounted to sda1
tune2fs -l /dev/sda1 | grep 'Reserved block'
# adjust to 1%
tune2fs -m 1 /dev/sda1

Obviously heed the usual run as root precautions. ncdu will gladly delete /etc or even / if you ask it to while running privileged.

Thanks! Appreciate the Linux tutorials, I really need to spend more time learning this type of OS.

I did buy a dedicated device for this, but not much time spent on it yet… I bought a Devterm A06 for a few tasks, and because it was neat and I liked what they were doing. With Manjaro running it seems to be mostly complete now. A little off topic, but interesting too. https://www.clockworkpi.com/devterm Now Pi4CM compatible if that is something you want, or Pi4CMS which is Pi3CM compatible. Waiting for more cores and more ram to get into RISC V.