Question About Tracking the Stable Branch

Kevin Oberman kob6558 at
Tue Aug 28 21:04:01 UTC 2012

On Tue, Aug 28, 2012 at 1:31 PM, Jamie Paul Griffin <jamie at> wrote:
> Hi
> I am following 9 Stable. I have read the handbook information and I am now subscribed to this list and the svn-src-stable-9@ list.
> Even after reading the handbook, what i'm not clear about is this:
> I see individual commits being submitted to the source tree; do I:
>         - patch and update each individual commit, or;
>         - rebuild world say once every couple of days or even each day to incorporate the changes, and;
>         - does the kernel need to be rebuilt and reinstalled each time if using the first option. Obviously I would have to if rebuilding world (the second option).
> Am I right in thinking that it also depends on the type of change; i.e. if the change is to a kernel and/or a kernel module then clearly I need to rebuild the kernel. But, then would I need to rebuild the userland as well?
> I hope I am making sense and not asking dumb questions, I just want to be clear about the process.
> Essentially, I want to know if it's necessary to rebuild the entire userland and kernel sources just to incorporate a small number of changes. Obviously that's a lot of time compiling. Or, do I just patch the commited files and rebuild that bit of the sourse tree and the kernel if necessary due to the type of change made.
> I've not followed a FreeBSD stable branch before so just wanted to clarify those points. I'd like to be involved with testing things for the project, etc.

Most people DON'T try to update for every commit. Many will rebuild on
a daily basis. Many weekly or monthly. Some only when they see a need
(such as a fix for a problem they are experiencing) or just get around
to it. How you choose to do do it is entirely up to you.

Manually applying updates and just rebuilding things that use that
change is certainly possible, but requires careful insight as to what
a given patch will impact. Does it result in a new library that my, in
turn, require the rebuild of code that uses it? Kernel patches can be
integrated but it is far easier to just update modules if the patch is
to a part of the kernel that can be loaded as a module.

In all cases, if you rebuild the kernel, be sure that the old kernel
is saved to kernel.old so you can go back to it if there si a problem.
'make installkernel' does this) and, should you fix a problem and
re-link the kernel, be sure NOT to overwrite the working kernel ('make
reinstallkernel' does this.

Also, many kernel changes impact the KBI, so some userland tools that
use kernel structures (e.g. top) my fail after a kernel update that is
not accompanied by a userland rebuild.

In general, I update stable about once a month. I use 'svn up' to
update my source tree and then follow the "standard" instructions:
cd /usr/src
rm -rf /usr/obj/*
make -j6 -DNO_CLEAN buildworld
mergemaster -p (usually a no-op)
make -j6 buildkernel
make installkernel
shutdown -r now (to single user mode)
fsck -p
adjkerntz -i (if the hardware clock is not running UTC)
swapon -a
mount -a -t ufs
cd /usr/src/
make installworld
mergemaster -iPF (Use -U at your own risk. It saves time, but you
might miss something on rare occasion.)
make check-old
rm -rf any deleted directories (saves time)
make delete-old
R. Kevin Oberman, Network Engineer
E-mail: kob6558 at

More information about the freebsd-stable mailing list