Solved How to install virtualbox-ose-additions safely on 9.3

I have installed 9.3-RELEASE in a Virtualbox VM from the DVD ISO and it works well (with X11 and Xfce). I installed Xorg and Xfce via # pkg install xorg and # pkg install xorg. However, I had a very bad experience trying to install virtualbox-ose-additions on a previous 9.3 installation which had to be abandoned and am anxious not to repeat this experience. What happened was my fault: I used # pkg -r install virtualbox-ose-additions and 9.3-STABLE was retrieved and installed before I realized what was going on. The result was a complete disaster: a different fr86 VESA driver, different keyboard driver and different mouse driver were installed and rebooting hung up repeatedly at
Code:
cleaning /tmp (X related)
A little afraid to try # pkg install virtualbox-ose-additions (without the -r option), I thought to make and install it (/usr/ports/emulators/virtualbox-ose-additions), but when the Makefile asked for the kernel source, I ran into trouble as sysinstall wouldn't recognize the DVD ISO that I had used to install 9.3 (the whole of /usr/src is on that DVD although I was just trying to install /usr/src/sys).

So my questions are two:
  1. is there a way to get sysinstall to recognize the DVD that I used to install 9.3 or is sysinstall broken here)? Or is there some other way to obtain the kernel source?
    OR
  2. can I safely use #pkg install virtualbox-ose-additions?

Many thanks,

cac
 
sysinstall(8) only supported old-style packages, and those are obsolete now. pkg is a completely new system from the old pkg_install, and -r does not even do the same thing any more.

It's difficult to see how pkg could have updated the operating system. It may just have been showing a repository name. Packages built for 9.3-STABLE will run on 9.3.

However, if the additions must be built anyway, why not just build them from the port?
 
I would like to build them from the port, but using sysinstall I'm unable to obtain the kernel source either from the DVD (where the whole source tree is available as a tgz file) or via FTP. Is there another way to obtain either just the kernel source or the whole source (I see now that I should have installed it during the main installation process, but I mistakenly assumed I could just get it during the post-installation process). As a last resort could I just copy the tgz by hand and untar it? Thanks.
 
Yes, the sources can be extracted into /usr/src. Please also see this article about upgrading ports: http://www.wonkity.com/~wblock/docs/html/portupgrade.html.
Done. I extracted the sources into the right place, built the additions, installed them, configured them (/etc/rc.conf), rebooted, and nothing was broken (at least so far [knock, knock, knock on wood]. Thanks again to all for their help. This thread may be considered closed successfully.
 
Back
Top