Re: Default FS Layout Too Small?

From: Freddie Cash <fjwcash_at_gmail.com>
Date: Tue, 24 Feb 2009 13:20:40 -0800
On February 24, 2009 1:03 pm Rick Macklem wrote:
> On Tue, 24 Feb 2009, Stephen Montgomery-Smith wrote:
> > Sean Bruno wrote:
> > cd /usr/src
> > make installkernel
> > .... this dies with a "file system full" error
> > rm -r /boot/kernel.old
> > make installkernel
>
> Although I wouldn't recommend it "in general", for your case I would
> make sure everything you need is configured into the kernel you build
> (so it doesn't need any loadable modules) and then:
>
>    cd /usr/src/sys/<arch>/compile/GENERIC
>    mkdir /boot/kernel.new
>    cp kernel /boot/kernel.new
>
> so that you can boot the new one and see it work before deleting the
> old one.

cd /usr/src
make KERNCONF=WHATEVER buildkernel
make KERNCONF=WHATEVER KODIR=/boot/kernel.new installkernel
nextboot -k kernel.new
reboot

That will install the new kernel into a separate directory, and will cause 
the next boot *only* to use the new kernel.  If things fail, you just 
reboot, and it goes back to the old kernel.  If things work, then it's a 
simple rename of the kernel directory:
  cd /boot
  mv kernel kernel.old
  mv kernel.new kernel
  reboot

KODIR and nextboot are very handy ... especially for remote upgrades.
-- 
Freddie
fjwcash_at_gmail.com
Received on Tue Feb 24 2009 - 20:20:43 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:42 UTC