Обновите Ubuntu 10.10 до 14.04.3, не распознавая новую установку python 2.7.9

Я использую Ubuntu 14.04.3 LTS на сервере Dell T410, обновив его с 10.10 (Maverick) ранее сегодня. По большей части обновление прошло хорошо, но у меня возникли некоторые трудности при использовании apt-get upgrade. Вот точная ошибка, которую я получаю:

tom@smckay1:~$ 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:
 gconf2 : Depends: python:any
 python-httplib2 : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                   Depends: python:any (>= 2.7.1-0ubuntu2)
 python-lazr.restfulclient : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                             Depends: python:any (>= 2.7.1-0ubuntu2)
 python-lazr.uri : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                   Depends: python:any (>= 2.7.1-0ubuntu2)
 python-pyatspi : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                  Depends: python:any (>= 2.7.1-0ubuntu2)
                  Depends: python-gi (>= 2.90.1)
                  Depends: gir1.2-atspi-2.0 (>= 2.9.90) but it is not installed
                  Depends: libatk-adaptor but it is not installed
 python-simplejson : Depends: python (>= 2.7~) but 2.6.6-2ubuntu2 is installed
                     Depends: python:any (>= 2.7.5-5~)
 python-twisted-bin : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
 python-twisted-core : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                       Depends: python:any (>= 2.7.1-0ubuntu2)
 python-twisted-names : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                        Depends: python:any (>= 2.7.1-0ubuntu2)
 python-zope.interface : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                         Depends: python:any (>= 2.7.1-0ubuntu2)
E: Unmet dependencies. Try using -f.

Я пробовал несколько реализаций apt-get install -f, apt-get clean, apt-get autoremove и других подобных мер. Тем не менее, я продолжаю получать ту же ошибку, и в результате не могу установить какие-либо новые пакеты.

Вот моя копия /etc/apt/sources.list с удаленными комментариями. Я признаю, что перед обновлением я редактировал этот файл, добавив в него «надежный» вместо «ясный», когда обновлял ОС с 10.10 до 14.04.

#deb cdrom:[Ubuntu 10.10 _Maverick Meerkat_ - Release amd64 (20101007.1)]/ trusty main restricted

deb http://us.archive.ubuntu.com/ubuntu/ trusty main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty main restricted

deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty-updates main restricted

deb http://us.archive.ubuntu.com/ubuntu/ trusty universe
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty universe
deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates universe
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty-updates universe

deb http://us.archive.ubuntu.com/ubuntu/ trusty multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty multiverse
deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty-updates multiverse

deb http://extras.ubuntu.com/ubuntu trusty main
deb-src http://extras.ubuntu.com/ubuntu trusty main

deb http://security.ubuntu.com/ubuntu trusty-security main restricted
deb-src http://security.ubuntu.com/ubuntu trusty-security main restricted
deb http://security.ubuntu.com/ubuntu trusty-security universe
deb-src http://security.ubuntu.com/ubuntu trusty-security universe
deb http://security.ubuntu.com/ubuntu trusty-security multiverse
deb-src http://security.ubuntu.com/ubuntu trusty-security multiverse
deb http://us.archive.ubuntu.com/ubuntu/ trusty main
deb http://security.ubuntu.com/ubuntu/ trusty-security main
deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates main
deb http://us.archive.ubuntu.com/ubuntu/ trusty-proposed main

Вот вывод apt-cache policy python:

$ apt-cache policy python
python:
  Installed: 2.6.6-2ubuntu2
  Candidate: 2.7.5-5ubuntu3
  Version table:
     2.7.5-5ubuntu3 0
        500 http://us.archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages
 *** 2.6.6-2ubuntu2 0
        100 /var/lib/dpkg/status   

Я установил Python 2.7.9 с помощью этих команд:

cd ~/Downloads/
wget https://www.python.org/ftp/python/2.7.9/Python-2.7.9.tgz
tar -xvf Python-2.7.9.tgz
cd Python-2.7.9
./configure
make
sudo make install

Теперь python -V сообщает мне что у меня установлена ​​версия 2.7.9, но apt-get этого не видит. В связи с этим во время обновления во время выполнения команды do-release-upgrade я получил следующую ошибку:

