Apache überträgt keine daten ??

Apache, Lighttpd, nginx, Cherokee
Post Reply
philipps.
Posts: 26
Joined: 2004-03-19 11:26
 

Apache überträgt keine daten ??

Post by philipps. »

Hallo,
ich kämpfe nun seit 2 tagen mit folgendem Problem:

Ich bin dummerweise auf die Idee gekommen meinen Apache auf Apache2 upzudaten.
Alles gut und schön, nur leider überträgt mein Apache2 keine Daten an den Client.

Rufe ich z.b. ein Jpg auf erscheint folgender Fehler :
The image â??http://DOMAIN/tux-large.jpgâ? cannot be displayed, because it contains errors.

Rufe ich eine html Datei auf sehe ich gähnende leere.

Mein Vhost sieht wie folgt aus:

Code: Select all

NameVirtualHost *
<VirtualHost *>
        ServerAdmin bla@bla

        DocumentRoot /var/www/root/html
        <Directory />
                Options FollowSymLinks
                AllowOverride None
        </Directory>

        #<Directory /var/www/root/>
        #       Options Indexes FollowSymLinks MultiViews
        #       AllowOverride None
        #       Order allow,deny
        #       allow from all
        # This directive allows us to have apache2's default start page
        # in /apache2-default/, but still have / go to the right place
        #       RedirectMatch ^/$ /html/
        #</Directory>

        ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
        <Directory "/usr/lib/cgi-bin">
                AllowOverride None
                Options ExecCGI -MultiViews +SymLinksIfOwnerMatch
                Order allow,deny
                Allow from all
        </Directory>

        ErrorLog /var/log/apache2/error.log

        # Possible values include: debug, info, notice, warn, error, crit,
        # alert, emerg.
        LogLevel warn

        CustomLog /var/log/apache2/access.log combined
        ServerSignature On

    Alias /doc/ "/usr/share/doc/"
    <Directory "/usr/share/doc/">
        Options Indexes MultiViews FollowSymLinks
        AllowOverride None
        Order deny,allow
        Deny from all
        Allow from 127.0.0.0/255.0.0.0 ::1/128
    </Directory>

</VirtualHost>
Die Verzeichnisrechte liegen bei 775 und www-data:www-data .

Hat jemand nen Tip wo ich meinen Fehler finden kann ?

Gruß Philipp
fox-t.c
Posts: 14
Joined: 2005-03-22 08:41
 

Re: Apache überträgt keine daten ??

Post by fox-t.c »

versuch erstmal ob der apache überhauot richtig läuft sprich du hast eine beispiel konfiguration wie man ein Virtual host definiert mach es erstmal so und dann kannst du deine Vhost immer nach und nach erweiter dann findest du auch den fehler. woran es liegt weiß ich auch nicht für mich sieht dein konfig richtig aus aber versuche es mal mit stupiden debugging.
philipps.
Posts: 26
Joined: 2004-03-19 11:26
 

Re: Apache überträgt keine daten ??

Post by philipps. »

also Fehlermeldungen wie 404 werden problemlos ausgegeben, auch ein directory listing ist möglich aber ich kann keine dateien öffenen/ausgeben.
mausgreck
Posts: 84
Joined: 2005-03-19 17:22
 

Re: Apache überträgt keine daten ??

Post by mausgreck »

Was sagen die Standardtests?

> tail -f /var/log/apache2/access.log
> tail -f /var/log/apache2/error.log
> telnet DOMAIN 80<enter>
GET /filename.jpg HTTP/1.1<enter>
Host: DOMAIN<enter>
<enter>
philipps.
Posts: 26
Joined: 2004-03-19 11:26
 

Re: Apache überträgt keine daten ??

Post by philipps. »

mausgreck wrote:Was sagen die Standardtests?

> tail -f /var/log/apache2/access.log
> tail -f /var/log/apache2/error.log
> telnet DOMAIN 80<enter>
GET /filename.jpg HTTP/1.1<enter>
Host: DOMAIN<enter>
<enter>

Code: Select all

access.log :
0.138.120.218 - - [22/Mar/2005:13:11:06 +0100] "GET /index.html HTTP/1.1" 206 350 "-" "Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7) Gecko/20040803 Firefox/0.9.3"
80.138.120.218 - - [22/Mar/2005:13:12:07 +0100] "GET /index.html HTTP/1.1" 206 350 "-" "Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7) Gecko/20040803 Firefox/0.9.3"
80.138.120.218 - - [22/Mar/2005:13:14:46 +0100] "GET /index.html HTTP/1.1" 206 350 "-" "Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7) Gecko/20040803 Firefox/0.9.3"

Code: Select all

[Tue Mar 22 08:58:00 2005] [warn] child process 10111 still did not exit, sending a SIGTERM
[Tue Mar 22 08:58:00 2005] [notice] caught SIGTERM, shutting down
[Tue Mar 22 08:58:01 2005] [notice] Apache/2.0.53 (Debian GNU/Linux) configured -- resuming normal operations
[Tue Mar 22 08:58:05 2005] [error] [client 80.138.120.218] File does not exist: /var/www/root/html/var
[Tue Mar 22 08:58:52 2005] [error] [client 207.46.98.112] File does not exist: /var/www/root/html/robots.txt
also eigentlich auch nichts woraus sich was schließen lässt.

Code: Select all

36037:/var/log/apache2# telnet langor.de 80
Trying 82.96.83.71...
Connected to langor.de.
Escape character is '^]'.
GET /index.html HTTP/1.1

HTTP/1.1 400 Bad Request
Date: Tue, 22 Mar 2005 12:34:52 GMT
Server: Apache/2.0.53 (Debian GNU/Linux)
Content-Length: 315
Connection: close
Content-Type: text/html; charset=iso-8859-1

