Thursday, May 9, 2024
 Popular · Latest · Hot · Upcoming
12
rated 0 times [  12] [ 0]  / answers: 1 / hits: 4373  / 1 Year ago, wed, february 1, 2023, 9:50:43

I'm trying to upgrade Ubuntu to the latest version, and I get this Error:


Not enough free disk space

The upgrade has aborted. The upgrade needs a total of 430 M free space on disk '/boot'. Please free at least an additional 37.8 M of disk space on '/boot'. You can remove old kernels using 'sudo apt autoremove' and you could also set COMPRESS=xz in /etc/initramfs-tools/initramfs.conf to reduce the size of your initramfs.

From gparted I read that my /boot partition is 732 MB, with 425 free. I would have gladly allocated more space to /boot to avoid this issue, but given where I'm at now, here's what I did:



  • I ran sudo apt autoremove --this made no difference.

  • I'm trying to add compression, but the instructions just say set COMPRESS=xz .... Presumably, that means changing the following line in /etc/initramfs-tools/initramfs.conf from this:


COMPRESS=lz4


to this:


COMPRESS=gz


... but then what? Should I save that file and then reboot? Should I log out and log back in again? Should I reinitialize something somewhere with some kind of command? More clarification here would be really helpful. What does it mean to "set" the COMPRESS value and what do I need to do after editing the above file for the changes to take effect?


More From » boot

 Answers
2

Type in the terminal:


sudo nano /etc/initramfs-tools/initramfs.conf

It will open the file in the editor.

Change COMPRESS=zstd to COMPRESS=xz


View screenshot


Then rebuild the images using


sudo update-initramfs -u -k all

[#272] Friday, February 3, 2023, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
tocklftime

Total Points: 110
Total Questions: 109
Total Answers: 100

Location: Mayotte
Member since Mon, Sep 12, 2022
2 Years ago
tocklftime questions
;