Traceback (most recent call last):
 File "/usr/bin/do-release-upgrade", line 10, in <module>
 from UpdateManager.Core.DistUpgradeFetcherCore import      DistUpgradeFetcherCore
 File "/usr/lib/python2.6/dist-packages/UpdateManager   /Core/DistUpgradeFetcherCore.py", line 34, in <module>
  import GnuPGInterface
ImportError: No module named GnuPGInterface
Error in sys.excepthook:
Traceback (most recent call last):
File "/usr/lib/python2.6/dist-packages/apport_python_hook.py", line 105,  in apport_excepthook
 os.O_WRONLY|os.O_CREAT|os.O_EXCL, 0600), 'w')
OSError: [Errno 2] No such file or directory: '/var/crash/_usr_bin_do-   release-upgrade.1001.crash'

Первоначальное исключение было:

Traceback (most recent call last):
File "/usr/bin/do-release-upgrade", line 10, in <module>
from UpdateManager.Core.DistUpgradeFetcherCore import    DistUpgradeFetcherCore
 File "/usr/lib/python2.6/dist-packages/UpdateManager/Core/DistUpgradeFetcherCore.py", line 34, in <module>
  import GnuPGInterface
 ImportError: No module named GnuPGInterface

Однако sudo apt-get update и обновление в конечном итоге оставило меня с Ubuntu 14.04 как-то.

1135 Кто-нибудь знает, что делать, чтобы решить эту проблему? Я очень ценю вашу помощь.

Выходные данные из sudo apt-get install -f:

tom@smckay1:~$ sudo apt-get install -f
[sudo] password for tom:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... failed.
The following packages have unmet dependencies:
 gconf2 : Depends: python:any
 python-httplib2 : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                   Depends: python:any (>= 2.7.1-0ubuntu2)
 python-lazr.restfulclient : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                            Depends: python:any (>= 2.7.1-0ubuntu2)
 python-lazr.uri : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                   Depends: python:any (>= 2.7.1-0ubuntu2)
 python-pyatspi : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                  Depends: python:any (>= 2.7.1-0ubuntu2)
                  Depends: python-gi (>= 2.90.1)
                  Depends: gir1.2-atspi-2.0 (>= 2.9.90) but it is not installed
                  Depends: libatk-adaptor but it is not installed
 python-simplejson : Depends: python (>= 2.7~) but 2.6.6-2ubuntu2 is installed
                     Depends: python:any (>= 2.7.5-5~)
 python-twisted-bin : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
 python-twisted-core : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                       Depends: python:any (>= 2.7.1-0ubuntu2)
 python-twisted-names : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                        Depends: python:any (>= 2.7.1-0ubuntu2)
 python-zope.interface : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is installed
                         Depends: python:any (>= 2.7.1-0ubuntu2)
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.
E: Unable to correct dependencies

Выходные данные sudo apt-get install -f python:

tom@smckay1:~$ sudo apt-get install -f python
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:
 command-not-found : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 computer-janitor : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 computer-janitor-gtk : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 hplip : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
         Recommends: sane-utils but it is not going to be installed
 jockey-common : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 language-selector-common : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 lsb-release : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 nvidia-common : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python : Depends: python2.7 (>= 2.7.5-1~) but it is not going to be installed
          Depends: python-minimal (= 2.7.5-5ubuntu3) but 2.6.6-2ubuntu2 is to be installed
          Depends: libpython-stdlib (= 2.7.5-5ubuntu3) but it is not going to be installed
 python-appindicator : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-apport : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-apt : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-aptdaemon : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
                    Recommends: aptdaemon but it is not going to be installed
 python-aptdaemon-gtk : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-brlapi : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-cairo : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-crypto : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-cups : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-dbus : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-egenix-mxdatetime : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-egenix-mxtools : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-gconf : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-glade2 : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-gmenu : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-gnomeapplet : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-gnomecanvas : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-gnomekeyring : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-gobject : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-gobject-cairo : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-gtk2 : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-gtksourceview2 : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-gtkspell : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-imaging : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-indicate : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-launchpad-integration : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-libxml2 : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-markupsafe : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-newt : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-notify : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-openssl : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-pam : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-problem-report : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-pyatspi : Depends: python-gi (>= 2.90.1)
                  Depends: gir1.2-atspi-2.0 (>= 2.9.90) but it is not going to be installed
                  Depends: libatk-adaptor but it is not going to be installed
 python-pycurl : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-pygoocanvas : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-pyorbit : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-rdflib : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-smbc : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-software-properties : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-twisted-web : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-ubuntuone : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-uno : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-virtkey : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-vte : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-webkit : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-wnck : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 python-xapian : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 screen-resolution-extra : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 ubuntu-sso-client : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 ufw : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
 update-manager : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
                  Recommends: software-properties-gtk (>= 0.71.2) but it is not going to be installed
 update-manager-core : Depends: python (< 2.7) but 2.7.5-5ubuntu3 is to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

