FreeBSDUpgrade

WebHome | UnixGeekTools | Geekfarm | About This Site

Notes for upgrading a FreeBSD box.

Pointers

Warning

This is just my checklist for upgrading my FreeBSD 6 servers. Please see the instructions here.

Getting the release source

Tracking Stable

Building

    # script /var/tmp/world_make.out

pre-buildworld mergemaster

    cd /usr/src/usr.sbin/mergemaster
    ./mergemaster.sh -p

Remove /usr/obj

    cd /usr/obj
    chflags -R noschg *
    rm -rf *

build the world

    cd /usr/src
    make -j4 buildworld
    chflags -R noschg /usr/obj/usr
    rm -rf /usr/obj/usr
    cd /usr/src
    make cleandir
    make cleandir

kernel

    make -j4 buildkernel [KERNCONF=MYKERNEL]
    make installkernel [KERNCONF=MYKERNEL]

reboot in single user mode

    reboot
    # choose single user mode
    fsck -p
    mount -u /
    mount -a -t ufs
    swapon -a

log output

    script /var/tmp/world_install.out

check date command to see if time is correct, if not...

    adjkerntz -i

finish up the install

    mergemaster -p
    cd /usr/src
    make installworld
    mergemaster
    reboot

update ports

    portupgrade -fR portupgrade
    portupgrade -af

update all FreeBSDJails

    cd /usr/src
    # i've seen build errors several times when i didn't do this next step :(
    make -j4 buildworld DESTDIR=/jailroot
    mergemaster -p -D /jailroot
    make installworld DESTDIR=/jailroot
    mergemaster -D /jailroot




Updated Sat Jan 20, 2007 3:29 PM