shuxinwei@ubuntu:~$ uname -r
shuxinwei@ubuntu:~$ uname -r
2.6.35-28-generic
Command 2 :列出所有安装的内核
shuxinwei@ubuntu:~$ dpkg --get-selections|grep linux
shuxinwei@ubuntu:~$ dpkg --get-selections|grep linux
libselinux1 install
linux-firmware install
linux-generic install
linux-headers-2.6.35-22 install
linux-headers-2.6.35-22-generic install
linux-headers-2.6.35-28 install
linux-headers-2.6.35-28-generic install
linux-headers-generic install
linux-image-2.6.35-22-generic install
linux-image-2.6.35-28-generic install
linux-image-generic install
linux-libc-dev install
linux-sound-base install
pptp-linux install
syslinux install
syslinux-common install
util-linux install
Command 3 :删除旧版本内核
shuxinwei@ubuntu:~$ sudo apt-get remove linux-image-2.6.35.22-generic
shuxinwei@ubuntu:~$ sudo apt-get remove linux-image-2.6.35.22-generic
[sudo] password for shuxinwei:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'linux-image-2.6.35-22-generic' for regex 'linux-image-2.6.35.22-generic'
Note, selecting 'linux-image-2.6.35-22-generic-pae' for regex 'linux-image-2.6.35.22-generic'
Package linux-image-2.6.35-22-generic-pae is not installed, so not removed
The following packages will be REMOVED:
linux-image-2.6.35-22-generic
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
After this operation, 107MB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 144479 files and directories currently installed.)
Removing linux-image-2.6.35-22-generic ...
Examining /etc/kernel/prerm.d.
run-parts: executing /etc/kernel/prerm.d/dkms 2.6.35-22-generic /boot/vmlinuz-2.6.35-22-generic
dkms: uninstalling: fglrx 8.780 (2.6.35-22-generic) (i686)
-------- Uninstall Beginning --------
Module: fglrx
Version: 8.780
Kernel: 2.6.35-22-generic (i686)
-------------------------------------
Status: Before uninstall, this module version was ACTIVE on this kernel.
fglrx.ko:
- Uninstallation
- Deleting from: /lib/modules/2.6.35-22-generic/updates/dkms/
- Original module
- No original module was found for this module on this kernel.
- Use the dkms install command to reinstall any previous module version.
depmod......
DKMS: uninstall Completed.
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 2.6.35-22-generic /boot/vmlinuz-2.6.35-22-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 2.6.35-22-generic /boot/vmlinuz-2.6.35-22-generic
Generating grub.cfg ...
cat: /boot/grub/video.lst: No such file or directory
Found linux image: /boot/vmlinuz-2.6.35-28-generic
Found initrd image: /boot/initrd.img-2.6.35-28-generic
Found Windows 7 (loader) on /dev/sda1
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]

没有评论:
发表评论