On Sunday 05 Mar 2017 16:57:11 Dale wrote: > the...@sys-concept.com wrote: > > On 03/05/2017 02:33 PM, the...@sys-concept.com wrote: > >> After upgrading my machine. I rebooted, everything went as planned. > >> So I decided to upgrade to a newer kernel. I was using: > >> linux-3.10.7-gentoo-r1 > >> > >> and decided to switch to: > >> linux-4.9.6-gentoo-r1 > >> > >> I've done kernel upgrade many, many times so it was a routine procedure. > >> When I re-booted the last thing on the screen were letter: > >> > >> "GRUB" and blank screen, not even a kernel selection. > >> I scramble, boot strap the system and copied two file in /boot/ > >> kernel-old --> kernel-current > >> System.map-old --> System.map-current > >> > >> I was under impression that something is wrong with the current (newest > >> kernel). But it seems to me I run out of room on the /boot partition.> > > [snip] > > > >> -rw-r--r-- 1 root root 2.9M Mar 5 11:03 System.map-current > >> -rw-r--r-- 1 root root 2.9M Mar 5 10:12 System.map-old > > > > [snip] > > > > Can I remove System.map files from /boot partition? > > I don't have any reference to these files in grub.conf. > > > > default 0 > > timeout 30 > > splashimage=(hd0,0)/boot/grub/splash.xpm.gz > > > > title Gentoo Current Kernel > > root (hd0,0) > > kernel /boot/kernel-current root=/dev/sda3 vga=normal > > > > title Gentoo Old Kernel > > root (hd0,0) > > kernel /boot/kernel-old root=/dev/sda3 > > > > This would save me almost 6Mb > > > > -- > > Thelma > > > > . > > I'm pretty sure grub uses that file. I've never tested the theory. > > Why such a small /boot? My OS is installed on a fairly small 160GB hard > drive. I made /boot about 400MBs and later wished it was bigger. I > later wanted to put a ISO image there for sysrescue. If I were to set > up a new system now with that same size or larger drive, I'd likely make > /boot 1GB and maybe even 2GBs in size. The amount of space is not that > large compared to the size of the hard drive. If one is pressed to save > space that bad on a system, maybe they need a larger drive?? > > You mentioned following a guide on that size. I have to ask, just how > old was that guide? I looked at the Gentoo install guide, it suggests > 128MBs for /boot, which I think is to small. Whatever guide you were > using, it must be old and need some updating. I'm not sure I'd follow > that one until it was. > > Dale > > :-) :-)
Yes, back in the GRUB legacy days boot partition was suggested to be something like 30MB I recall. However, things have moved on and kernels got bigger since then. Despite this, on an old box using GRUB legacy I have 2 kernel images, two System files, two config files. I also have installed memtest, which in an isolinux directory on its own is taking up 11MB. My boot partition is 46MB, but only 33MB is used. If I didn't have memtest installed, then my 2x kernel, System and config files would fit in less than 20MB. Do you have anything else in there you have not accounted for? For example how large is this /boot/grub/splash.xpm.gz of yours? There's different ways you can hack at this problem: 1. What Alan said. 2. Tar everything out of the whole installation, resize/delete/recreate partitions, move everything back. Not as slow and painful as Alan spoke of. 3. Create a new partition at the end of the disk, large enough for boot, after you resize the last partition to free up some space. 4. Do not create a new partition for boot, just copy the /boot filesystem into / and comment out the boot partition from fstab. You'll need to also edit your /boot/grub/grub.conf 5. Boot with a LiveCD, delete/move old kernel and/or any unnecessary files, check /boot/grub/grub.conf, reboot. Any of the above will work, but some make more sense than others depending on your use case for this particular installation. -- Regards, Mick
signature.asc
Description: This is a digitally signed message part.