You are not logged in.

#1 2014-06-15 18:00:59

vagif
Member
Registered: 2007-12-26
Posts: 37

How to move /boot to /

My /boot is full. Was too small to begin with, only 32 mb. And finally today i could not upgrade linux package. It said no more room.

I do not want to deal with resizing partitions. Rather i want to simply copy /boot folder to folder under / and reconfigure system to boot from it.

How do i do that? What do i need to change in grub2 config and fstab to make it work?

Another temporary solution could be just deleting some unnessesary files in /boot folder. But i'm afraid to do that because i do not know which ones are unnecessary smile

There are for example files grub.cfg.example, grub.cfg.pacnew and grub.cfg.pacsave that i'm pretty sure i can delete. Just wanted to confirm.

Offline

#2 2014-06-15 18:34:57

dif
Member
From: Stalowa Wola, Poland
Registered: 2009-12-22
Posts: 137

Re: How to move /boot to /

This is not quite a reply you asked for, but as long as you can log in normally you can delete or move initramfs-linux-fallback.img elsewhere. This will not quarantee a successful upgrade, but should be safe to do.

Offline

#3 2014-06-15 18:46:10

vagif
Member
Registered: 2007-12-26
Posts: 37

Re: How to move /boot to /

Thx. I solved my problem for now by removing folder /boot/grub/fonts, that contained huge (2 mb) unicode.pf2 file and configuring /etc/default/grub to use /usr/share/grub/unicode.pf2. That gave me enough free space for upgrade.

Offline

#4 2014-06-15 18:53:13

headkase
Member
Registered: 2011-12-06
Posts: 1,983

Re: How to move /boot to /

You should be able to do it with your live-cd and a copy of gparted.

Modify your /etc/fstab and remove the /boot entry from the live-cd when nothing is mounted.  Then from the partition that /boot is on, copy all those files and sub-directories to the partition that / is on - within a /boot directory.  Then boot gparted and erase the partition /boot is on and merge its newly free space into a convenient partition - either / or whatever partition is adjacent to it.

Then reboot into your Arch system and everything should be well.  I've not done this but I don't see anything wrong with it.  Make sure that your /dev/sdaX or UUID's in your fstab match the new layout before booting.  If not you can always fix them after from the live-cd.

Offline

#5 2014-06-15 18:57:00

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 20,257

Re: How to move /boot to /

headkase wrote:

Modify your /etc/fstab and remove the /boot entry from the live-cd when nothing is mounted.  Then from the partition that /boot is on, copy all those files and sub-directories to the partition that / is on - within a /boot directory.  Then boot gparted and erase the partition /boot is on and merge its newly free space into a convenient partition - either / or whatever partition is adjacent to it..

That will only work on a BIOS system.  EFI (I think) requires that the boot partition be that of a proprietary file system from the American Pacific Northwest


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#6 2014-06-15 19:09:54

headkase
Member
Registered: 2011-12-06
Posts: 1,983

Re: How to move /boot to /

Ah, ok, thanks ewaller - I wasn't familiar with that caveat.

Offline

#7 2014-06-15 20:32:27

Head_on_a_Stick
Member
From: The Wirral
Registered: 2014-02-20
Posts: 8,408
Website

Re: How to move /boot to /

vagif wrote:

[...] i want to simply copy /boot folder to folder under / and reconfigure system to boot from it [...]

Boot from a live distro, mount the partition containing / to /mnt/main the partition containing /boot to /mnt/boot then copy /mnt/boot to /mnt/main.
Then remove the "/boot" entry from your fstab, (arch-)chroot into Arch & reinstall GRUB.
As ewaller has noted: this will not work if you intend to boot-up in EFI-mode...
smile


Para todos todo, para nosotros nada

Offline

Board footer

Powered by FluxBB