1

I just installed Ub 10.04.2 LTS -64bit on a new drive in my new laptop. Didn't allocate enough space for /boot partition, and Update Manager choked on updating the kernel -- or at least I think that's it... (grin)

I found and followed 2nd paragraph in [ Can I expand my /boot without upsetting the system? ]. I'm now going to boot the LiveCD I used to install (64-bit) and trust GParted to move partitions and increase size of sda1 to 1GB (now 100MB). I've done similar things with other distros, so I'm hopeful this will work; but how do I get my /boot partition set back to sda1 once I have it big enough?

Will I need to:

  1. mount -t ext4 /dev/sda1 /mnt
  2. cp -ax /boot/. /mnt
  3. gedit /etc/fstab ;un-comment '/boot partition' line (didn't remove)
  4. --then how do I deal with the 'new' boot directory, from a live & mounted root filesystem, before re-running grub-install /dev/sda?

Or, have I completely lost my mind to think this could be easily accomplished?

Also, is it necessary to have /boot in a separate partition to be able to multi-boot several (possibly 10 or more, eventually) separate distros?

Some day I'll investigate Virtual Machines as I'm sure they're more efficient (and why I got a dual-core AMD), but for now, I'm still hoping to customize an installation which survives a shut-down/ power-up cycle -- in less than seventy-something reinstalls! (grin) Some might even call me dangerous...

BTW, I dropped the 'sudo' part because I run one terminal window as root -- which might explain the huge number of reinstalls. Oh, to be cut-apart by the sharp edge of a learning curve! (smile)

Thanks so much, in advance!

--Tom

Tom
  • 11

1 Answers1

2

If you need to expand your /boot, you should shrink a partition next (or previous) to the /boot partition.

Assuming you've partitioned your disk like /boot (sda1) and / (sda2):

  1. Backup data. I've never lost data when using GParted, but you may have less luck if there is a power failure or some other hardware error.
  2. Boot into a Live CD without mounting any filesystems
  3. (optional) Update the software sources and GParted, this ensures that you've the latest version from the repos available:

    sudo apt-get update && sudo apt-get install gparted
    
  4. Shrink sda2 on the left side to allocate space for /boot
  5. Expand sda1 to fill the allocated space.
  6. Apply the changes

No further actions like grub-install are required since you did not remove the partition and hence the UUID and partition device number did not change.

Lekensteyn
  • 178,446