PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : Apache2 status "unused"



Emmermacher
10.01.13, 13:55
Hallo.

Zum Apache2.2.3 habe ich eine Frage an euch.
Server ist SLES 10 Sp4

Beim Starten bekommt man diese Meldung:
mail2:/ # /etc/init.d/apache2 restart
Syntax OK
Starting httpd2 (prefork) (98)Address already in use: make_sock: could not bind to address 10.x.x.y:80
no listening sockets available, shutting down
Unable to open logs
startproc: exit status of parent of /usr/sbin/httpd2-prefork: 1
done

Ein lsof -i :80 liefert
mail2:/ # lsof -i :80
COMMAND PID USER FD TYPE DEVICE SIZE NODE NAME
httpd2-pr 5505 root 3u IPv4 15845 TCP mydomain.de:http (LISTEN)
httpd2-pr 5761 nobody 3u IPv4 15845 TCP mydomain.de:http (LISTEN)
httpd2-pr 5763 nobody 3u IPv4 15845 TCP mydomain.de:http (LISTEN)
httpd2-pr 5880 nobody 3u IPv4 15845 TCP mydomain.de:http (LISTEN)
httpd2-pr 6024 nobody 3u IPv4 15845 TCP mydomain.de:http (LISTEN)
httpd2-pr 6028 nobody 3u IPv4 15845 TCP mydomain.de:http (LISTEN)
httpd2-pr 6029 nobody 3u IPv4 15845 TCP mydomain.de:http (LISTEN)
httpd2-pr 6090 nobody 3u IPv4 15845 TCP mydomain.de:http (LISTEN)
httpd2-pr 6369 nobody 3u IPv4 15845 TCP mydomain.de:http (LISTEN)
httpd2-pr 6371 nobody 3u IPv4 15845 TCP mydomain.de:http (LISTEN)
httpd2-pr 6437 nobody 3u IPv4 15845 TCP mydomain.de:http (LISTEN)

Ursprünglich war auf dem Server das DMS Knowledgetree installiert.
Das wurde aber auf die "normalen" Dienste umgestellt, damit man wieder updates nutzen konnte.

In der httpd.conf ist eingetragen
Listen 10.x.x.y:80
Alle VirtualHosts *:80

Die Includes auf listen.conf und default.server.conf sind nicht vorhanden.
Die Datei entspricht dem 1.3er Format. So braucht man nicht ständig hin und her zu springen.

Wo kann ich hier mit der Fehlersuche anfangen?

Vielen dank im voraus für Eure Antworten.

LG

Dirk Emmermacher

corresponder
10.01.13, 14:21
warscheinlich läuft der apache noch.
kann auch sein, dass die sock datei beim letzten stop des apache nicht gelöscht wurde.
der rechner hat die IP 10.x.x.y? in der /etc/hosts?

netstat -an |grep LISTEN
sagt dir, ob der apache noch lauscht.

gruss

c.

Emmermacher
10.01.13, 14:39
Hallo c.

Danke für die Antwort.

Den Apache habe ich mit /etc/init.d/rcapache2 stop angehalten.
Ein netstat -an brachte hervor, das noch ein httpd Prozess lief.
Den Prozes habe ich dann gekillt und noch einmal das netstat- na laufen lassen.
Kein Prozess mehr vorhanden.
Den Apache wieder gestartet über /etc/init.d/apache2 start.
Hier kam dann ein "done"
Die Abfrage des Status bringt dann wieder ein "unused".

In der /etc/hosts ist die IP-Adresse mit meheren Namen vorhanden.
10.x.x.y server_a
10.x.x.y server_b
Die mehrfachen IP-Adressen habe ich entfernt.

