PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : Das seltsame Apache-Problem...



Ypsilon
09.07.02, 17:37
Hallo,
ich habe hier den Apache 1.3.26 installiert und konfiguriert.
Der LogLevel steht auf "debug".

Wenn ich den Apache starte, schreibt er in das Logfile:



[Tue Jul 9 18:49:36 2002] [info] mod_unique_id: using ip addr 127.0.0.1
[Tue Jul 9 18:49:37 2002] [info] mod_unique_id: using ip addr 127.0.0.1
[Tue Jul 9 18:49:38 2002] [info] created shared memory segment #2719748
[Tue Jul 9 18:49:38 2002] [notice] Apache/1.3.26 (Unix) configured -- resuming normal operations
[Tue Jul 9 18:49:38 2002] [info] Server built: Jun 19 2002 05:51:45
[Tue Jul 9 18:49:38 2002] [notice] Accept mutex: sysvsem (Default: sysvsem)


Und beim Beenden



[Tue Jul 9 18:49:43 2002] [info] removed PID file /var/run/httpd.pid (pid=796)
[Tue Jul 9 18:49:43 2002] [notice] caught SIGTERM, shutting down


Also nichts Ungewöhnliches, oder?

Aber ich kann ihn einfach nicht ansprechen.

wenn ich http://127.0.0.1 im Browser aufrufe kommt nach ner Weile ein "Connection refused" oder so, also nichts.

http://localhost/ das Selbe.

es ist zum Verrücktwerden..

Liegt das vielleicht an irgendwelchen Routing-Einstellungen oder so?

Bitte helft mir, ich schlag mich damit schon ewig rum... :ugly:

msi
09.07.02, 17:40
versuch mal in der apache conf (/etc/apache/httpd.conf)
ServerName auf den Namen deines Rechners zu setzen!

Ypsilon
09.07.02, 18:37
Hat nichts gebracht...
Ich glaube dass meine Kiste ganz allgemein ein Problem hat was Netzwerkdinge wie Routing, etc. angeht...

Beispiel wenn ich online bin (üner ippp0 mit ISDN)m und gebe ein "ping localhost",
dann krieg ich folgendes:



root@/:#> ping localhost
PING localhost (127.0.0.1): 56 octets data

--- localhost ping statistics ---
5 packets transmitted, 0 packets received, 100% packet loss



Und wenn ich nicht online bin,
das hier:



root@/:#> ping localhost
PING localhost (127.0.0.1): 56 octets data
sendto: Network is unreachable
ping: sent 64 octets to localhost, ret=-1
sendto: Network is unreachable
ping: sent 64 octets to localhost, ret=-1
sendto: Network is unreachable
ping: sent 64 octets to localhost, ret=-1
sendto: Network is unreachable
ping: sent 64 octets to localhost, ret=-1
sendto: Network is unreachable
ping: sent 64 octets to localhost, ret=-1

--- localhost ping statistics ---
5 packets transmitted, 0 packets received, 100% packet loss


"route" gibt wenn ich online bin folgendes aus:



root@/:#> route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
62.225.245.0 * 255.255.255.0 U 0 0 0 ippp0
default 62.225.245.129 0.0.0.0 UG 0 0 0 ippp0


Und wenn ich offline bin, das hier:



root@/:#> route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
62.225.245.0 * 255.255.255.0 U 0 0 0 ippp0



Irgendwie denke ich dass da ganz einfach was faul ist und irgendwas einfach "fehlt" bzw. nicht konfiguriert ist.

Außer in /etc/resolv.conf nen DNS eingetragen hab ich sonst überhaupt nichts netzwerkrelevantes bewusst konfiguriert (außer natürlich dem Inet-Zugeng per ISDN mit isdn4linux).

msi
09.07.02, 18:50
was bringt ifconfig ?

Ypsilon
09.07.02, 20:12
root@/:#> ifconfig
ippp0 Link encap:Point-to-Point Protocol
inet addr:62.157.84.97 P-t-P:193.158.135.249 Mask:255.0.0.0
UP POINTOPOINT RUNNING NOARP MTU:1500 Metric:1
RX packets:11590 errors:0 dropped:0 overruns:0 frame:0
TX packets:13087 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:30
RX bytes:6930795 (6.6 Mb) TX bytes:2950843 (2.8 Mb)

