apt-get сломанные пакеты стек ламп [дубликаты]

На этот вопрос уже есть ответ:

В Ubuntu 13.04 я не могу установить какие-либо части стека LAMP из-за сломанных пакетов. Я пытался

sudo apt-get -f install php5
sudo apt-get --purge remove php5 
sudo apt-get autoremove 

, а также пытался установить все зависимости, перечисленные во всех перестановках порядка

sudo apt-get --fix-broken --ignore-hold install php5
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:
 php5 : Depends: libapache2-mod-php5 (>= 5.4.9-4ubuntu2) but it is not going to be installed or
             libapache2-mod-php5filter (>= 5.4.9-4ubuntu2) but it is not going to be installed or
             php5-cgi (>= 5.4.9-4ubuntu2) but it is not going to be installed or
             php5-fpm (>= 5.4.9-4ubuntu2) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

, хотелось бы немного постичь, я думаю, что это связано с Обновление дистрибутива

Редактирование: еще несколько выходных форм apt

root@ascension:/home/kevin# dpkg --configure -a
root@ascension:/home/kevin# apt-get install -f
Reading package lists... Done
Building dependency tree       
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
root@ascension:/home/kevin# apt-get install php5
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:
 php5 : Depends: libapache2-mod-php5 (>= 5.4.9-4ubuntu2) but it is not going to be     installed or
             libapache2-mod-php5filter (>= 5.4.9-4ubuntu2) but it is not going to be installed or
             php5-cgi (>= 5.4.9-4ubuntu2) but it is not going to be installed or
             php5-fpm (>= 5.4.9-4ubuntu2) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
root@ascension:/home/kevin# apt-get remove php5-fpm
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package 'php5-fpm' is not installed, so not removed
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
root@ascension:/home/kevin# apt-get remove php5-cgi
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package 'php5-cgi' is not installed, so not removed
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
root@ascension:/home/kevin# apt-get remove libapache2-mod-php5filter
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package 'libapache2-mod-php5filter' is not installed, so not removed
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
root@ascension:/home/kevin# apt-get install apache2
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:
apache2 : Depends: apache2-mpm-worker (= 2.2.22-6ubuntu5) but it is not going to be     installed or
                apache2-mpm-prefork (= 2.2.22-6ubuntu5) but it is not going to be installed or
                apache2-mpm-event (= 2.2.22-6ubuntu5) but it is not going to be installed or
                apache2-mpm-itk (= 2.2.22-6ubuntu5) but it is not going to be installed
       Depends: apache2.2-common (= 2.2.22-6ubuntu5) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

Редактирование, согласно выводу @Braiam

apt-cache:

php5:
Installed: (none)
Candidate: 5.4.9-4ubuntu2
Version table:
 5.4.9-4ubuntu2 0
    500 http://us.archive.ubuntu.com/ubuntu/ raring/main amd64 Packages
libapache2-mod-php5:
Installed: (none)
Candidate: 5.4.9-4ubuntu2
Version table:
 5.4.9-4ubuntu2 0
    500 http://us.archive.ubuntu.com/ubuntu/ raring/main amd64 Packages
php5-cgi:
Installed: (none)
Candidate: 5.4.9-4ubuntu2
Version table:
 5.4.9-4ubuntu2 0
    500 http://us.archive.ubuntu.com/ubuntu/ raring/main amd64 Packages
php5-fpm:
Installed: (none)
Candidate: 5.4.9-4ubuntu2
Version table:
 5.4.9-4ubuntu2 0
    500 http://us.archive.ubuntu.com/ubuntu/ raring/universe amd64 Packages

cat источников.list & amp; /etc/apt/sources.list.d/*.list

# deb cdrom:[Ubuntu 12.10 _Quantal Quetzal_ - Release amd64 (20121017.5)]/ .Trashes/501/dists/raring/main/binary-i386/

# deb cdrom:[Ubuntu 12.10 _Quantal Quetzal_ - Release amd64 (20121017.5)]/ .Trashes/501/dists/raring/restricted/binary-i386/
# deb cdrom:[Ubuntu 12.10 _Quantal Quetzal_ - Release amd64 (20121017.5)]/ quantal main restricted
# deb cdrom:[Ubuntu 12.10 _Quantal Quetzal_ - Release amd64 (20121017.5)]/.Trashes/501/ raring main restricted

# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
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.

## 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

## 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

## 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.


## 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 quantal partner
# deb-src http://archive.canonical.com/ubuntu quantal 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 raring main
# deb-src http://extras.ubuntu.com/ubuntu raring main

#spotify yo
# deb http://repository.spotify.com stable non-free
deb http://us.archive.ubuntu.com/ubuntu/ raring-updates universe main restricted multiverse
deb http://security.ubuntu.com/ubuntu/ raring-security universe main restricted multiverse

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

0
задан 16.04.2020, 01:24

1 ответ

Установите php5:

sudo apt-get install php5

Установите apache:

sudo apt-get install apache2

Для использования php5 с apache2 установите:

sudo apt-get install libapache2-mod-php5

Установите клиент и сервер mysql:

sudo apt-get install mysql-client mysql-server

И все, у вас установлен стек LAMP!

один вкладыш:

sudo apt-get install php5 apache2 libapache2-mod-php5 mysql-client mysql-server
-1
ответ дан 16.04.2020, 01:25
  • 1
    Я don' t думают, что Вы понимаете, пытаться установить любой из них говорит мне, что я повредил пакеты, неважно, порядок. – mpen 16.04.2020, 01:25
  • 2
    @KevinQualters, если это doesn' t отвечают на Вашу проблему don' t отмечают ответ, как решено. – AndreiM 16.04.2020, 01:26
  • 3
    Я сделал некоторый поиск и нашел этот ссылка . Это могло решить Вашу проблему... – fgregg 16.04.2020, 01:26
  • 4
    Все еще didn' t работают, к сожалению, что-то странное определенно произошло, и I' ll, вероятно, должны скомпилировать несколько вещей самостоятельно. Спасибо за усилие с Вашей стороны, I' ll идут вперед и принимают ответ. – Josh Mc 16.04.2020, 01:26

Теги

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