Ein ps -ef|grep httpd liefert:
root 8161 1 0 14:46 ? 00:00:00 /usr/sbin/httpd2-prefork -f /etc/apache2/httpd.conf
nobody 8162 8161 0 14:46 ? 00:00:00 /usr/sbin/httpd2-prefork -f /etc/apache2/httpd.conf
nobody 8163 8161 0 14:46 ? 00:00:00 /usr/sbin/httpd2-prefork -f /etc/apache2/httpd.conf
nobody 8164 8161 0 14:46 ? 00:00:00 /usr/sbin/httpd2-prefork -f /etc/apache2/httpd.conf
nobody 8165 8161 0 14:46 ? 00:00:00 /usr/sbin/httpd2-prefork -f /etc/apache2/httpd.conf
nobody 8166 8161 0 14:46 ? 00:00:00 /usr/sbin/httpd2-prefork -f /etc/apache2/httpd.conf
nobody 8168 8161 0 14:46 ? 00:00:00 /usr/sbin/httpd2-prefork -f /etc/apache2/httpd.conf



Kann es sein, das versucht wird, den Apache zweimal zu starten?

LG

Dirk

corresponder
10.01.13, 18:18
wie meinst du das, mit den mehreren server ips in der hosts?

gruss

c.

heatwalker
10.01.13, 18:26
Bitte poste mal die httpd.conf. Denn so ist das ein rumstochern im Nebel.

Vermutlich gibt es default Einträge in ./vhosts.d welche gestartet werden.
Ohne genauen Input ist das kristallkugel lesen. :ugly:

Emmermacher
11.01.13, 08:07
Guten Morgen c.

Ein bisschen weiter bin ich mit der Fehlersuche gekommen.
User und Group habe ich geändert. Damit funktioniert auf jeden Fall wieder der Zugriff auf /var/lib/php5.

Was jetzt noch zicken macht, ist phpmayadmin
Das System benutzt wohl zwei php.ini Dateien. Einmal /etc/php5/apache/php.ini und einmal /etc/php5/cli/php.ini.
Hier kommt noch ein Fehler, dass keine Schreibrechte auf session_path gesetzt sind. Die Dateien habe ich verglichen. session.path_save = "/var/lib/php5"
Rechte auf das Verzeichnis 775 wwwrun:www

Trotzdem hier noch mal meine httpd.conf:

ServerRoot "/srv/www"

<IfModule !mpm_winnt.c>
<IfModule !mpm_netware.c>
#LockFile logs/accept.lock
</IfModule>
</IfModule>

<IfModule !mpm_netware.c>
<IfModule !perchild.c>
#ScoreBoardFile logs/apache_runtime_status
</IfModule>
</IfModule>

<IfModule !mpm_netware.c>
PidFile /srv/www/logs/httpd.pid
</IfModule>


Timeout 300


TraceEnable off


KeepAlive On

MaxKeepAliveRequests 0

KeepAliveTimeout 2

<IfModule prefork.c>
StartServers 5
MinSpareServers 5
MaxSpareServers 10
MaxClients 150
MaxRequestsPerChild 0
</IfModule>

<IfModule worker.c>
StartServers 2
MaxClients 150
MinSpareThreads 25
MaxSpareThreads 75
ThreadsPerChild 25
MaxRequestsPerChild 0
</IfModule>

<IfModule perchild.c>
NumServers 5
StartThreads 5
MinSpareThreads 5
MaxSpareThreads 10
MaxThreadsPerChild 20
MaxRequestsPerChild 0
</IfModule>

<IfModule mpm_winnt.c>
ThreadsPerChild 250
MaxRequestsPerChild 0
</IfModule>

<IfModule beos.c>
StartThreads 10
MaxClients 50
MaxRequestsPerThread 10000
</IfModule>

<IfModule mpm_netware.c>
ThreadStackSize 65536
StartThreads 250
MinSpareThreads 25
MaxSpareThreads 250
MaxThreads 1000
MaxRequestsPerChild 0
MaxMemFree 100
</IfModule>

<IfModule mpmt_os2.c>
StartServers 2
MinSpareThreads 5
MaxSpareThreads 10
MaxRequestsPerChild 0
</IfModule>

Listen 10.0.0.2:80



