Вопрос по установки Apache + PHP + MySQL?

Автор shiko, 19 Января 2009, 20:46

« предыдущая тема - следующая тема »

0 Пользователей и 1 Гость просматривают эту тему.

shiko

Всем доброго времени суток! Проблема в следующем, apache установлен и настроен, просмотр страниц html осуществляет. Мне необходимо подключить модуль php5, библиотеки libphp5 и mssql для размещения и конструирования web-странички с использованием php скриптов. Я почитал литературу и прежде чем производить установку и настройку выше указанных библиотек и модулей решил проверить что у меня есть на компе через drakconf, в итоге обнаружил что имеются установленные из репозитария а может быть и самого индейца библиотеки и модули, но они почему то не работают, а сервер выдает ошибку при перезапуске:
[root@stp1 /]# service httpd restart
Shutting down httpd:                                            [  OK  ]
Starting httpd: httpd: Syntax error on line 27 of /etc/httpd/conf/httpd.conf: Cannot load /etc/httpd/modules/libphp5.so into server: /etc/httpd/modules/libphp5.so: cannot open shared object file: No such file or directory
                                                                [ СБОЙ ]

понятно что возможно неправильно указан путь в конфиге httpd.conf, а как прописать не могу понять, вроде и путь прописывал, да все та же ошибка выходит
         LoadModule setenvif_module modules/mod_setenvif.so
      #LoadModule php5_module modules/libphp5.so
      #LoadModule php5_module usr/lib/libphp5_common.so
через drakconf установленна вот эта библиотека, а лежит она вот здесь: /etc/lib/libphp5_common.so
libphp5_common5 - Shared library for PHP5?ВООБЩЕ ЭТА ТА БИБЛИОТЕКА ИЛИ НЕТ???

А из php модулей в drakconf установлены следующие:
Цитировать- apache-mod_php - The PHP5 HTML-embedded scripting language for use with apache?
 ?/etc/httpd/modules.d/70_mod_php.conf
        ?/usr/lib/apache-extramodules/mod_php5.so

а это файл php.ini каторый тоже как я понял надо настраивать, он тоже установлен
- php-ini - INI files for PHP?
 ?/etc/php.d
        ?/etc/php.ini
        ?/usr/lib/php
        ?/usr/lib/php/extensions

Подскажите пожалуйста каким образом можно это все связать или как прописать в конфиге:
### Section 1: Global Environment
#
      Listen 80
      ServerRoot "/etc/httpd"
      PidFile /var/run/httpd.pid
      Timeout 60
      KeepAlive On
      MaxKeepAliveRequests 50
      KeepAliveTimeout 5

      ### Section 2: 'Main' server configuration 192.168.0.0/24

      User apache
      Group apache
      ServerAdmin alza_74@mail.ru
      ServerName localhost
      DocumentRoot "/var/www/html"

      LoadModule authz_host_module modules/mod_authz_host.so
      LoadModule alias_module modules/mod_alias.so
      LoadModule log_config_module modules/mod_log_config.so
      LoadModule mime_module modules/mod_mime.so
      LoadModule status_module modules/mod_status.so
      LoadModule info_module modules/mod_info.so
      LoadModule dir_module modules/mod_dir.so
      LoadModule setenvif_module modules/mod_setenvif.so
      #LoadModule php5_module modules/libphp5.so
      #LoadModule php5_module usr/lib/libphp5_common.so

      <Directory />
      Options None
      AllowOverride None
      Order allow,deny
      Allow from 127.0.0.1
      </Directory>

      <Directory "/var/www/html">
      Options None
      AllowOverride None
      Order allow,deny
      Allow from 127.0.0.1
      </Directory>

#      <Directory "/home/httpd/ona">
#      Options None
#      AllowOverride None
#      Order allow,deny
#      Allow from all
#      </Directory>