<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>400 Bad Request</title>
</head><body>
<h1>Bad Request</h1>
<p>Your browser sent a request that this server could not understand.<br />
</p>
<hr>
<address>Apache/2.0.53 (Debian GNU/Linux) Server at www.langor.de Port 80</address>
</body></html>
Connection closed by foreign host.
der fehler 400 wird mir im firefox leider nicht angezeigt.

mfg
Philipp
superuser1
Posts: 291
Joined: 2003-11-26 18:43
Location: earth
 

Re: Apache überträgt keine daten ??

Post by superuser1 »

Hi...

ändere mal bitte folgendes in deiner VHost-Direktive:

Code: Select all

<Directory /var/www/root/html/>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride None
        Order allow,deny
        allow from all
        # This directive allows us to have apache2's default start page
        # in /apache2-default/, but still have / go to the right place
        # RedirectMatch ^/$ /html/
</Directory>
&& apache2ctl restart

:roll:
philipps.
Posts: 26
Joined: 2004-03-19 11:26
 

Re: Apache überträgt keine daten ??

Post by philipps. »

leider keine veränderung.
fehler bleibt bestehen.

mfg
philipp
mausgreck
Posts: 84
Joined: 2005-03-19 17:22
 

Weird!

Post by mausgreck »

Der 400-Fehler kommt, weil du den Host:-Header vergessen hast. Ich habe mir mal erlaubt, das zu testen und erstaunlicherweise stimmt es genau mit deiner Beschreibung überein:

Code: Select all

$ telnet ########.de 80
Trying ###.###.###.###...
Connected to ########.de.
Escape character is '^]'.
GET /index.html HTTP/1.1
Host: ########.de

HTTP/1.1 200 OK
Date: Tue, 22 Mar 2005 13:13:34 GMT
Server: Apache/2.0.53 (Debian GNU/Linux)
Last-Modified: Tue, 22 Mar 2005 11:17:36 GMT
ETag: "1d1200b-15e-fde15400"
Accept-Ranges: bytes
Content-Length: 350
Content-Type: text/html

Connection closed by foreign host.
Huch? Er sagt zwar Content-Length: 350 (ist index.html 350 bytes groß?), und schliesst dann aber einfach die Connection!? Das sehe ich auch zum ersten mal...
mausgreck
Posts: 84
Joined: 2005-03-19 17:22
 

Re: Apache überträgt keine daten ??

Post by mausgreck »

Nur interessenshalber:
was sagt ein "ps aux | grep www-data" vor und nach einem Zugriff? Vielleicht schmiert ja der Prozess beim Ausliefern ab?
philipps.
Posts: 26
Joined: 2004-03-19 11:26
 

Re: Apache überträgt keine daten ??

Post by philipps. »

Code: Select all

36037:/etc/apache2/sites-available# ps aux | grep www-data
www-data 22904  0.0  0.0  4060 1548 ?        S    Mar21   0:01 proftpd: (accepting connections)
www-data 11455  0.0  0.0  7368 2552 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11456  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11458  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11460  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11461  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11462  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11457  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11463  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11464  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11466  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11467  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11468  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11469  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11470  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11471  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11472  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11473  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11474  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11475  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11476  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11477  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11478  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11479  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11480  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11481  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11482  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11483  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11484  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11485  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11486  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11487  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11488  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11489  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11490  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11491  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11492  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11493  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11494  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11495  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11496  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11497  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11498  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11499  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11500  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11501  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11502  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11503  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11504  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11505  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11506  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11507  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11508  0.0  0.0 62872 3004 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11509  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11510  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11511  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11512  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
www-data 11513  0.0  0.0 62872 2892 ?        S    15:28   0:00 /usr/sbin/apache2 -k start -DSSL
root     12301  0.0  0.0  3076  676 pts/0    R    15:29   0:00 grep www-data
dies ist nach einem zugriff, vorher siehts aber identisch aus.

jepp die index.html ist 350byte .
mausgreck
Posts: 84
Joined: 2005-03-19 17:22
 

Re: Apache überträgt keine daten ??

Post by mausgreck »

Naja, interessant wäre gewesen, ob einer dieser (vielen!) Prozessen verschwindet, also z.B:

$ ps -eo "%p %U %c %a" |grep www-data|grep -v grep|sort -n > x
<ein paarmal index.html mit dem browser oder mit wget aufrufen>
$ ps -eo "%p %U %c %a" |grep www-data|grep -v grep|sort -n > y
$ diff -u x y

Wie gesagt, das sieht wirklich so aus, als ob der Prozess beim Ausliefern der Seite abschmiert. Vielleicht hat es da irgendwas mit inkompatiblen Versionen? Ich würde mal alle Module ausschalten, alle restlichten Apache1-Pakete entfernen und alle Apache2-Pakete updaten. Seltsam ist das schon,,,
philipps.
Posts: 26
Joined: 2004-03-19 11:26
 

Re: Apache überträgt keine daten ??

Post by philipps. »

da ich nach

diff -u x y

keine ausgabe erhalte gehe ich davon aus das alles identisch ist.

ich hab bald keine lust mehr.
philipps.
Posts: 26
Joined: 2004-03-19 11:26
 

Re: Apache überträgt keine daten ??

Post by philipps. »

Nach einer erfolgreichen deinstallation des Apache2 hatte ich innerhalb von 20minuten den apache1 wieder installiert und voll lauffähig.

vieleicht muss ich dazu sagen das ich einen Limis VServer habe, aber auch nach einer kompletten deinstallation beider apachen und neuinstallation wollte sich der apache2 nicht dazubewegen lassen Daten zu übertragen.

Vielen Dank,

Mfg
Philipp
Post Reply