当前时区为 UTC + 8 小时



发表新帖 回复这个主题  [ 3 篇帖子 ] 
作者 内容
1 楼 
 文章标题 : 怎么删除不了这个内核的东西
帖子发表于 : 2009-04-10 22:28 
头像

注册: 2007-11-23 12:54
帖子: 100
送出感谢: 0 次
接收感谢: 0 次
rodren@rodren:~$ sudo aptitude purge ~ilinux-image-.*\(\!`uname -r`\)
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
Writing extended state information... Done
The following packages are BROKEN:
linux-restricted-modules-2.6.27-9-generic
The following packages will be REMOVED:
linux-image-2.6.27-7-generic{ap} linux-image-2.6.27-9-generic{p}
linux-image-generic{p}
0 packages upgraded, 0 newly installed, 3 to remove and 135 not upgraded.
Need to get 0B of archives. After unpacking 189MB will be freed.
The following packages have unmet dependencies:
linux-restricted-modules-2.6.27-9-generic: Depends: linux-image-2.6.27-9-generic but it is not installable
The following actions will resolve these dependencies:

Remove the following packages:
linux-restricted-modules-2.6.27-9-generic
linux-restricted-modules-generic

Score is 188

Accept this solution? [Y/n/q/?] y
The following packages will be REMOVED:
linux-image-2.6.27-7-generic{ap} linux-image-2.6.27-9-generic{p}
linux-image-generic{p} linux-restricted-modules-2.6.27-9-generic{a}
linux-restricted-modules-generic{a}
0 packages upgraded, 0 newly installed, 5 to remove and 134 not upgraded.
Need to get 0B of archives. After unpacking 191MB will be freed.
Do you want to continue? [Y/n/?] y
Writing extended state information... Done
(Reading database ... 115710 files and directories currently installed.)
Removing linux-image-2.6.27-7-generic ...
Running postrm hook script /sbin/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: /boot/vmlinuz-2.6.27-12-generic
Found kernel: /boot/vmlinuz-2.6.27-9-generic
Found kernel: /boot/memtest86+.bin
Replacing config file /var/run/grub/menu.lst with new version
Updating /boot/grub/menu.lst ... done

Purging configuration files for linux-image-2.6.27-7-generic ...
Running postrm hook script /sbin/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: /boot/vmlinuz-2.6.27-12-generic
Found kernel: /boot/vmlinuz-2.6.27-9-generic
Found kernel: /boot/memtest86+.bin
Updating /boot/grub/menu.lst ... done

rmdir: failed to remove `/lib/modules/2.6.27-7-generic': Directory not empty

dpkg - warning: while removing linux-image-2.6.27-7-generic, directory `/lib/modules/2.6.27-7-generic' not empty so not removed.
Removing linux-image-generic ...
(Reading database ... 115706 files and directories currently installed.)
Removing linux-restricted-modules-generic ...
Removing linux-restricted-modules-2.6.27-9-generic ...
update-initramfs: Generating /boot/initrd.img-2.6.27-9-generic
(Reading database ... 115645 files and directories currently installed.)
Removing linux-image-2.6.27-9-generic ...
Examining /etc/kernel/prerm.d.
run-parts: executing /etc/kernel/prerm.d/last-good-boot
Running postrm hook script /sbin/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: /boot/vmlinuz-2.6.27-12-generic
Found kernel: /boot/memtest86+.bin
Replacing config file /var/run/grub/menu.lst with new version
Updating /boot/grub/menu.lst ... done

The link /vmlinuz.old is a damaged link
Removing symbolic link vmlinuz.old
you may need to re-run your boot loader[grub]
The link /initrd.img.old is a damaged link
Removing symbolic link initrd.img.old
you may need to re-run your boot loader[grub]
Purging configuration files for linux-image-2.6.27-9-generic ...
Running postrm hook script /sbin/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: /boot/vmlinuz-2.6.27-12-generic
Found kernel: /boot/memtest86+.bin
Updating /boot/grub/menu.lst ... done

rmdir: failed to remove `/lib/modules/2.6.27-9-generic': Directory not empty

Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
Writing extended state information... Done

Current status: 134 updates [-2].

看红色部分
为什么会这样
代码:
rodren@rodren:~$ dpkg --get-selections|grep linux
libselinux1               install
linux-firmware               install
linux-headers-2.6.27-9            install
linux-headers-2.6.27-9-generic         install
linux-headers-generic            install
linux-image-2.6.27-12-generic         install
linux-libc-dev               install
linux-restricted-modules-2.6.27-12-generic   install
linux-restricted-modules-2.6.27-7-generic   deinstall
linux-restricted-modules-2.6.27-9-generic   deinstall
linux-restricted-modules-common         install
linux-sound-base            install
linuxfetion               install
syslinux               install
util-linux               install
rodren@rodren:~$


页首
 用户资料  
 
2 楼 
 文章标题 : Re: 怎么删除不了这个内核的东西
帖子发表于 : 2009-04-11 17:19 
头像

注册: 2005-10-25 13:54
帖子: 272
送出感谢: 0 次
接收感谢: 0 次
linux-restricted-modules-2.6.27-9-generic 已损坏,请先卸掉他。出错的原因是因为/lib/modules/2.6.27-9-generic目录非空。也就是说损坏的linux-restricted-modules-2.6.27-9-generic并没有被卸掉或者是有残留文件存在。导致卸载失败。请先修复linux-restricted-modules-2.6.27-9-generic,然后卸掉linux-restricted-modules-2.6.27-7-generic.最后卸掉内核。


_________________
Full Circle中文杂志 | Ubuntu社区独立发行的电子月刊
http://www.freeearth.org.cn


页首
 用户资料  
 
3 楼 
 文章标题 : Re: 怎么删除不了这个内核的东西
帖子发表于 : 2009-04-14 11:40 
头像

注册: 2007-11-23 12:54
帖子: 100
送出感谢: 0 次
接收感谢: 0 次
谢谢LS


页首
 用户资料  
 
显示帖子 :  排序  
发表新帖 回复这个主题  [ 3 篇帖子 ] 

当前时区为 UTC + 8 小时


在线用户

正在浏览此版面的用户:没有注册用户 和 4 位游客


不能 在这个版面发表主题
不能 在这个版面回复主题
不能 在这个版面编辑帖子
不能 在这个版面删除帖子
不能 在这个版面提交附件

前往 :  
本站点为公益性站点,用于推广开源自由软件,由 DiaHosting VPSBudgetVM VPS 提供服务。
我们认为:软件应可免费取得,软件工具在各种语言环境下皆可使用,且不会有任何功能上的差异;
人们应有定制和修改软件的自由,且方式不受限制,只要他们自认为合适。

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
简体中文语系由 王笑宇 翻译