#      <Files .pl>
#      Options None
#      AllowOverride None
#      Order deny,allow
#      Deny from all
#      </Files>

      <IfModule mod_dir.c>
      DirectoryIndex index.html index.php index.php3 index.php5 default.html index.cgi
      </IfModule>

      #<IfModule mod_include.c>
      #Include conf/mmap.conf
      #</IfModule>

      UseCanonicalName On

      <IfModule mod_mime.c>
      TypesConfig /etc/httpd/conf/mime.types
      </IfModule>

      DefaultType text/plain
      HostnameLookups Off

      ErrorLog /var/log/httpd/error_log
      LogLevel warn
      LogFormat "%h %l %u %t "%r" %>s %b "%{Referer}i" "%{User-Agent}i"" combined
      SetEnvIf Request_URI .gif$ gif-image
      CustomLog /var/log/httpd/access_log combined env=!gif-image
      ServerSignature Off

      <IfModule mod_alias.c>
      ScriptAlias /cgi-bin/  "/home/httpd/cgi-bin/"
      <Directory "/home/httpd/cgi-bin">
      AllowOverride None
      Options None
      Order allow,deny
      Allow from all
      </Directory>
      </IfModule>

      <IfModule mod_mime.c>
      AddEncoding x-compress Z
      AddEncoding x-gzip gz tgz

      AddType application/x-tar .tgz
      </IfModule>

      ErrorDocument 500 "The server made a boo boo.
      ErrorDocument 404 http://192.168.1.1/error.htm
      ErrorDocument 403 "Access Forbidden -- Go away.

      <IfModule mod_setenvif.c>
      BrowserMatch "Mozilla/2" nokeepalive
      BrowserMatch "MSIE 4.0b2;" nokeepalive downgrade-1.0 force-response-1.0
      BrowserMatch "RealPlayer 4.0" force-response-1.0
      BrowserMatch "Java/1.0" force-response-1.0
      BrowserMatch "JDK/1.0" force-response-1.0
      </IfModule>

      ### Section 3: Virtual Hosts
не хочется качать и собирать пакеты из tar архивов, тем более если уже есть установленный софт. Подскажите кто сталкивался с подобной ситуацией, как быть!

Vicpo

В обще то Mandriva при установке пакетов apache + php + mysql сама все корректно прописывает в модулях и править потом ничего не приходится.
Переставьте пакеты php и все само заработает

shiko

Да вот в том то и дело никак не доганю как их ПРИСТАВИТЬ. Они вродебы есть, эти пакеты и в тоже время как будто бы и нет. В конфиг внес изменения добавив следующие строки :
LoadModule php5_module modules/libphp5.so
<IfModule mod_dir.c>
      DirectoryIndex index.html index.php index.php3 index.php4 index.php5 default.html index.cgi
      </IfModule>

<IfModule mod_mime.c>
      AddType application/x-httpd-php .php
      AddType application/x-httpd-php5 .php
      AddType application/x-httpd-source .php .phps

и всеравно дает ошибку при перезапуске
Starting httpd: httpd: Syntax error on line 27 of /etc/httpd/conf/httpd.conf: Cannot load /etc/httpd/modules/libphp5.so into server: /etc/httpd/modules/libphp5.so: cannot open shared object file: No such file or directory
                                                                [ СБОЙ ]

shiko

Здравствуйте! Переустановил мандриву, при установки установил apache. Модулю (mod_perl и mod_php5) встали по следующему пути: /etc/httpd/extramodules. Я их скопировал /etc/httpd/modules туда кде лежат все работающие модули, а в httpd.conf внес следующие изменения:
добавил модуль
LoadModule php5_module modules/mod_php5.so

<IfModule mod_php5.c>
        DirectoryIndex index.php index.html
    </IfModule>
    <IfModule mod_php5.c>
        AddType application/x-httpd-php .php
        AddType application/x-httpd-php-source .phps
    </IfModule>

после чего дал команду: apachectl graceful, и перезагрузил апач. Ошибки не было, но тестовую страничку с кодом:
<html>
<body>
<?php
 echo "This is a test";
