virtualbox升级出错了,dpkg-l的结果是 iF

Kvm、VMware、Virtualbox、Xen、Qemu 等
回复
chufunyu
帖子: 46
注册时间: 2010-04-07 16:27
送出感谢: 0
接收感谢: 0

virtualbox升级出错了,dpkg-l的结果是 iF

#1

帖子 chufunyu » 2010-11-18 17:31

是用apt-get upgrade来升级到3.2.10,,.:
但是110: Can't open /etc/init.d/functions
有这样的错误,,不过没多少关系,软件都能使用也没问题。

可是在今天upgrade的时候

代码: 全选

Setting up virtualbox-3.2 (3.2.10-66523~Ubuntu~maverick) ...
addgroup: The group `vboxusers' already exists as a system group. Exiting.
 * Stopping VirtualBox kernel modules        
 * Cannot unload module vboxdrv
.: 110: Can't open /etc/init.d/functions
invoke-rc.d: initscript vboxweb-service, action "start" failed.
dpkg: error processing virtualbox-3.2 (--configure):
 subprocess installed post-installation script returned error exit status 127
No apport report written because MaxReports is reached already
Setting up linux-image-2.6.35-23-generic (2.6.35-23.40) ...
Running depmod.
update-initramfs: Generating /boot/initrd.img-2.6.35-23-generic
Not updating initrd symbolic links since we are being updated/reinstalled 
(2.6.35-23.37 was configured last, according to dpkg)
Not updating image symbolic links since we are being updated/reinstalled 
(2.6.35-23.37 was configured last, according to dpkg)
Examining /etc/kernel/postinst.d.
run-parts: executing /etc/kernel/postinst.d/dkms 2.6.35-23-generic /boot/vmlinuz-2.6.35-23-generic
 * dkms: running auto installation service for kernel 2.6.35-23-generic        
 *       fglrx (8.780)...        
[ OK ]
 *       vboxhost (3.2.10)...        
[ OK ]
run-parts: executing /etc/kernel/postinst.d/initramfs-tools 2.6.35-23-generic /boot/vmlinuz-2.6.35-23-generic
run-parts: executing /etc/kernel/postinst.d/nvidia-common 2.6.35-23-generic /boot/vmlinuz-2.6.35-23-generic
run-parts: executing /etc/kernel/postinst.d/pm-utils 2.6.35-23-generic /boot/vmlinuz-2.6.35-23-generic
run-parts: executing /etc/kernel/postinst.d/update-notifier 2.6.35-23-generic /boot/vmlinuz-2.6.35-23-generic
run-parts: executing /etc/kernel/postinst.d/zz-update-grub 2.6.35-23-generic /boot/vmlinuz-2.6.35-23-generic
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-2.6.35-23-generic
Found initrd image: /boot/initrd.img-2.6.35-23-generic
Found memtest86+ image: /boot/memtest86+.bin
Found Windows 7 (loader) on /dev/sda1
done
Setting up linux-headers-2.6.35-23 (2.6.35-23.40) ...
Setting up linux-headers-2.6.35-23-generic (2.6.35-23.40) ...
Examining /etc/kernel/header_postinst.d.
run-parts: executing /etc/kernel/header_postinst.d/dkms 2.6.35-23-generic /boot/vmlinuz-2.6.35-23-generic
 * dkms: running auto installation service for kernel 2.6.35-23-generic        
 *       fglrx (8.780)...        
[ OK ]
 *       vboxhost (3.2.10)...        
[ OK ]
run-parts: executing /etc/kernel/header_postinst.d/nvidia-common 2.6.35-23-generic /boot/vmlinuz-2.6.35-23-generic
Setting up openssl (0.9.8o-1ubuntu4.2) ...
Processing triggers for python-central ...
Errors were encountered while processing:
 virtualbox-3.2
Setting up virtualbox-3.2 (3.2.10-66523~Ubuntu~maverick) ...
addgroup: The group `vboxusers' already exists as a system group. Exiting.
 * Stopping VirtualBox kernel modules        
 * Cannot unload module vboxdrv
.: 110: Can't open /etc/init.d/functions
invoke-rc.d: initscript vboxweb-service, action "start" failed.
dpkg: error processing virtualbox-3.2 (--configure):
 subprocess installed post-installation script returned error exit status 127
Processing triggers for python-central ...
virtualbox-3.2
E: Sub-process /usr/bin/dpkg returned an error code (1)
貌似每次安装软件都会有这样的错误,,
你们在用 新版本的virtualbox的时候有这样的情况吗??
有什么解决的办法。。。
saillee
帖子: 1
注册时间: 2008-07-26 0:28
送出感谢: 0
接收感谢: 0

Re: virtualbox升级出错了,dpkg-l的结果是 iF

#2

帖子 saillee » 2010-11-28 2:17

检查看看你/etc下面是否有redhat-release文件,如果有的话,把名字改了以后在安装或升级,就不会有这个问题了,我也是找了很久才发现这个问题的。

由于自己机器上要安装Oracle,当时加入了redhat-release来模拟RedHat环境,估计是virtualbox误以为是redhat操作系统环境才导致出错的。

看看/etc/init.d/vboxweb-service中有一段系统环境检测的代码:

代码: 全选

system=unknown
if [ -f /etc/redhat-release ]; then
    system=redhat
    PIDFILE="/var/lock/subsys/vboxweb-service"
elif [ -f /etc/SuSE-release ]; then
    system=suse
    PIDFILE="/var/lock/subsys/vboxweb-service"
elif [ -f /etc/debian_version ]; then
    system=debian
    PIDFILE="/var/run/vboxweb-service"
elif [ -f /etc/gentoo-release ]; then
    system=gentoo
    PIDFILE="/var/run/vboxweb-service"
elif [ -f /etc/arch-release ]; then
     system=arch
     PIDFILE="/var/run/vboxweb-service"
elif [ -f /etc/slackware-version ]; then
    system=slackware
    PIDFILE="/var/run/vboxweb-service"
elif [ -f /etc/lfs-release ]; then
    system=lfs
    PIDFILE="/var/run/vboxweb-service.pid"
else
    system=other
    if [ -d /var/run -a -w /var/run ]; then
        PIDFILE="/var/run/vboxweb-service"
    fi
fi
由于我系统中有redhat-release文件,所以vbox误以为我的系统是RedHat Linux。
diligentcat
帖子: 1
注册时间: 2012-06-22 8:14
送出感谢: 0
接收感谢: 0

Re: virtualbox升级出错了,dpkg-l的结果是 iF

#3

帖子 diligentcat » 2012-06-29 7:48

原来如此,oracle跟redhat的关系不一般啊,呵呵
回复

回到 “虚拟机和虚拟化”