VirtualBox kernel modules
Bernhard Fröhlich
decke at FreeBSD.org
Fri Jan 11 15:40:35 UTC 2013
On Fri, Jan 11, 2013 at 4:19 PM, Brandon Gooch
<jamesbrandongooch at gmail.com> wrote:
> On Thu, Jan 10, 2013 at 10:31 PM, Warren Block <wblock at wonkity.com> wrote:
>
>> On Thu, 10 Jan 2013, Ryan Stone wrote:
>>
>> As I recall, a make installkernel will first mv /boot/kernel
>>> /boot/kernel.old
>>>
>>> Should ports put modules in /boot/modules to avoid this kind of thing?
>>>
>>
>> I thought so, but the Porter's Handbook doesn't say anything about it.
>> multimedia/cuse4bsd-kmod installs a module there.
>
>
> The previous versions of this port did indeed install the modules into
> /boot/modules; only with the most recent version (4.2.6) has this changed.
> For example:
>
> $ tar tvf /usr/ports/packages/All/virtualbox-ose-kmod-4.1.22.txz
> [...]
> -r-xr-xr-x 0 root wheel 297288 Sep 19 09:19 /boot/modules/vboxdrv.ko
> -r-xr-xr-x 0 root wheel 9544 Sep 19 09:19 /boot/modules/vboxnetadp.ko
> -r-xr-xr-x 0 root wheel 26648 Sep 19 09:19 /boot/modules/vboxnetflt.ko
> [...]
>
> $ tar tvf /usr/ports/packages/All/virtualbox-ose-kmod-4.2.6.txz
> [...]
> -r-xr-xr-x 0 root wheel 337912 Jan 6 13:13 /boot/kernel/vboxdrv.ko
> -r-xr-xr-x 0 root wheel 9696 Jan 6 13:13 /boot/kernel/vboxnetadp.ko
> -r-xr-xr-x 0 root wheel 26808 Jan 6 13:13 /boot/kernel/vboxnetflt.ko
> [...]
>
> I don't know WHY this changed, or if it was just an oversight during the
> update -- perhaps it by (re)design...
I think this is an unwanted side effect. In fact I changed the defintion of
where the kernel module should be installed in virtualbox-ose-kmod/Makefile
from KMODDIR=/boot/modules to KMODDIR?=/boot/modules to allow
overwriting the KMODDIR in case you want to have a non default directory
for your kernel modules (like in a jail).
I haven't found yet where KMODDIR is set to /boot/kernel but it obviously is
defined somewhere. I'm also not sure if that is really a virtualbox
problem or if
we better should fix that in Mk and set KMODDIR or create a new variable for
ports kernel modules.
In the meantime overwriting KMODDIR to /boot/modules in your make.conf
should help.
--
Bernhard Froehlich
http://www.bluelife.at/
More information about the freebsd-emulation
mailing list