[HO]Xerxes
09.07.02, 20:16
schau mal in der /etc/hosts nach, ob da der localhost drine steht. und wenn du nene dns hast, schau auch da nach, ob localhost eingetragen ist.
und hast du schonmal versucht, statt 127.0.0.1 einfach 192.168.0.1 (oder was auch immer deine "echte" IP ist) einzutippen? das prob., dass er den locahost refused hat, die normale ip aber ran gelassen hat, hatte ich auch mal...

Ypsilon
09.07.02, 20:28
Also in /etc/hosts steht der localhost drin.

In der /etc/resolv.conf steht jedoch nur der DNS, wie muss ich da das localhost eintragen?

Woher weiß ich eigentlich was meine "echte" private IP ist?
Ich meine ich hab kein Netzwerk, und wurde damit noch nie konfrontiert ;)

Ypsilon
09.07.02, 20:38
In der /etc/hosts stand vorher "127.0.0.1 linux.local linux",
ich hab das geändert auf "192.168.0.1 linux.local linux"

Und jetzt funzt zumindest ein "ping 192.168.0.1" wenn ich online bin.
Wenn ich offline bin, kommt immer noch "network is unreachable".

Der Apache läuft immernoch nicht...

msi
09.07.02, 20:43
bei dir gibt es kein loopbackdevice
so siehts bei mir (router) aus:
eth0 Link encap:Ethernet HWaddr 00:50:BA:B4:01:5D
inet addr:192.168.0.1 Bcast:192.168.0.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:122990 errors:0 dropped:0 overruns:0 frame:0
TX packets:209881 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:100
Interrupt:11 Base address:0xfc00

eth1 Link encap:Ethernet HWaddr 00:30:84:74:6A:2C
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:179930 errors:0 dropped:0 overruns:0 frame:0
TX packets:120917 errors:0 dropped:0 overruns:0 carrier:0
collisions:52 txqueuelen:100
Interrupt:10 Base address:0x4800

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:9974 errors:0 dropped:0 overruns:0 frame:0
TX packets:9974 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0

ppp0 Link encap:Point-to-Point Protocol
inet addr:217.224.170.158 P-t-P:217.5.98.10 Mask:255.255.255.255
UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1492 Metric:1
RX packets:129991 errors:0 dropped:0 overruns:0 frame:0
TX packets:76787 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:3


ppp0 = dsl bei dir ippp0
eth0 ist lan netzwerk
eth1 ist dsl (ppp0)
lo ist loopback

mach das:

ifconfig lo 127.0.0.1 up
in /etc/hosts muss
das mit localhost 127.0.0.1 drinnenstehen.

versuchs jetzt nochmal

panzi
09.07.02, 20:50
Würd' sagen deine "echte" IP-Adr. ist: 62.157.84.97

Is das nicht ne Class-A (od. B, will jetzt nicht nachdenken, jedenfalls nicht C) Adresse????

[HO]Xerxes
10.07.02, 11:39
@Ypsilon: das es bei dir funktioniert, wenn du online bist, liegt daran, dass du dann auf einen nameserver zu greifen kannst (der steht in der resolve.conf)
und steht in deiner hosts neben dem "192.168.0.1 linux.local linux" auch ein "127.0.0.1 localhost" drin?
aber unter linux oder linux.local solltest du deinen rechner eigentlich immer erreichen können, auch wenn du nicht online bist.
achja. schau mal in der httpd.conf nach, wie da dein server heißt. trage da mal 127.0.0.1 oder localhost ein. oder auch linux.local (wenn dein rechner so heißt).
aber der localhost müsste es auf deinem rechner eigentlich tun, wenn du keine netzwerkkarte drin hast..

Ypsilon
10.07.02, 12:46
"ifconfig lo 127.0.0.1 up" war die Lösung.
Nachdem ich das ausgeführt habe, funzt das Pingen von localhost sowohl on- als auch offline und mein Apache funzt. :cool:
Ich hab mir das dann gleich in mein ISDN-Bootskript eingetragen.

Dieses Forum rult wirklich :D