?>
</body>
</html>
все равно не хочет обрабатывать. :( Загружает в браузере чистый лист и все, в чем может быть проблема подскажите пожалуйста.

Iskander

Любовь и массовые расстрелы спасут мир.

shiko

Вот представляю данные из лог файла /var/log/httpd/arror_log
[Mon Jan 26 12:03:52 2009] [notice] core dump file size limit raised to 4294967295 bytes
[Mon Jan 26 12:03:53 2009] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Mon Jan 26 12:03:53 2009] [notice] Digest: generating secret for digest authentication ...
[Mon Jan 26 12:03:53 2009] [notice] Digest: done
[Mon Jan 26 12:03:55 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) mod_ssl/2.2.6 OpenSSL/0.9.8e PHP/5.2.4 with Suhosin-Patch mod_perl/2.0.3 Perl/v5.8.8 configured -- resuming normal operations
[Mon Jan 26 17:37:36 2009] [notice] caught SIGTERM, shutting down
[Mon Jan 26 18:49:06 2009] [notice] core dump file size limit raised to 4294967295 bytes
[Mon Jan 26 18:49:07 2009] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Mon Jan 26 18:49:07 2009] [notice] Digest: generating secret for digest authentication ...
[Mon Jan 26 18:49:07 2009] [notice] Digest: done
[Mon Jan 26 18:49:10 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) mod_ssl/2.2.6 OpenSSL/0.9.8e PHP/5.2.4 with Suhosin-Patch mod_perl/2.0.3 Perl/v5.8.8 configured -- resuming normal operations
[Mon Jan 26 22:11:32 2009] [notice] caught SIGTERM, shutting down
[Mon Jan 26 22:12:49 2009] [notice] core dump file size limit raised to 4294967295 bytes
[Mon Jan 26 22:12:50 2009] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Mon Jan 26 22:12:50 2009] [notice] Digest: generating secret for digest authentication ...
[Mon Jan 26 22:12:50 2009] [notice] Digest: done
[Mon Jan 26 22:12:52 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) mod_ssl/2.2.6 OpenSSL/0.9.8e PHP/5.2.4 with Suhosin-Patch mod_perl/2.0.3 Perl/v5.8.8 configured -- resuming normal operations
[Tue Jan 27 00:45:28 2009] [notice] caught SIGTERM, shutting down
[Tue Jan 27 15:45:44 2009] [notice] core dump file size limit raised to 4294967295 bytes
[Tue Jan 27 15:45:47 2009] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Tue Jan 27 15:45:47 2009] [notice] Digest: generating secret for digest authentication ...
[Tue Jan 27 15:45:47 2009] [notice] Digest: done
[Tue Jan 27 15:45:49 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) mod_ssl/2.2.6 OpenSSL/0.9.8e PHP/5.2.4 with Suhosin-Patch mod_perl/2.0.3 Perl/v5.8.8 configured -- resuming normal operations
[Tue Jan 27 17:48:31 2009] [notice] caught SIGTERM, shutting down
[Tue Jan 27 17:55:26 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) configured -- resuming normal operations
[Tue Jan 27 17:55:32 2009] [notice] caught SIGTERM, shutting down
[Tue Jan 27 17:55:32 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) configured -- resuming normal operations
[Tue Jan 27 19:25:31 2009] [notice] Graceful restart requested, doing restart
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:25:31 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) configured -- resuming normal operations
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [notice] Graceful restart requested, doing restart
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) configured -- resuming normal operations
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:39:14 2009] [notice] Graceful restart requested, doing restart
[Tue Jan 27 19:39:14 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:39:14 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:39:14 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:39:14 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:39:14 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
Syntax error on line 91 of /etc/httpd/conf/httpd.conf:
Invalid command 'AddModule', perhaps misspelled or defined by a module not included in the server configuration
[Tue Jan 27 19:40:07 2009] [warn] pid file /var/run/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
[Tue Jan 27 19:40:07 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Tue Jan 27 19:40:32 2009] [notice] caught SIGTERM, shutting down
[Tue Jan 27 19:40:32 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Tue Jan 27 20:19:54 2009] [notice] caught SIGTERM, shutting down
[Wed Jan 28 12:15:04 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Wed Jan 28 13:08:39 2009] [notice] caught SIGTERM, shutting down
[Wed Jan 28 19:36:12 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Thu Jan 29 00:03:55 2009] [notice] caught SIGTERM, shutting down
[Sat Jan 31 15:33:22 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sat Jan 31 18:12:37 2009] [notice] caught SIGTERM, shutting down
[Sat Jan 31 18:12:39 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sat Jan 31 18:13:14 2009] [notice] caught SIGTERM, shutting down
[Sat Jan 31 18:30:36 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations

shiko

Попробовал еще один вариант, как показано в одной из статей, добавил в конфиг вот эту строку:
LoadModule php5_module usr/lib/libphp5_common.soдалее дал команду
# apachectl gracefulрезультат следующий
[Sun Feb 01 12:08:41 2009] [warn] module php5_module is already loaded, skipping
[root@localhost shiko]# service httpd restart
Shutting down httpd:                                            [  OK  ]
Starting httpd: [Sun Feb 01 12:08:51 2009] [warn] module php5_module is already loaded, skipping
                                                                [  OK  ]
После чего попробовал еще раз загрузить тест страничку html со вставленным php кодом
<html>
<body>
<?php
 echo "This is a test";
?>
</body>
</html>
Подскажите пожалуйста кто знает как победить эту проблему, в чем может быть проблема, почему сервер не обрабатывает скрипт php ,  ??? очень нужно!

shiko

Скажите, а может быть проблема возникает потому, что я неправильно указал путь к установленному модулю php, у меня он стаит вот здесь:  ?/usr/lib/apache-extramodules/mod_php5.so
А у себя в конфиге я подключил модуль php следующим образом
ЦитироватьLoadModule authz_host_module modules/mod_authz_host.so
      LoadModule alias_module modules/mod_alias.so
      LoadModule log_config_module modules/mod_log_config.so
      LoadModule mime_module modules/mod_mime.so
      LoadModule status_module modules/mod_status.so
      LoadModule info_module modules/mod_info.so
      LoadModule dir_module modules/mod_dir.so
      LoadModule setenvif_module modules/mod_setenvif.so
      LoadModule php5_module modules/mod_php5.so
      LoadModule php5_module usr/lib/libphp5_common.so

Vicpo

В логах апача при старте что пишет?

shiko

Вот данные  error_log файла:
[Mon Jan 26 12:03:52 2009] [notice] core dump file size limit raised to 4294967295 bytes
[Mon Jan 26 12:03:53 2009] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Mon Jan 26 12:03:53 2009] [notice] Digest: generating secret for digest authentication ...
[Mon Jan 26 12:03:53 2009] [notice] Digest: done
[Mon Jan 26 12:03:55 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) mod_ssl/2.2.6 OpenSSL/0.9.8e PHP/5.2.4 with Suhosin-Patch mod_perl/2.0.3 Perl/v5.8.8 configured -- resuming normal operations
[Mon Jan 26 17:37:36 2009] [notice] caught SIGTERM, shutting down
[Mon Jan 26 18:49:06 2009] [notice] core dump file size limit raised to 4294967295 bytes
[Mon Jan 26 18:49:07 2009] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Mon Jan 26 18:49:07 2009] [notice] Digest: generating secret for digest authentication ...
[Mon Jan 26 18:49:07 2009] [notice] Digest: done
[Mon Jan 26 18:49:10 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) mod_ssl/2.2.6 OpenSSL/0.9.8e PHP/5.2.4 with Suhosin-Patch mod_perl/2.0.3 Perl/v5.8.8 configured -- resuming normal operations
[Mon Jan 26 22:11:32 2009] [notice] caught SIGTERM, shutting down
[Mon Jan 26 22:12:49 2009] [notice] core dump file size limit raised to 4294967295 bytes
[Mon Jan 26 22:12:50 2009] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Mon Jan 26 22:12:50 2009] [notice] Digest: generating secret for digest authentication ...
[Mon Jan 26 22:12:50 2009] [notice] Digest: done
[Mon Jan 26 22:12:52 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) mod_ssl/2.2.6 OpenSSL/0.9.8e PHP/5.2.4 with Suhosin-Patch mod_perl/2.0.3 Perl/v5.8.8 configured -- resuming normal operations
[Tue Jan 27 00:45:28 2009] [notice] caught SIGTERM, shutting down
[Tue Jan 27 15:45:44 2009] [notice] core dump file size limit raised to 4294967295 bytes
[Tue Jan 27 15:45:47 2009] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Tue Jan 27 15:45:47 2009] [notice] Digest: generating secret for digest authentication ...
[Tue Jan 27 15:45:47 2009] [notice] Digest: done
[Tue Jan 27 15:45:49 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) mod_ssl/2.2.6 OpenSSL/0.9.8e PHP/5.2.4 with Suhosin-Patch mod_perl/2.0.3 Perl/v5.8.8 configured -- resuming normal operations
[Tue Jan 27 17:48:31 2009] [notice] caught SIGTERM, shutting down
[Tue Jan 27 17:55:26 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) configured -- resuming normal operations
[Tue Jan 27 17:55:32 2009] [notice] caught SIGTERM, shutting down
[Tue Jan 27 17:55:32 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) configured -- resuming normal operations
[Tue Jan 27 19:25:31 2009] [notice] Graceful restart requested, doing restart
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:25:31 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) configured -- resuming normal operations
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:25:31 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [notice] Graceful restart requested, doing restart
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) configured -- resuming normal operations
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:26:22 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:39:14 2009] [notice] Graceful restart requested, doing restart
[Tue Jan 27 19:39:14 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:39:14 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:39:14 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:39:14 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Tue Jan 27 19:39:14 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
Syntax error on line 91 of /etc/httpd/conf/httpd.conf:
Invalid command 'AddModule', perhaps misspelled or defined by a module not included in the server configuration
[Tue Jan 27 19:40:07 2009] [warn] pid file /var/run/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
[Tue Jan 27 19:40:07 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Tue Jan 27 19:40:32 2009] [notice] caught SIGTERM, shutting down
[Tue Jan 27 19:40:32 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Tue Jan 27 20:19:54 2009] [notice] caught SIGTERM, shutting down
[Wed Jan 28 12:15:04 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Wed Jan 28 13:08:39 2009] [notice] caught SIGTERM, shutting down
[Wed Jan 28 19:36:12 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Thu Jan 29 00:03:55 2009] [notice] caught SIGTERM, shutting down
[Sat Jan 31 15:33:22 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sat Jan 31 18:12:37 2009] [notice] caught SIGTERM, shutting down
[Sat Jan 31 18:12:39 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sat Jan 31 18:13:14 2009] [notice] caught SIGTERM, shutting down
[Sat Jan 31 18:30:36 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sat Jan 31 19:47:14 2009] [notice] caught SIGTERM, shutting down
[Sat Jan 31 21:37:55 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sat Jan 31 22:11:56 2009] [notice] caught SIGTERM, shutting down
[Sun Feb 01 11:35:55 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sun Feb 01 12:04:35 2009] [notice] Graceful restart requested, doing restart
[Sun Feb 01 12:04:35 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Sun Feb 01 12:04:35 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Sun Feb 01 12:04:35 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Sun Feb 01 12:04:35 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Sun Feb 01 12:04:35 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Sun Feb 01 12:04:36 2009] [warn] module php5_module is already loaded, skipping
[Sun Feb 01 12:04:36 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sun Feb 01 12:05:31 2009] [notice] caught SIGTERM, shutting down
[Sun Feb 01 12:05:33 2009] [warn] module php5_module is already loaded, skipping
[Sun Feb 01 12:05:33 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sun Feb 01 12:05:47 2009] [notice] caught SIGTERM, shutting down
[Sun Feb 01 12:05:48 2009] [warn] module php5_module is already loaded, skipping
[Sun Feb 01 12:05:48 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sun Feb 01 12:08:41 2009] [notice] Graceful restart requested, doing restart
[Sun Feb 01 12:08:41 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Sun Feb 01 12:08:41 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Sun Feb 01 12:08:41 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Sun Feb 01 12:08:41 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Sun Feb 01 12:08:41 2009] [error] [client ::1] client denied by server configuration: /var/www/html/
[Sun Feb 01 12:08:41 2009] [warn] module php5_module is already loaded, skipping
[Sun Feb 01 12:08:41 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sun Feb 01 12:08:50 2009] [notice] caught SIGTERM, shutting down
[Sun Feb 01 12:08:51 2009] [warn] module php5_module is already loaded, skipping
[Sun Feb 01 12:08:51 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sun Feb 01 12:45:30 2009] [notice] caught SIGTERM, shutting down
[Sun Feb 01 16:00:55 2009] [warn] module php5_module is already loaded, skipping
[Sun Feb 01 16:00:58 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sun Feb 01 16:11:52 2009] [notice] caught SIGTERM, shutting down
[Sun Feb 01 19:27:17 2009] [warn] module php5_module is already loaded, skipping
[Sun Feb 01 19:27:18 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
[Sun Feb 01 20:26:38 2009] [notice] caught SIGTERM, shutting down
[Mon Feb 02 00:00:27 2009] [warn] module php5_module is already loaded, skipping
[Mon Feb 02 00:00:29 2009] [notice] Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch configured -- resuming normal operations
Вроде бы что то подгружает если я не ошибаюсь, но тогда почему не обрабатывает код тестовой странички???

вот access_log файл:
(internal dummy connection)"
::1 - - [27/Jan/2009:19:26:22 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) (internal dummy connection)"
::1 - - [27/Jan/2009:19:26:22 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) (internal dummy connection)"
::1 - - [27/Jan/2009:19:26:22 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) (internal dummy connection)"
::1 - - [27/Jan/2009:19:26:22 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) (internal dummy connection)"
::1 - - [27/Jan/2009:19:39:14 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) (internal dummy connection)"
::1 - - [27/Jan/2009:19:39:14 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) (internal dummy connection)"
::1 - - [27/Jan/2009:19:39:14 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) (internal dummy connection)"
::1 - - [27/Jan/2009:19:39:14 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) (internal dummy connection)"
::1 - - [27/Jan/2009:19:39:14 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) (internal dummy connection)"
127.0.0.1 - - [27/Jan/2009:19:46:33 +0300] "GET /page_test.html HTTP/1.1" 200 62 "-" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.6) Gecko/20070208 Mandriva/2.0.0.6-12mdv2008.0 (2008.0) Firefox/2.0.0.6"
127.0.0.1 - - [31/Jan/2009:21:41:08 +0300] "GET /page_test.html HTTP/1.1" 304 - "-" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.6) Gecko/20070208 Mandriva/2.0.0.6-12mdv2008.0 (2008.0) Firefox/2.0.0.6"
::1 - - [01/Feb/2009:12:04:35 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch (internal dummy connection)"
::1 - - [01/Feb/2009:12:04:35 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch (internal dummy connection)"
::1 - - [01/Feb/2009:12:04:35 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch (internal dummy connection)"
::1 - - [01/Feb/2009:12:04:35 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch (internal dummy connection)"
::1 - - [01/Feb/2009:12:04:35 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch (internal dummy connection)"
::1 - - [01/Feb/2009:12:08:41 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch (internal dummy connection)"
::1 - - [01/Feb/2009:12:08:41 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch (internal dummy connection)"
::1 - - [01/Feb/2009:12:08:41 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch (internal dummy connection)"
::1 - - [01/Feb/2009:12:08:41 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch (internal dummy connection)"
::1 - - [01/Feb/2009:12:08:41 +0300] "GET / HTTP/1.0" 403 28 "-" "Apache/2.2.6 (Mandriva Linux/PREFORK-8mdv2008.0) PHP/5.2.4 with Suhosin-Patch (internal dummy connection)"

Vicpo


shiko

Вот вывод команд:
[root@localhost shiko]# rpm -qa | grep php
php-ini-5.2.4-1mdv2008.0
php-timezonedb-2007.5-4mdv2008.0
php-gd-5.2.4-2mdv2008.0
php-ctype-5.2.4-2mdv2008.0
php-posix-5.2.4-2mdv2008.0
php-xmlwriter-5.2.4-2mdv2008.0
php-gettext-5.2.4-2mdv2008.0
php-openssl-5.2.4-2mdv2008.0
php-sysvsem-5.2.4-2mdv2008.0
php-xmlreader-5.2.4-2mdv2008.0
apache-mod_php-5.2.4-2mdv2008.0
libphp5_common5-5.2.4-2mdv2008.0
php-ftp-5.2.4-2mdv2008.0
php-suhosin-0.9.20-6mdv2008.0
php-tokenizer-5.2.4-2mdv2008.0
php-dom-5.2.4-2mdv2008.0
php-json-5.2.4-2mdv2008.0
php-filter-5.2.4-2mdv2008.0
php-session-5.2.4-2mdv2008.0
php-zlib-5.2.4-2mdv2008.0
php-simplexml-5.2.4-2mdv2008.0
php-hash-5.2.4-2mdv2008.0
php-sysvshm-5.2.4-2mdv2008.0
php-mysql-5.2.4-2mdv2008.0

[root@localhost shiko]# rpm -qa | grep apache
apache-modules-2.2.6-8mdv2008.0
apache-mod_perl-2.0.3-7mdv2008.0
apache-mod_php-5.2.4-2mdv2008.0
apache-conf-2.2.6-1mdv2008.0
apache-mpm-prefork-2.2.6-8mdv2008.0
apache-mod_ssl-2.2.6-8mdv2008.0
apache-base-2.2.6-8mdv2008.0
apache-mod_suexec-2.2.6-2mdv2008.0

в том то и дело если как вы говорите, после установки сервера apache все модули должны вставать по умолчанию то почему не обрабатывается моя тестовая страничка? И кстати давно хотел спросить, почему в котфиге апача в том месте где прописываются модули сервера, не прописан модуль php?

Vicpo


shiko

[shiko@localhost ~]$ ls /etc/httpd/modules.d/
40_mod_ssl.conf  69_mod_suexec.conf  70_mod_php.conf  75_mod_perl.conf

Vicpo

70_mod_php.conf подгрузка php
так что верни на место дефолтный конфиг
во вложении если что

shiko

Я извиняюсь, но я не совсем понял что мне делать? Да и в дефолтном конфиге вообще нет намека на подключение модуля php, я собственно поэтому и спрашивал вашего совета.

shiko

Я поставил ваш конфиг по умолчанию, после перезагрузки выдавал вот это сообщение:
# service httpd restart
Shutting down httpd:                                            [  OK  ]
Starting httpd: httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
                                                                [  OK  ]
Раскоментировал стороку с именим сервера ServerName и указал доменное имя, перезагрузил все нормально, но все равно тестируемую страничку не обрабатывает :( что делать дальше еще ума не приложу.

ЦитироватьДа и в дефолтном конфиге вообще нет намека на подключение модуля php, я собственно поэтому и спрашивал вашего совета.

Vicpo

в дефолтном конфиге есть строчка подгрузки модулей из каталога /etc/httpd/modules.d а в этом каталоге лежит файлик 70_mod_php.conf вот в этом файле и прописана подгрузка модуля php
Если ты хочешь следовать мануалам из сети то ставь дистр для которого эти мануалы написаны, либо разбирайся как в мандриве устроена загрузка apache

shiko

ЦитироватьЕсли ты хочешь следовать мануалам из сети то ставь дистр для которого эти мануалы написаны, либо разбирайся как в мандриве устроена загрузка apache
Здравствуйте Vicpo! Я понял по поводу мануалов, да действительно вы правы, я об этом как то не подумал.  Но если в мандриве так все пушисто как вы говорите, если модули подгружаются и все в порядке почему не обрабатывается тестовая страничка php???
Помогите пожалуйста разобраться с этой проблемой, а то хочется поработать с php, а никак не получается.

Vicpo

ставь дефолтный конфиг, топай в /etc/httpd/conf/vhost.d смотри, что там есть
Где находится каталог сервера куда ты ложишь скрипт с php?
При попытке открыть скрипт он начинает скачиваться или просто пустая страница?
Если пустая страница смотри логи ошибок апача