2009/2/11

ubuntu中编译新内核后nvidia-common出错

昨天我手动编译了新的内核,linux-kernel-2.6.28.4.编译后我的系统并没有出来什么大问题,可是今天我更新系统的时候出现了我以前没有遇到过的问题。代码附在后面。在网上并没有找到解决方法。于是自己来分析一下原因。我注意到,程序关键出错在执行到run-parts: executing /etc/kernel/postinst.d/nvidia-common时。而nvidia-common是N卡的驱动相关的软件包。而我自己的是A卡。我想这个跟我的系统应该没有多大关系。所以选择删除。
执行:
sudo apt-get purge nvidia-common
删除之后再继续安装刚才的软件。这次没有再报错顺利执行了。呵呵!好高兴,之后我再把nvidia-common重新装上。

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
hal-info
1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
Need to get 46.1kB of archives.
After this operation, 0B of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://mirrors.163.com intrepid-proposed/main hal-info 20090128-0ubuntu1~intrepid2 [46.1kB]
Fetched 46.1kB in 1s (36.3kB/s)
(Reading database ... 210357 files and directories currently installed.)
Preparing to replace hal-info 20090128-0ubuntu1~intrepid1 (using .../hal-info_20090128-0ubuntu1~intrepid2_all.deb) ...
Unpacking replacement hal-info ...
Processing triggers for hal ...
Regenerating hal fdi cache ...
* Restarting Hardware abstraction layer hald [ OK ]
Setting up linux-image-2.6.28.4-custom (2.6.28.4-custom-10.00.Custom) ...
Running depmod.
Finding valid ramdisk creators.
Using mkinitramfs-kpkg to build the ramdisk.
initrd.img(/boot/initrd.img-2.6.28.4-custom
) points to /boot/initrd.img-2.6.28.4-custom
(/boot/initrd.img-2.6.28.4-custom) -- doing nothing at /var/lib/dpkg/info/linux-image-2.6.28.4-custom.postinst line 583.
vmlinuz(/boot/vmlinuz-2.6.28.4-custom
) points to /boot/vmlinuz-2.6.28.4-custom
(/boot/vmlinuz-2.6.28.4-custom) -- doing nothing at /var/lib/dpkg/info/linux-image-2.6.28.4-custom.postinst line 583.
Running postinst hook script update-grub.
Searching for GRUB installation directory ... found: /boot/grub
Searching for default file ... found: /boot/grub/default
Testing for an existing GRUB menu.lst file ... found: /boot/grub/menu.lst
Searching for splash image ... none found, skipping ...
Found kernel: /vmlinuz-2.6.28.4-custom
Found kernel: /vmlinuz-2.6.27-11-generic
Found kernel: /vmlinuz-2.6.27-7-generic
Found kernel: /memtest86+.bin
Updating /boot/grub/menu.lst ... done

Examining /etc/kernel/postinst.d.
run-parts: executing /etc/kernel/postinst.d/dkms
run-parts: executing /etc/kernel/postinst.d/nvidia-common
run-parts: /etc/kernel/postinst.d/nvidia-common exited with return code 20
Failed to process /etc/kernel/postinst.d at /var/lib/dpkg/info/linux-image-2.6.28.4-custom.postinst line 1181.
dpkg: error processing linux-image-2.6.28.4-custom (--configure):
subprocess post-installation script returned error exit status 2
Setting up hal-info (20090128-0ubuntu1~intrepid2) ...
Errors were encountered while processing:
linux-image-2.6.28.4-custom
E: Sub-process /usr/bin/dpkg returned an error code (1)

1 条评论:

  1. 哈哈,赶潮流你……
    我用Ubuntu这么久了,还真没手动编译过内核,算是一大失败
    学习学习

    你的博客已经加入我的友情链接

    回复删除