LoadModule actions_module /usr/lib64/apache2-prefork/mod_actions.so
LoadModule alias_module /usr/lib64/apache2-prefork/mod_alias.so
LoadModule auth_basic_module /usr/lib64/apache2-prefork/mod_auth_basic.so
LoadModule authn_file_module /usr/lib64/apache2-prefork/mod_authn_file.so
LoadModule authz_host_module /usr/lib64/apache2-prefork/mod_authz_host.so
LoadModule authz_groupfile_module /usr/lib64/apache2-prefork/mod_authz_groupfile.so
LoadModule authz_default_module /usr/lib64/apache2-prefork/mod_authz_default.so
LoadModule authz_user_module /usr/lib64/apache2-prefork/mod_authz_user.so
LoadModule authn_dbm_module /usr/lib64/apache2-prefork/mod_authn_dbm.so
LoadModule autoindex_module /usr/lib64/apache2-prefork/mod_autoindex.so
LoadModule cgi_module /usr/lib64/apache2-prefork/mod_cgi.so
LoadModule dir_module /usr/lib64/apache2-prefork/mod_dir.so
LoadModule env_module /usr/lib64/apache2-prefork/mod_env.so
LoadModule expires_module /usr/lib64/apache2-prefork/mod_expires.so
LoadModule include_module /usr/lib64/apache2-prefork/mod_include.so
LoadModule log_config_module /usr/lib64/apache2-prefork/mod_log_config.so
LoadModule mime_module /usr/lib64/apache2-prefork/mod_mime.so
LoadModule negotiation_module /usr/lib64/apache2-prefork/mod_negotiation.so
LoadModule setenvif_module /usr/lib64/apache2-prefork/mod_setenvif.so
LoadModule ssl_module /usr/lib64/apache2-prefork/mod_ssl.so
LoadModule suexec_module /usr/lib64/apache2-prefork/mod_suexec.so
LoadModule userdir_module /usr/lib64/apache2-prefork/mod_userdir.so
LoadModule php5_module /usr/lib64/apache2/mod_php5.so

#ExtendedStatus On

<IfModule !mpm_winnt.c>
<IfModule !mpm_netware.c>

# User nobody
User wwwrun
# User apache
# Group -1
# Group apache
Group www
</IfModule>
</IfModule>

ServerAdmin you@example.com

UseCanonicalName Off

DocumentRoot "/srv/www/htdocs"

<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>


# <Directory "/opt/ktdms/knowledgeTree">


UserDir public_html


# Sperren vom Adminbereich SEC
<Directory /srv/www/dom-12/_admin>
AllowOverride All
</Directory>

DirectoryIndex index.php index.html index.html.var

AccessFileName .htaccess

<FilesMatch "^\.ht">
Order allow,deny
Deny from all
</FilesMatch>

TypesConfig conf/mime.types

DefaultType text/plain

<IfModule mod_mime_magic.c>
MIMEMagicFile conf/magic
</IfModule>

HostnameLookups Off

ErrorLog /var/log/apache2/error_log

LogLevel warn


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

# CustomLog /var/log/apache2/access_log combined

ServerTokens ProductOnly

# ServerSignature On
ServerSignature Off

Alias /icons/ "/srv/www/icons/"
Alias /pureFTP/ "/srv/www/pure/"
Alias /awstatsclasses/ "/usr/local/awstats/wwwroot/classes/"
Alias /awstatscss/ "/usr/local/awstats/wwwroot/css/"
Alias /awstatsicons/ "/usr/local/awstats/wwwroot/icon/"
ScriptAlias /awstats/ "usr/local/awstats/wwwroot/cgi-bin/"

<Directory "usr/local/awstats/wwwroot">
Options None
AllowOverride None
Order Allow,Deny
Allow from all
</Directory>

AliasMatch ^/manual(?:/(?:de|en|es|fr|ja|ko|ru))?(/.*)?$ "/srv/www/manual$1"

