I have just updated the kernel, meaning I have two sets of kernel files at the moment; and I'd like to use the command line to remove the old one.
I'm aware that I can use
apt-show-versions to show which packages I have installed which are named
$ apt-show-versions -r linux* libselinux1/natty uptodate 2.0.96-1ubuntu2 linux-firmware/natty uptodate 1.52 linux-generic/natty uptodate 188.8.131.52.25 linux-headers-2.6.38-10/natty uptodate 2.6.38-10.46 linux-headers-2.6.38-10-generic/natty uptodate 2.6.38-10.46 linux-headers-2.6.38-8/natty uptodate 2.6.38-8.42 linux-headers-2.6.38-8-generic/natty uptodate 2.6.38-8.42 linux-headers-generic/natty uptodate 184.108.40.206.25 linux-image-2.6.38-10-generic/natty uptodate 2.6.38-10.46 linux-image-2.6.38-8-generic/natty uptodate 2.6.38-8.42 linux-image-generic/natty uptodate 220.127.116.11.25 linux-libc-dev/natty uptodate 2.6.38-10.46 linux-sound-base/natty uptodate 1.0.24+dfsg-0ubuntu1 pptp-linux/natty uptodate 1.7.2-6 syslinux/natty uptodate 2:4.02+dfsg-7ubuntu1 syslinux-common/natty uptodate 2:4.02+dfsg-7ubuntu1 util-linux/natty uptodate 2.17.2-9.1ubuntu4
From this I can see I have kernel files from
2.6.38-8 and from
Is there an apt command where I could specify something like 'version=2.6.38-8*'; and it lists all packages that match that version number (regardless of name)?
The reason I'm asking for this is that I'd like to be able to check if I have packages installed say with version
2.6.38-8* - but which do not start with
I'm not sure if there are such files now, but I'm pretty sure I've had this problem before, which is why now I always first search for
linux* in Synaptic, and then separately search for version number of the package I want to remove, and sort by installed, and remove all in one take. I'd just like to be able to do the same from the command line.