Strona 1 z 1
[+] PHP - problem podczas restartowania Apache
: 30 października 2009, 19:04
autor: targenor
Witam.
Zainstalowałem Apache według instrukcji z
http://www.unixy.pl/forum/art/php_mysql.html.
Podczas restartowania konsola wywala mi coś takiego:
Kod: Zaznacz cały
debian:/home/targenor# /etc/init.d/apache2 restart
Restarting web server: apache2We failed to correctly shutdown apache, so we're now killing all running apache processes. This is almost certainly suboptimal, so please make sure your system is working as you'd expect now! (warning).
... waiting Syntax error on line 14 of /etc/apache2/sites-enabled/000-default:
Invalid command '\xef\xbb\xbfRedirectMatch', perhaps misspelled or defined by a module not included in the server configuration
failed!
Oczywiście skrypty php nie działają.
Przeszukałem forum ale nie znalazłem nic coby mi pomogło. Jeśli coś przeoczyłem to przepraszam. Proszę o pomoc.
Byłbym zapomniał, jestem zielony.
: 30 października 2009, 19:36
autor: lessmian2
Chyba nie jesteś aż tak zielony że nie umiesz przeczytać komunikatu, ew. użyć translatora lub słownika.
targenor pisze:Syntax error on line 14 of /etc/apache2/sites-enabled/000-default
Wklej zawartość tego pliku.
: 30 października 2009, 20:11
autor: targenor
No tak. W pliku tym wkleiłem wcześniej pewną linię (sam już nie wiem skąd to wziąłem) i zapomniałem o tym. Po usunięciu jej i restartowaniu apache otrzymuję komunikat:
Kod: Zaznacz cały
debian:/home/targenor# /etc/init.d/apache2 restart
Restarting web server: apache2[Fri Oct 30 20:02:56 2009] [warn] The Alias directive in /etc/apache2/sites-enabled/phpmyadmin at line 3 will probably never match because it overlaps an earlier Alias.
apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
[Fri Oct 30 20:02:56 2009] [warn] The Alias directive in /etc/apache2/sites-enabled/phpmyadmin at line 3 will probably never match because it overlaps an earlier Alias.
apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
Zawartość pliku /etc/apache2/sites-enabled/phpmyadmin:
Kod: Zaznacz cały
# phpMyAdmin default Apache configuration
Alias /phpmyadmin /usr/share/phpmyadmin
<Directory /usr/share/phpmyadmin>
Options Indexes FollowSymLinks
DirectoryIndex index.php
# Authorize for setup
<Files setup.php>
# For Apache 1.3 and 2.0
<IfModule mod_auth.c>
AuthType Basic
AuthName "phpMyAdmin Setup"
AuthUserFile /etc/phpmyadmin/htpasswd.setup
</IfModule>
# For Apache 2.2
<IfModule mod_authn_file.c>
AuthType Basic
AuthName "phpMyAdmin Setup"
AuthUserFile /etc/phpmyadmin/htpasswd.setup
</IfModule>
Require valid-user
</Files>
<IfModule mod_php4.c>
AddType application/x-httpd-php .php
php_flag magic_quotes_gpc Off
php_flag track_vars On
php_flag register_globals Off
php_value include_path .
</IfModule>
<IfModule mod_php5.c>
AddType application/x-httpd-php .php
php_flag magic_quotes_gpc Off
php_flag track_vars On
php_flag register_globals Off
php_value include_path .
</IfModule>
</Directory>
Po 10 minutach
Wszystko w porządku. Skrypty działają.
Przepraszam za zawracanie głowy. Jestem jednak ciekawy co oznacza komunikat z konsoli.
: 30 października 2009, 21:17
autor: lessmian2
targenor pisze:The Alias directive in /etc/apache2/sites-enabled/phpmyadmin at line 3 will probably never match because it overlaps an earlier Alias
Ni mniej ni więcej, masz już zdefiniowany taki alias. Zapewne w pliku
/etc/apache2/conf.d/phpmyadmin który jest tworzony przy instalacji
phpMyAdmina z paczki.
targenor pisze:Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
Dopisz sobie dyrektywę
np. do
apache2.conf lub
httpd.conf.
: 30 października 2009, 21:39
autor: targenor
OK. Dziękuję serdecznie.
Temat do zamknięcia.