и dist-upgrade дают мне те же выходные данные, что и apt-get upgrade ( первый сегмент кода).

Вывод из apt-cache policy command-not-found:

command-not-found:
  Installed: 0.2.40ubuntu15
  Candidate: 0.3ubuntu12
  Version table:
     0.3ubuntu12 0
        500 http://us.archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages
 *** 0.2.40ubuntu15 0
        100 /var/lib/dpkg/status

Вот вывод из apt-get install command-not-found=0.3ubuntu12:

$ sudo apt-get install command-not-found=0.3ubuntu12
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:
 command-not-found : Depends: python3-commandnotfound (>= 0.3ubuntu7) but it is not going to be installed
 gconf2 : Depends: python:any
 python-httplib2 : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is to be installed
                   Depends: python:any (>= 2.7.1-0ubuntu2)
 python-lazr.restfulclient : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is to be installed
                             Depends: python:any (>= 2.7.1-0ubuntu2)
 python-lazr.uri : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is to be installed
                   Depends: python:any (>= 2.7.1-0ubuntu2)
 python-pyatspi : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is to be installed
                  Depends: python:any (>= 2.7.1-0ubuntu2)
                  Depends: python-gi (>= 2.90.1)
                  Depends: gir1.2-atspi-2.0 (>= 2.9.90) but it is not going to be installed
                  Depends: libatk-adaptor but it is not going to be installed
 python-simplejson : Depends: python (>= 2.7~) but 2.6.6-2ubuntu2 is to be installed
                     Depends: python:any (>= 2.7.5-5~)
 python-twisted-bin : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is to be installed
 python-twisted-core : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is to be installed
                       Depends: python:any (>= 2.7.1-0ubuntu2)
 python-twisted-names : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is to be installed
                        Depends: python:any (>= 2.7.1-0ubuntu2)
 python-zope.interface : Depends: python (>= 2.7) but 2.6.6-2ubuntu2 is to be installed
                         Depends: python:any (>= 2.7.1-0ubuntu2)
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

Вот вывод из apt-cache policy command-not-found:

$ apt-cache policy command-not-found
command-not-found:
  Installed: 0.2.40ubuntu15
  Candidate: 0.3ubuntu12
  Version table:
     0.3ubuntu12 0
        500 http://us.archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages
 *** 0.2.40ubuntu15 0
        100 /var/lib/dpkg/status

Спасибо за все отзывы.

4
задан 17 September 2015 в 10:51

1 ответ

Происходящий ответ

Сначала мы должны восстановить Вашу систему:

  • Первый проблематичный пакет command-not-found. Вам установили Точную версию. Поэтому запустите

    sudo apt-get dist-upgrade
    

    Это должно обновить пакет и некоторых других. С другой стороны, мы можем вызвать установку версии 0.3ubuntu12 через

    sudo apt-get install command-not-found=0.3ubuntu12
    

Команда

sudo make install

установки никакие пакеты. Поэтому apt не видьте установленную версию.

Если мы восстановили Вашу установку (поэтому отвечают происходящий), можно установить пакет позже следующим образом.

sudo apt-get install checkinstall
cd ~/Downloads/Python-2.7.9
sudo checkinstall
1
ответ дан 17 September 2015 в 20:51
  • 1
    Хм. Что относительно sudo modprobe r8168 и перезагрузка? – ThatGuy 5 December 2016 в 13:13

Другие вопросы по тегам:

Похожие вопросы: