Keeping FreeBSD with custom kernel up to date: freebsd-update no option?

andreas scherrer ascherrer at gmail.com
Wed Apr 17 20:37:10 UTC 2013


Thank you very much for your detailed answer!

on 16.4.13 22:18  Polytropon said the following:
> On Tue, 16 Apr 2013 21:38:16 +0200, andreas scherrer wrote:
>> I am (still) struggling to understand how to keep my FreeBSD system up
>> to date ("world"/system, not ports). I want to "track" RELEASE (not a
>> development branch) and I want to receive security related updates. And
>> I want to run a custom kernel.
> 
> Without actually havint tested it, it seems that if you want
> to use freebsd-update (binary updating), you should note this:
> 
> In /etc/freebsd-update.conf, you should have the line for what
> to update as "Components src world".

That's what I thought (and currently have).

> This should prevent overwriting of the kernel, but you need to
> compile your kernel and install it. The component "src" will
> make sure you have the proper kernel sources. I assume a custom
> kernel configuration file in /usr/src/sys/{i386|amd64}/conf/
> is _not_ being overwritten by freebsd-update.

A custom kernel configuration file is *not* overwritten by
freebsd-update, I can confirm this. Of course I will have to compile and
install my custom kernel manually.

For some reason I was under the impression that /usr/src/sys is not
being updated by freebsd-update if I remove "kernel" from the
"Components" directive in freebsd-update.conf. But I might be wrong (I
will check).

Maybe related to this: how does freebsd-update "know" what
sources/binaries to get when I don't use the "-r" switch? Does it rely
on /usr/src/sys/conf/newvers.sh?

Could it be that I never saw a change to my kernel sources
(/usr/src/sys) because freebsd-update was tracking some static sources?

[snip]

>> I'm on a low powered consumer
>> device and it takes considerable amount of time to build the world and
>> kernel (plus I still don't feel comfortable doing such tasks remotely).
> 
> In this case, use freebsd-update as explained at the beginning of
> my message: Update components "world" and "src", leave out "kernel",
> the rebuild the kernel by source and install it. Then reboot.

That's what I am planning to do. Let's see.

As I currently have a checkout from SVN in /urs/src I need to get rid of
this. Can I just copy (read: move) back my previous /usr/src directory
and continue to use freebsd-update? I think this should work, right? I
am just not sure if freebsd-update still "knows" what sources/binaries
to track (see my previous comment about how freebsd-update knows what
source to use).


Cheers
andreas


More information about the freebsd-questions mailing list