<Directory "/srv/www/manual">
Options Indexes
AllowOverride None
Order allow,deny
Allow from all

<Files *.html>
SetHandler type-map
</Files>

SetEnvIf Request_URI ^/manual/(de|en|es|fr|ja|ko|ru)/ prefer-language=$1
RedirectMatch 301 ^/manual(?:/(de|en|es|fr|ja|ko|ru)){2,}(/.*)?$ /manual/$1$2
</Directory>

ScriptAlias /cgi-bin/ "/srv/www/cgi-bin/"

<IfModule mod_cgid.c>
</IfModule>

<Directory "/srv/www/cgi-bin">
AllowOverride None
Options None
Order allow,deny
Allow from all
</Directory>

AddIconByEncoding (CMP,/icons/compressed.gif) x-compress x-gzip

AddIconByType (TXT,/icons/text.gif) text/*
AddIconByType (IMG,/icons/image2.gif) image/*
AddIconByType (SND,/icons/sound2.gif) audio/*
AddIconByType (VID,/icons/movie.gif) video/*

AddIcon /icons/binary.gif .bin .exe
AddIcon /icons/binhex.gif .hqx
AddIcon /icons/tar.gif .tar
AddIcon /icons/world2.gif .wrl .wrl.gz .vrml .vrm .iv
AddIcon /icons/compressed.gif .Z .z .tgz .gz .zip
AddIcon /icons/a.gif .ps .ai .eps
AddIcon /icons/layout.gif .html .shtml .htm .pdf
AddIcon /icons/text.gif .txt
AddIcon /icons/c.gif .c
AddIcon /icons/p.gif .pl .py
AddIcon /icons/f.gif .for
AddIcon /icons/dvi.gif .dvi
AddIcon /icons/uuencoded.gif .uu
AddIcon /icons/script.gif .conf .sh .shar .csh .ksh .tcl
AddIcon /icons/tex.gif .tex
AddIcon /icons/bomb.gif core

AddIcon /icons/back.gif ..
AddIcon /icons/hand.right.gif README
AddIcon /icons/folder.gif ^^DIRECTORY^^
AddIcon /icons/blank.gif ^^BLANKICON^^

DefaultIcon /icons/unknown.gif

#AddDescription "GZIP compressed document" .gz
#AddDescription "tar archive" .tar
#AddDescription "GZIP compressed tar archive" .tgz

ReadmeName README.html
HeaderName HEADER.html

IndexIgnore .??* *~ *# HEADER* README* RCS CVS *,v *,t

AddLanguage ca .ca
AddLanguage cs .cz .cs
AddLanguage da .dk
AddLanguage de .de
AddLanguage el .el
AddLanguage en .en
AddLanguage eo .eo
AddLanguage es .es
AddLanguage et .et
AddLanguage fr .fr
AddLanguage he .he
AddLanguage hr .hr
AddLanguage it .it
AddLanguage ja .ja
AddLanguage ko .ko
AddLanguage ltz .ltz
AddLanguage nl .nl
AddLanguage nn .nn
AddLanguage no .no
AddLanguage pl .po
AddLanguage pt .pt
AddLanguage pt-BR .pt-br
AddLanguage ru .ru
AddLanguage sv .sv
AddLanguage zh-CN .zh-cn
AddLanguage zh-TW .zh-tw

LanguagePriority en ca cs da de el eo es et fr he hr it ja ko ltz nl nn no pl pt pt-BR ru sv zh-CN zh-TW

ForceLanguagePriority Prefer Fallback

AddCharset ISO-8859-1 .iso8859-1 .latin1
AddCharset ISO-8859-2 .iso8859-2 .latin2 .cen
AddCharset ISO-8859-3 .iso8859-3 .latin3
AddCharset ISO-8859-4 .iso8859-4 .latin4
AddCharset ISO-8859-5 .iso8859-5 .latin5 .cyr .iso-ru
AddCharset ISO-8859-6 .iso8859-6 .latin6 .arb
AddCharset ISO-8859-7 .iso8859-7 .latin7 .grk
AddCharset ISO-8859-8 .iso8859-8 .latin8 .heb
AddCharset ISO-8859-9 .iso8859-9 .latin9 .trk
AddCharset ISO-2022-JP .iso2022-jp .jis
AddCharset ISO-2022-KR .iso2022-kr .kis
AddCharset ISO-2022-CN .iso2022-cn .cis
AddCharset Big5 .Big5 .big5
# For russian, more than one charset is used (depends on client, mostly):
AddCharset WINDOWS-1251 .cp-1251 .win-1251
AddCharset CP866 .cp866
AddCharset KOI8-r .koi8-r .koi8-ru
AddCharset KOI8-ru .koi8-uk .ua
AddCharset ISO-10646-UCS-2 .ucs2
AddCharset ISO-10646-UCS-4 .ucs4
AddCharset UTF-8 .utf8

AddCharset GB2312 .gb2312 .gb
AddCharset utf-7 .utf7
AddCharset utf-8 .utf8
AddCharset big5 .big5 .b5
AddCharset EUC-TW .euc-tw
AddCharset EUC-JP .euc-jp
AddCharset EUC-KR .euc-kr
AddCharset shift_jis .sjis

AddType application/x-compress .Z
AddType application/x-gzip .gz .tgz

AddHandler type-map var


<Directory "/usr/share/apache2/error">
AllowOverride None
Options IncludesNoExec
AddOutputFilter Includes html
AddHandler type-map var
Order allow,deny
Allow from all
LanguagePriority en cs de es fr it ja ko nl pl pt-br ro sv tr
ForceLanguagePriority Prefer Fallback
</Directory>

ErrorDocument 400 /error/HTTP_BAD_REQUEST.html.var
ErrorDocument 401 /error/HTTP_UNAUTHORIZED.html.var
ErrorDocument 403 /error/HTTP_FORBIDDEN.html.var
ErrorDocument 404 /error/HTTP_NOT_FOUND.html.var
ErrorDocument 405 /error/HTTP_METHOD_NOT_ALLOWED.html.var
ErrorDocument 408 /error/HTTP_REQUEST_TIME_OUT.html.var
ErrorDocument 410 /error/HTTP_GONE.html.var
ErrorDocument 411 /error/HTTP_LENGTH_REQUIRED.html.var
ErrorDocument 412 /error/HTTP_PRECONDITION_FAILED.html.var
ErrorDocument 413 /error/HTTP_REQUEST_ENTITY_TOO_LARGE.html.var
ErrorDocument 414 /error/HTTP_REQUEST_URI_TOO_LARGE.html.var
ErrorDocument 415 /error/HTTP_UNSUPPORTED_MEDIA_TYPE.html.var
ErrorDocument 500 /error/HTTP_INTERNAL_SERVER_ERROR.html.var
ErrorDocument 501 /error/HTTP_NOT_IMPLEMENTED.html.var
ErrorDocument 502 /error/HTTP_BAD_GATEWAY.html.var
ErrorDocument 503 /error/HTTP_SERVICE_UNAVAILABLE.html.var
ErrorDocument 506 /error/HTTP_VARIANT_ALSO_VARIES.html.var

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

BrowserMatch "Microsoft Data Access Internet Publishing Provider" redirect-carefully
BrowserMatch "MS FrontPage" redirect-carefully
BrowserMatch "^WebDrive" redirect-carefully
BrowserMatch "^WebDAVFS/1.[0123]" redirect-carefully
BrowserMatch "^gnome-vfs" redirect-carefully
BrowserMatch "^XML Spy" redirect-carefully
BrowserMatch "^Dreamweaver-WebDAV-SCM1" redirect-carefully

<IfModule mod_ssl.c>
#Include conf/ssl.conf
</IfModule>

NameVirtualHost *:80

AddType application/x-httpd-php .php .phtml

AddType Application/x-httpd-php .php .phtml

<VirtualHost *:80>
ServerAdmin webmaster@dom-01.de
DocumentRoot /srv/www/htdocs
ServerName www2.ntb.local
ErrorLog /var/log/httpd/dom-01-error_log
CustomLog /var/log/httpd/dom-01-access_log combined
</VirtualHost>


<VirtualHost *:80>
ServerAdmin webmaster@dom-02.de
DocumentRoot /srv/www/dom-02
ServerName www.dom-02.de
ServerAlias dom-02.de
ErrorLog /var/log/httpd/dom-02_error.log
CustomLog /var/log/httpd/dom-02_customer.log combined
</VirtualHost>


<VirtualHost *:80>
DocumentRoot /srv/www/dom-03
ServerName www.dom-03.de
ServerAlias dom-03.de
ErrorLog /var/log/httpd/dom-03_error.log
CustomLog /var/log/httpd/dom-03_customer.log combined
</VirtualHost>


<VirtualHost *:80>
DocumentRoot /srv/www/dom-04
ServerName www.dom-04.de
ServerAlias dom-04.de
ErrorLog /var/log/httpd/dom-04_error.log
CustomLog /var/log/httpd/dom-04_customer.log combined
</VirtualHost>


<VirtualHost *:80>
DocumentRoot /srv/www/dom-05
ServerName www.dom-05.de
ServerAlias dom-05.de
ErrorLog /var/log/httpd/dom-05_error.log
CustomLog /var/log/httpd/dom-05_customer.log combined
</VirtualHost>
<VirtualHost *:80>

ServerAdmin webmaster@dom-06.de
DocumentRoot /srv/www/dom-06
ServerName www.dom-06.de
ServerAlias dom-06.de
ErrorLog /var/log/httpd/dom-06_error.log
CustomLog /var/log/httpd/dom-06_customer.log combined
</VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@dom-07.de
DocumentRoot /srv/www/dom-07
ServerName www.dom-07.de
ServerAlias dom-07.de
ErrorLog /var/log/httpd/dom-07_error.log
CustomLog /var/log/httpd/dom-07_customer.log combined
</VirtualHost>

<VirtualHost *:80>
ServerAdmin mailadmin@dom-08.de
DocumentRoot /srv/www/dom-08
ServerName www.dom-08.de
ServerAlias dom-08.de
ErrorLog /var/log/httpd/dom-08.log
CustomLog /var/log/httpd/dom-08_customer.log combined
</VirtualHost>


<VirtualHost *:80>
ServerAdmin webmaster@dom-09.de
DocumentRoot /srv/www/dom-09/belegung
ServerName belegung.dom-09.de
ErrorLog /var/log/httpd/dom-09_belegung_error.log
CustomLog /var/log/httpd/dom-09_belegung_customer.log combined
</VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@dom-09.de
DocumentRoot /srv/www/dom-09
ServerName www.dom-09.de
ServerAlias dom-09.de
ErrorLog /var/log/httpd/dom-09_error.log
CustomLog /var/log/httpd/dom-09_customer.log combined
</VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@dom-10.de
DocumentRoot /srv/www/dom-10
ServerName www.dom-10.de
ErrorLog /var/log/httpd/dom-10_error.log
CustomLog /var/log/httpd/dom-10_customer.log combined
</VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@dom-11.de
DocumentRoot /srv/www/dom-11
ServerName www.dom-11.de
ServerAlias dom-11.de
ErrorLog /var/log/httpd/dom-11_error.log
CustomLog /var/log/httpd/dom-11_customer.log combined
</VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@dom-12.de
DocumentRoot /srv/www/dom-12
ServerName www.dom-12.de
ServerAlias dom-12.de
ErrorLog /var/log/httpd/dom-12_error.log
CustomLog /var/log/httpd/dom-12_customer.log combined
</VirtualHost>

<Directory "/usr/local/awstats/wwwroot">
Options None
AllowOverride None
Order allow,deny
Allow from all
</Directory>



LG

Dirk