unable to remove old kernels
I used janitor, synaptic and terminal using this method:
http://www.liberiangeek.net/2011/11/...neiric-ocelot/
It is not for the pangolin, but it should work. Right? And, no, I did not remove the current 24 kernel. ;)
Here is what happened when I tried to remove those using 3 different ways.
I think there is something wrong with my system (I ran into some fan issue and upgraded thinking that it would solve that), but who know what I did wrong! HELP!
pierre2@Pierre-Vancouver:~$ dpkg --list | grep linux-image
rc linux-image-2.6.35-28-generic 2.6.35-28.50 Linux kernel image for version 2.6.35 on x86/x86_64
rc linux-image-2.6.38-10-generic 2.6.38-10.46 Linux kernel image for version 2.6.38 on x86/x86_64
rc linux-image-2.6.38-11-generic 2.6.38-11.50 Linux kernel image for version 2.6.38 on x86/x86_64
rc linux-image-2.6.38-12-generic 2.6.38-12.51 Linux kernel image for version 2.6.38 on x86/x86_64
rH linux-image-2.6.38-13-generic 2.6.38-13.52 Linux kernel image for version 2.6.38 on x86/x86_64
rc linux-image-2.6.38-8-generic 2.6.38-8.42 Linux kernel image for version 2.6.38 on x86/x86_64
rH linux-image-3.0.0-14-generic 3.0.0-14.23 Linux kernel image for version 3.0.0 on x86/x86_64
rH linux-image-3.0.0-15-generic 3.0.0-15.26 Linux kernel image for version 3.0.0 on x86/x86_64
rH linux-image-3.0.0-16-generic 3.0.0-16.29 Linux kernel image for version 3.0.0 on x86/x86_64
rH linux-image-3.0.0-17-generic 3.0.0-17.30 Linux kernel image for version 3.0.0 on x86/x86_64
rH linux-image-3.0.0-19-generic 3.0.0-19.33 Linux kernel image for version 3.0.0 on x86/x86_64
rH linux-image-3.0.0-20-generic 3.0.0-20.34 Linux kernel image for version 3.0.0 on x86/x86_64
rH linux-image-3.0.0-21-generic 3.0.0-21.35 Linux kernel image for version 3.0.0 on x86/x86_64
rH linux-image-3.0.0-22-generic 3.0.0-22.36 Linux kernel image for version 3.0.0 on x86/x86_64
rH linux-image-3.0.0-23-generic 3.0.0-23.39 Linux kernel image for version 3.0.0 on x86/x86_64
ii linux-image-3.0.0-24-generic 3.0.0-24.40 Linux kernel image for version 3.0.0 on x86/x86_64
iF linux-image-3.2.0-29-generic 3.2.0-29.46 Linux kernel image for version 3.2.0 on 32 bit x86 SMP
iU linux-image-generic 3.2.0.29.31 Generic Linux kernel image
pierre2@Pierre-Vancouver:~$ sudo apt-get purge linux-image-2.6.35-28-generic
[sudo] password for pierre2:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
linux-image-2.6.35-28-generic* linux-image-2.6.38-13-generic linux-image-3.0.0-14-generic
linux-image-3.0.0-15-generic linux-image-3.0.0-16-generic linux-image-3.0.0-17-generic
linux-image-3.0.0-19-generic linux-image-3.0.0-20-generic linux-image-3.0.0-21-generic
linux-image-3.0.0-22-generic linux-image-3.0.0-23-generic
0 upgraded, 0 newly installed, 11 to remove and 0 not upgraded.
17 not fully installed or removed.
After this operation, 1,167 MB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 280841 files and directories currently installed.)
Removing linux-image-2.6.38-13-generic ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 2.6.38-13-generic /boot/vmlinuz-2.6.38-13-generic
update-initramfs: Deleting /boot/initrd.img-2.6.38-13-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 2.6.38-13-generic /boot/vmlinuz-2.6.38-13-generic
/usr/sbin/grub-mkconfig: 11: /etc/default/grub: splash: not found
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-2.6.38-13-generic.postrm line 328.
dpkg: error processing linux-image-2.6.38-13-generic (--remove):
subprocess installed post-removal script returned error exit status 1
No apport report written because MaxReports is reached already
Removing linux-image-3.0.0-14-generic ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 3.0.0-14-generic /boot/vmlinuz-3.0.0-14-generic
update-initramfs: Deleting /boot/initrd.img-3.0.0-14-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 3.0.0-14-generic /boot/vmlinuz-3.0.0-14-generic
/usr/sbin/grub-mkconfig: 11: /etc/default/grub: splash: not found
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-3.0.0-14-generic.postrm line 328.
dpkg: error processing linux-image-3.0.0-14-generic (--remove):
subprocess installed post-removal script returned error exit status 1
No apport report written because MaxReports is reached already
Removing linux-image-3.0.0-15-generic ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 3.0.0-15-generic /boot/vmlinuz-3.0.0-15-generic
update-initramfs: Deleting /boot/initrd.img-3.0.0-15-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 3.0.0-15-generic /boot/vmlinuz-3.0.0-15-generic
/usr/sbin/grub-mkconfig: 11: /etc/default/grub: splash: not found
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-3.0.0-15-generic.postrm line 328.
dpkg: error processing linux-image-3.0.0-15-generic (--remove):
subprocess installed post-removal script returned error exit status 1
No apport report written because MaxReports is reached already
Removing linux-image-3.0.0-16-generic ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 3.0.0-16-generic /boot/vmlinuz-3.0.0-16-generic
update-initramfs: Deleting /boot/initrd.img-3.0.0-16-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 3.0.0-16-generic /boot/vmlinuz-3.0.0-16-generic
/usr/sbin/grub-mkconfig: 11: /etc/default/grub: splash: not found
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-3.0.0-16-generic.postrm line 328.
dpkg: error processing linux-image-3.0.0-16-generic (--remove):
subprocess installed post-removal script returned error exit status 1
No apport report written because MaxReports is reached already
Removing linux-image-3.0.0-17-generic ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 3.0.0-17-generic /boot/vmlinuz-3.0.0-17-generic
update-initramfs: Deleting /boot/initrd.img-3.0.0-17-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 3.0.0-17-generic /boot/vmlinuz-3.0.0-17-generic
/usr/sbin/grub-mkconfig: 11: /etc/default/grub: splash: not found
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-3.0.0-17-generic.postrm line 328.
dpkg: error processing linux-image-3.0.0-17-generic (--remove):
subprocess installed post-removal script returned error exit status 1
No apport report written because MaxReports is reached already
Removing linux-image-3.0.0-19-generic ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 3.0.0-19-generic /boot/vmlinuz-3.0.0-19-generic
update-initramfs: Deleting /boot/initrd.img-3.0.0-19-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 3.0.0-19-generic /boot/vmlinuz-3.0.0-19-generic
/usr/sbin/grub-mkconfig: 11: /etc/default/grub: splash: not found
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-3.0.0-19-generic.postrm line 328.
dpkg: error processing linux-image-3.0.0-19-generic (--remove):
subprocess installed post-removal script returned error exit status 1
No apport report written because MaxReports is reached already
Removing linux-image-3.0.0-20-generic ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 3.0.0-20-generic /boot/vmlinuz-3.0.0-20-generic
update-initramfs: Deleting /boot/initrd.img-3.0.0-20-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 3.0.0-20-generic /boot/vmlinuz-3.0.0-20-generic
/usr/sbin/grub-mkconfig: 11: /etc/default/grub: splash: not found
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-3.0.0-20-generic.postrm line 328.
dpkg: error processing linux-image-3.0.0-20-generic (--remove):
subprocess installed post-removal script returned error exit status 1
No apport report written because MaxReports is reached already
Removing linux-image-3.0.0-21-generic ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 3.0.0-21-generic /boot/vmlinuz-3.0.0-21-generic
update-initramfs: Deleting /boot/initrd.img-3.0.0-21-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 3.0.0-21-generic /boot/vmlinuz-3.0.0-21-generic
/usr/sbin/grub-mkconfig: 11: /etc/default/grub: splash: not found
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-3.0.0-21-generic.postrm line 328.
dpkg: error processing linux-image-3.0.0-21-generic (--remove):
subprocess installed post-removal script returned error exit status 1
No apport report written because MaxReports is reached already
Removing linux-image-3.0.0-22-generic ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 3.0.0-22-generic /boot/vmlinuz-3.0.0-22-generic
update-initramfs: Deleting /boot/initrd.img-3.0.0-22-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 3.0.0-22-generic /boot/vmlinuz-3.0.0-22-generic
/usr/sbin/grub-mkconfig: 11: /etc/default/grub: splash: not found
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-3.0.0-22-generic.postrm line 328.
dpkg: error processing linux-image-3.0.0-22-generic (--remove):
subprocess installed post-removal script returned error exit status 1
No apport report written because MaxReports is reached already
Removing linux-image-3.0.0-23-generic ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 3.0.0-23-generic /boot/vmlinuz-3.0.0-23-generic
update-initramfs: Deleting /boot/initrd.img-3.0.0-23-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 3.0.0-23-generic /boot/vmlinuz-3.0.0-23-generic
/usr/sbin/grub-mkconfig: 11: /etc/default/grub: splash: not found
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-3.0.0-23-generic.postrm line 328.
dpkg: error processing linux-image-3.0.0-23-generic (--remove):
subprocess installed post-removal script returned error exit status 1
No apport report written because MaxReports is reached already
Errors were encountered while processing:
linux-image-2.6.38-13-generic
linux-image-3.0.0-14-generic
linux-image-3.0.0-15-generic
linux-image-3.0.0-16-generic
linux-image-3.0.0-17-generic
linux-image-3.0.0-19-generic
linux-image-3.0.0-20-generic
linux-image-3.0.0-21-generic
linux-image-3.0.0-22-generic
linux-image-3.0.0-23-generic
N: Ignoring file 'google.listgksu' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
N: Ignoring file 'google.listgksu' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
E: Sub-process /usr/bin/dpkg returned an error code (1)
pierre2@Pierre-Vancouver:~$
Re: unable to remove old kernels
Install Ubuntu Tweak and use it to get rid of the old kernels.
Re: unable to remove old kernels
I generally just use Synaptics to locate and delete but Ubuntu Tweak would work. Might give that a try myself. ;)
1 Attachment(s)
Re: unable to remove old kernels
Thank you, Lindsay and Bucky!
I forgot about Tweaks. I tried and this is what I got (see attachment)! When I tried to install it anyway, it froze partly through the install!
Any other ideas?
I think I copied a root command (i) and must have messed up enough things to make my system not work well, when I realized I had my fan was not working.
I am just thinking to reinstall everything, but I would like to keep my skype audio and video settings/drivers (because I had some initial problems with those last time). I took screen shots of the chosen settings.
Any advice?
Re: unable to remove old kernels
I was given this answer for this same issue in 10.04, but it works the same with 12.04:
¨Check this article (video included) for the details on how to do it.¨
Re: unable to remove old kernels
Quote:
Originally Posted by
hank22077
I was given this answer for this same issue in 10.04, but it works the same with 12.04:
¨Check this
article (video included) for the details on how to do it.¨
Oh! Thanks a lot! Well! I like the idea that I did not have ton do a compete removal, but as I went into synaptic it told me that I needed to do sudo dpkg-configure-a, but terminal did not know what that was! :) I am enable to do anything, install new programs,...
I think my systems is so messed up that a clean install of a new system, with a window partition to boot might resolve my fan issue and make my system run smoother! :)
Thanks!
I will p;ost in a few days with a post or not! :)
Re: unable to remove old kernels
Give that a go.
Notes: Delete partitions; install Windows first on its own partition using the tools in the Windows install; once Win is installed rest of disk should be free space; install Ubuntu using the free space either automatically or manually partition by choosing 'Something Else'.
If you want to share data between Win and Ubuntu you are going to need a share partition, either NTFS or FAT. This might be helpful:
http://members.iinet.net/~herman546/index.html
Re: unable to remove old kernels
Quote:
Originally Posted by
Bucky Ball
Give that a go.
Notes: Delete partitions; install Windows first on its own partition using the tools in the Windows install; once Win is installed rest of disk should be free space; install Ubuntu using the free space either automatically or manually partition by choosing 'Something Else'.
If you want to share data between Win and Ubuntu you are going to need a share partition, either NTFS or FAT. This might be helpful:
http://members.iinet.net/~herman546/index.html
Oh! Thanks! That should prove invaluable! Thanks!
Re: unable to remove old kernels
Quote:
Originally Posted by
pierreu1
I think I copied a root command (i) and must have messed up enough things to make my system not work well, when I realized I had my fan was not working.
Code:
N: Ignoring file 'google.listgksu' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
Remove that file or rename it properly (the right extension is .list) and then run apt-get update.
Quote:
Originally Posted by
pierreu1
as I went into synaptic it told me that I needed to do sudo dpkg-configure-a, but terminal did not know what that was!
that would be becasue there's supposed to be a space in the command:
Code:
sudo dpkg-configure -a
Re: unable to remove old kernels
Quote:
Originally Posted by
mcduck
Code:
N: Ignoring file 'google.listgksu' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
Remove that file or rename it properly (the right extension is .list) and then run apt-get update.
that would be becasue there's supposed to be a space in the command:
Code:
sudo dpkg-configure -a
Oh! Thanks! I tried both codes and they did not work!
N: Ignoring file 'google.listgksu' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
sudo dpkg-configure -a
Strange!
My system is really screwed! :)