Upgrading a Jail from Source

I've seen tons of questions online about how to upgrade a jail using make buildworld. Here's how I do mine.

The jail needs to be shutdown before this is run (unless you're the daring type). This assumes you've already upgraded (installed and all) the base system to the same version of FreeBSD as your jail and you have the new version built in /usr/src. See the FreeBSD manual for how to do this.

JAIL=/jails/thejail.com
echo $JAIL

cd /usr/src &&
make installworld DESTDIR=$JAIL &&
mergemaster -i -C -D $JAIL

Yup, it's that simple. Naturally if you've cleaned up your jail this'll put all those files back.

I may be missing something. Let me know.

   [ home page ]