在ubuntu 12.04上安装apache 2.4和php 5.5

我试图用ubuntu 12.04在vm上设置apache 2.4和PHP 5.5的测试环境,第一件事是添加存储库
apt-add-repository ppa:ptn107/apache
apt-add-repository ppa:ondrej/PHP5

然后安装apache 2.4

apt-get install apache2-mpm-worker

检查apache版本:

# apache2 -v
Server version: Apache/2.4.6 (Ubuntu)
Server built:   Sep 23 2013 07:23:34

安装PHP 5.5

apt-get install PHP5-common PHP5-MysqLnd PHP5-xmlrpc PHP5-curl PHP5-gd PHP5-cli PHP5-fpm PHP-pear PHP5-dev PHP5-imap PHP5-mcrypt

检查PHP版本

PHP -v
PHP 5.5.8-3+sury.org~precise+1 (cli) (built: Jan 24 2014 10:15:11) 
copyright (c) 1997-2013 The PHP Group
Zend Engine v2.5.0,copyright (c) 1998-2013 Zend Technologies
     with Zend OPcache v7.0.3-dev,copyright (c) 1999-2013,by Zend Technologies

所以everyting似乎确定的事情是我需要mod_fastcgi但不能安装:

apt-get install libapache2-mod-fastcgi
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages Could not be installed. This may mean that you haverequested 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:
libapache2-mod-fastcgi : Depends: apache2.2-common (>= 2.2.4) but it is not going to be installed
E: Unable to correct problems,you have held broken packages.

所以如果mod_fastcgi无法启用,我该如何运行PHP文件PHP-fpm?有没有我失踪的东西?

您可以从这里安装fastcgi mod和apache2,验证它在我的结尾有效. https://launchpad.net/~ondrej/+archive/apache2?field.series_filter=precise

相关文章

目录前言一、创建Hadoop用户二、更新apt和安装Vim编辑器三、...
原文连接:https://www.cnblogs.com/yasmi/p/5192694.html ...
电脑重启后,打开VirtualBox,发现一直用的虚拟机莫名的消失...
参见:https://blog.csdn.net/weixin_38883338/article/deta...
Ubuntu 18.04 LTS 已切换到 Netplan 来配置网络接口。Netpla...
介绍每个 Web 服务都可以通过特定的 URL 在 Internet 上访问...