#2351 closed defect (fixed)
Solaris install successful even with postinstall failure
Reported by: | injinius | Owned by: | |
---|---|---|---|
Component: | installer | Version: | VirtualBox 2.0.2 |
Keywords: | Solaris postinstall vboxdrv | Cc: | |
Guest type: | other | Host type: | Solaris |
Description
I tried installing VirtualBox on a Solaris 10 box using the Readme.txt instructions. The following step:
pkgadd -G -d VirtualBox-2.0.2-SunOS-amd64-r36488.pkg
produced the following error messages during the postinstall phase: [...] ## Executing postinstall script. Configuring VirtualBox kernel module... /opt/VirtualBox/vboxdrv.sh: /usr/xpg4/bin/id: not found /opt/VirtualBox/vboxdrv.sh: test: argument expected /opt/VirtualBox/vboxdrv.sh: /usr/xpg4/bin/id: not found /opt/VirtualBox/vboxdrv.sh: test: argument expected Configuring VirtualBox NetFilter kernel module... /opt/VirtualBox/vboxdrv.sh: /usr/xpg4/bin/id: not found /opt/VirtualBox/vboxdrv.sh: test: argument expected Creating links... devfsadm: driver failed to attach: vboxdrv Done.
but the package manager still thought the installation went well:
Installation of <SUNWvbox> was successful.
Apparently, the problem was that this machine was missing the /usr/xpg4/bin/id command (from the SUNWxcu4 package). In any case, I'm assuming that the "devfsadm: driver failed to attach: vboxdrv" message means that the install wasn't successful and that the overall package installation should have failed too.
Change History (11)
comment:1 by , 16 years ago
comment:2 by , 16 years ago
It was Solaris 10 u5. I don't have access to the machine right now, so I can't produce the /etc/release information. In any case, I don't see how the Solaris version makes that much of a difference. I'm assuming this is a shell scripting bug (i.e. not checking the error status of vboxdrv.sh) which allows the install to complete successfully.
comment:3 by , 16 years ago
The Solaris version becomes relevant because most other S10 u5s has /usr/xpg4/bin/id. I will fix the installer, thanks for the report.
comment:4 by , 16 years ago
Thanks for the quick response. I can't say why the xpg4 "stuff" wasn't available on this system. It is there on some other Solaris 10 u5 boxes I have access to. Again, hopefully this fix will make the postinstall a little bit more bulletproof.
comment:6 by , 15 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
I just installed 2.2.4 on SXCE B115 without the SUNWxcu4 and vboxdrv.sh failed. The check_root function has a problem...it tries /usr/xpg4/bin/id first, then wants to fall back to the result of 'which id', but the logic isn't right.
if test ! -f "$idbin"; then
found=
which id | grep "no id"
if test ! -z "$found"; thenabort "Failed to find a suitable user id binary! Aborting"
else
idbin=$found
fi
fi
$found is set to an error string if id isn't found (because of the grep), and is empty if it is, breaking the "idbin=$found" portion (it's set to nothing).
One way to fix it is to use "idbin=which id
" in the else part, which is how I hacked it to work.
comment:8 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
comment:9 by , 15 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
The check_root function seems to have issues in the 3.0.8 release. It has:
if test ! -f "$found" || test ! -h "$found"; then
and should really be
if test ! -f "$found" && test ! -h "$found"; then
Thanks.
Bryan
comment:10 by , 15 years ago
It should be
if test ! -x "$found"; then
Will be fixed in SVN, thanks for the report.
Which version of Solaris 10 is this? u4 or u5 or..? Could you please paste output of cat /etc/release ?