无法安装软件包

无法安装软件包

我已经在 Windows 7 上安装了 Ubuntu 12.04。

我尝试使用终端安装 vim 编辑器,sudo apt-get install vim 但出现以下错误,无法安装软件包。不仅如此,我无法从终端或 Ubuntu 中心安装任何东西。我确信我的互联网连接良好,我可以浏览互联网。

这是我得到的错误:-

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 vim : Depends: vim-common (= 2:7.3.429-2ubuntu2) but 2:7.3.429-2ubuntu2.1 is to be installed
E: Unable to correct problems, you have held broken packages.

答案1

试试这个。只需按下键盘上的Ctrl+ Alt+T即可打开终端。打开后,运行以下命令:

sudo apt-get clean && sudo apt-get update
sudo apt-get upgrade
sudo apt-get install vim

相关内容