4

我在 EC2 实例上有一个带有 Ubuntu 14.04 和 Apache2 的 LAMP 配置服务器 AMD64。

我按照这里的官方指南,所以首先

我下载sitemap_linux-x86_64-beta1-20091231.tar.gz并解压

然后我打字sudo sitemap-install/install.sh –-apache-bin=/usr/sbin/apache2,我的问题来了:

What is the location of the Apache binary or control script?
[/usr/sbin/apache2] should support -V option.
/usr/sbin/apache2 is not a supported Apache binary or control script.

我确定位置,事实上,如果我从日志文件中重新启动 Apache,我可以看到AH00094: Command line: '/usr/sbin/apache2'。我也试过用这个作为位置/usr/sbin/apache2ctl,但没办法。

我在谷歌上搜索了几天,没有找到任何东西。

为什么我无法使用/usr/sbin/apache2Apache 的位置安装 Google Sitemap Generator?

更新

如果我输入apache2 -V输出是一个警告列表,Invalid Mutex directory in argument file:${APACHE_LOCK_DIR}但这是因为请求/usr/sbin/apache2直接从二进制文件输出,所以/etc/apache2/envvars文件不是如here所述的那样来源

4

2 回答 2

2

文档不是说要使用-a而不是--apache-bin,所以你应该这样做:

sudo sitemap-install/install.sh –a /usr/sbin/apache2

我的apache2二进制文件和apache2ctl控制脚本都理解这个-V参数:

root@:~# apache2 -V
Server version: Apache/2.2.22 (Ubuntu)
Server built:   Jul 24 2015 17:25:42

root@:~# apache2ctl -V
Server version: Apache/2.2.22 (Ubuntu)
Server built:   Jul 24 2015 17:25:42
于 2016-03-01T00:43:50.563 回答
1

在我看来你应该这样做:

sudo 站点地图安装/install.sh --apache-bin=/usr/sbin/apachectl

另外 /usr/sbin/apachectl 很可能是一个软链接,所以ls -la如果你想知道真正的位置,只需在上面运行一个。

于 2016-02-28T10:16:42.363 回答