我需要一些帮助来解决这个问题。我运行了以下命令。
wbmc@wbmc-ThinkPad-R51:~$ sudo apt-get update
Fetched 674 kB in 4s (141 kB/s)
Reading package lists... Done
wbmc@wbmc-ThinkPad-R51:~$ sudo apt-get clean
wbmc@wbmc-ThinkPad-R51:~$ sudo apt-get -f remove linux-image-generic
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
linux-generic : Depends: linux-image-generic (= 3.8.0.27.45) but it is not going to be installed
linux-image-extra-3.8.0-27-generic : Depends: linux-image-3.8.0-27-generic but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
wbmc@wbmc-ThinkPad-R51:~$ sudo apt-get -f remove linux-image-extra-3.8.0-27-generic
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
linux-image-generic : Depends: linux-image-3.8.0-27-generic but it is not going to be installed
Depends: linux-image-extra-3.8.0-27-generic but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
wbmc@wbmc-ThinkPad-R51:~$ sudo apt-get autoremove
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
linux-image-extra-3.8.0-27-generic : Depends: linux-image-3.8.0-27-generic but it is not installed
linux-image-generic : Depends: linux-image-3.8.0-27-generic but it is not installed
E: Unmet dependencies. Try using -f.
wbmc@wbmc-ThinkPad-R51:~$ sudo apt-get -f install
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
libavahi-ui-gtk3-0 libblas3gf libcelt0-0 libfm-gtk1 libfm1 libgdu-gtk0
libgrail5 libkms1 libllvm3.1 libmenu-cache1 libmjpegtools-1.9 libntfs10
libopencv-calib3d2.3 libopencv-core2.3 libopencv-features2d2.3
libopencv-flann2.3 libopencv-highgui2.3 libopencv-imgproc2.3
libopencv-objdetect2.3 libopenspc0 libqpdf8 libsox1b libtbb2 libunique-3.0-0
libwebp2 libx264-120 linux-headers-3.5.0-37 linux-headers-3.5.0-37-generic
python3.2 python3.2-minimal
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
linux-image-3.8.0-27-generic
Suggested packages:
fdutils linux-doc-3.8.0 linux-source-3.8.0 linux-tools
The following NEW packages will be installed:
linux-image-3.8.0-27-generic
0 upgraded, 1 newly installed, 0 to remove and 29 not upgraded.
3 not fully installed or removed.
Need to get 12.1 MB of archives.
After this operation, 26.7 MB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://us.archive.ubuntu.com/ubuntu/ raring-updates/main linux-image-3.8.0-27-generic i386 3.8.0-27.40 [12.1 MB]
Fetched 12.1 MB in 15s (794 kB/s)
(Reading database ... 333748 files and directories currently installed.)
Unpacking linux-image-3.8.0-27-generic (from .../linux-image-3.8.0-27-generic_3.8.0-27.40_i386.deb) ...
This kernel does not support a non-PAE CPU.
dpkg: error processing /var/cache/apt/archives/linux-image-3.8.0-27-generic_3.8.0-27.40_i386.deb (--unpack):
subprocess new pre-installation script returned error exit status 1
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 3.8.0-27-generic /boot/vmlinuz-3.8.0-27-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 3.8.0-27-generic /boot/vmlinuz-3.8.0-27-generic
Errors were encountered while processing:
/var/cache/apt/archives/linux-image-3.8.0-27-generic_3.8.0-27.40_i386.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
wbmc@wbmc-ThinkPad-R51:~$ sudo apt-get install linux-image-486
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package linux-image-486
wbmc@wbmc-ThinkPad-R51:~$ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
linux-image-extra-3.8.0-27-generic : Depends: linux-image-3.8.0-27-generic but it is not installed
linux-image-generic : Depends: linux-image-3.8.0-27-generic but it is not installed
E: Unmet dependencies. Try using -f.
wbmc@wbmc-ThinkPad-R51:~$ cat /etc/apt/sources.list
# deb cdrom:[Xubuntu 12.04 LTS _Precise Pangolin_ - Release i386 (20120423)]/ precise main multiverse restricted universe
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb cdrom:[Ubuntu 13.04 _Raring Ringtail_ - Release i386 (20130424)]/ raring main restricted
deb http://us.archive.ubuntu.com/ubuntu/ raring main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ raring main restricted
## Major bug fix updates produced after the final release of the
## distribution.
deb http://us.archive.ubuntu.com/ubuntu/ raring-updates main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ raring-updates main restricted
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://us.archive.ubuntu.com/ubuntu/ raring universe
deb-src http://us.archive.ubuntu.com/ubuntu/ raring universe
deb http://us.archive.ubuntu.com/ubuntu/ raring-updates universe
deb-src http://us.archive.ubuntu.com/ubuntu/ raring-updates universe
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://us.archive.ubuntu.com/ubuntu/ raring multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ raring multiverse
deb http://us.archive.ubuntu.com/ubuntu/ raring-updates multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ raring-updates multiverse
## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://security.ubuntu.com/ubuntu raring-security main restricted
deb-src http://security.ubuntu.com/ubuntu raring-security main restricted
deb http://security.ubuntu.com/ubuntu raring-security universe
deb-src http://security.ubuntu.com/ubuntu raring-security universe
deb http://security.ubuntu.com/ubuntu raring-security multiverse
deb-src http://security.ubuntu.com/ubuntu raring-security multiverse
## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
# deb http://archive.canonical.com/ubuntu precise partner
# deb-src http://archive.canonical.com/ubuntu precise partner
## This software is not part of Ubuntu, but is offered by third-party
## developers who want to ship their latest software.
# deb http://extras.ubuntu.com/ubuntu quantal main
# deb-src http://extras.ubuntu.com/ubuntu quantal main
答案1
你的 CPU 不支持 PAE(物理地址扩展) 内核,因此任何安装linux-image-*-generic
都会失败。因此,让我们开始纠正软件包依赖关系:
sudo apt-get update
sudo apt-get clean
sudo apt-get -f remove linux-image-generic
sudo apt-get -f remove linux-image-extra-3.8.0-27-generic
sudo apt-get autoremove
sudo apt-get -f install
sudo apt-get install linux-image-486
sudo apt-get upgrade
这应该会删除有问题的软件包(linux-image-extra-3.8.0-27-generic
)并为您提供干净的树依赖关系。linux-image-486
最新的非 PAE 内核的依赖项。
如何知道你的 CPU 是否支持 PAE
PAE 是一种允许 32 位 CPU 访问大于 4 GB 的物理地址空间的方法。这意味着您不需要 64 位 CPU 即可使用超过 3.something GB 的 RAM。发现您的 CPU 是否支持 PAE 的最佳方法是:
cat /proc/cpuinfo | grep --color pae
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm constant_tsc pebs bts pni dtes64 monitor ds_cpl tm2 cid cx16 xtpr
^^^
否则,它将返回到提示。