dudilona
@dudilona

Как решить проблему с подключением mod_status на Apache?

Поднял web сервер на VPS при помощи CP Vesta.
ОС: Debian 7
Версия apache: Apache/2.2.22 (Debian)
На сервере работает один сайт - CMS PrestaShop 1.6.1.4
Домен не прикреплял - работаю по IP

Не могу подключить mod_status на Apache.
Облазил весь интернет, перепробовал кучу гайдов - ничего не работает (
Пытался разобраться сам - не разобрался.
Может из вас кто подскажет в чем причина, ну а я пока начну с базовых моментов:

Конфиг Apache /etc/apache2/apache2.conf :
# It is split into several files forming the configuration hierarchy outlined
# below, all located in the /etc/apache2/ directory:
#
#       /etc/apache2/
#       |-- apache2.conf
#       |       `--  ports.conf
#       |-- mods-enabled
#       |       |-- *.load
#       |       `-- *.conf
#       |-- conf.d
#       |       `-- *

# Global configuration
LockFile ${APACHE_LOCK_DIR}/accept.lock
PidFile ${APACHE_PID_FILE}
Timeout 30
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 20

<IfModule mpm_prefork_module>
    StartServers          3
    MinSpareServers       3
    MaxSpareServers       9
    ServerLimit         256
    MaxClients           20
    MaxRequestsPerChild 3000
</IfModule>

<IfModule mpm_worker_module>
    StartServers          2
    MinSpareThreads      25
    MaxSpareThreads      75
    ThreadLimit          64
    ThreadsPerChild      25
    MaxClients          200
    MaxRequestsPerChild 4000
</IfModule>

<IfModule mpm_event_module>
    StartServers          2
    MinSpareThreads      25
    MaxSpareThreads      75
    ThreadLimit          64
    ThreadsPerChild      25
    MaxClients          200
    MaxRequestsPerChild 4000
</IfModule>

# These need to be set in /etc/apache2/envvars
User ${APACHE_RUN_USER}
Group ${APACHE_RUN_GROUP}
#User www-data
#Group www-data

AccessFileName .htaccess

<Files ~ "^\.ht">
    Order allow,deny
    Deny from all
    Satisfy all
</Files>

DefaultType None
HostnameLookups Off

ErrorLog ${APACHE_LOG_DIR}/error.log
LogLevel warn

# Include module configuration:
Include mods-enabled/*.load
Include mods-enabled/*.conf

# Include list of ports to listen on and which to use for name based vhosts
Include ports.conf

LogFormat "%v:%p %h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" vhost_combined
LogFormat "%h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined
LogFormat "%h %l %u %t \"%r\" %>s %O" common
LogFormat "%{Referer}i -> %U" referer
LogFormat "%{User-agent}i" agent
LogFormat "%b" bytes

Include conf.d/


Запуск подгружаемого мода status: /etc/apache2/mods-enabled/status.load
LoadModule status_module /usr/lib/apache2/modules/mod_status.so


Конфиг мода status: /etc/apache2/mods-enabled/status.conf
<Location /server-status>
    SetHandler server-status
    Order deny,allow
    Deny from all
    Allow from all
</Location>

ExtendedStatus On


При выполнении команды: /usr/sbin/a2enmod status пишет
Module status already enabled

Если запустить команду: apachectl -l то увидим что apache не скомпилировался с нашим модом:
Compiled in modules:
  core.c
  mod_log_config.c
  mod_logio.c
  mod_version.c
  prefork.c
  http_core.c
  mod_so.c


Где еще ковырять не знаю. Разобраться самостоятельно наверно у меня уже не получится.

Всем пис ;)
  • Вопрос задан
  • 2595 просмотров
Решения вопроса 1
Пригласить эксперта
Ответы на вопрос 1
@neol
apachectl -l
показывает список модулей, подключенных при компиляции, а у вас mod_status подгружается динамически. Соответственно и смотреть надо так:
apachectl -t -D DUMP_MODULES
Ответ написан
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Войти через центр авторизации
Похожие вопросы