Gentoo Archives: gentoo-user

From: Jordan Woehr <jwoehr1@×××××.net>
To: gentoo-user@l.g.o
Subject: Re: Re: [gentoo-user] Issues pinging localhost and starting apache.
Date: Sun, 25 Nov 2007 05:37:19
Message-Id: 474908C0.7020004@telus.net
In Reply to: Re: [gentoo-user] Issues pinging localhost and starting apache. by Mark Shields
1 Mark Shields wrote:
2 > On Nov 22, 2007 7:45 PM, Jordan Woehr <jwoehr1@×××××.net
3 > <mailto:jwoehr1@×××××.net>> wrote:
4 >
5 > *I first encounter this problem while trying to setup Apache for my
6 > machine. I only want it to run locally on my network. First issue,
7 > I try
8 > to start Apache and have it listen to port 80 but it won't start with
9 > the error:*
10 >
11 > apache2ctl start
12 > * Caching service dependencies
13 > ... [ ok ]
14 > * Starting apache2 ...
15 > (98)Address already in use: make_sock: could not bind to address
16 > 0.0.0.0:80 <http://0.0.0.0:80>
17 > no listening sockets available, shutting down
18 > Unable to open logs
19 >
20 > *The only lines I have added to httpd.conf are as follows:
21 > *
22 > ServerName localhost
23 > Listen 80
24 >
25 > *Having Apache listen on port 8080 instead results in it starting
26 > fine.
27 > Thing is, I'm pretty sure nothing is listening on port 80.*
28 >
29 > netstat -an | grep :80
30 > tcp 0 0 192.168.0.104:56125
31 > <http://192.168.0.104:56125> 66.150.96.119:80
32 > <http://66.150.96.119:80>
33 > ESTABLISHED
34 > tcp 0 0 192.168.0.104:56123
35 > <http://192.168.0.104:56123> 66.150.96.119:80
36 > <http://66.150.96.119:80>
37 > TIME_WAIT
38 > tcp 0 0 192.168.0.104:36115
39 > <http://192.168.0.104:36115> 208.65.201.178:80
40 > <http://208.65.201.178:80>
41 > TIME_WAIT
42 > tcp 0 0 192.168.0.104:45155
43 > <http://192.168.0.104:45155> 205.150.218.4:80
44 > <http://205.150.218.4:80>
45 > ESTABLISHED
46 >
47 > *I was not happy with Apache not starting listening to port 80 but I
48 > started it on 8080 instead. Tried going to localhost:8080 in
49 > firefox
50 > but received an unable to establish connection error.
51 >
52 > From there I went to my hosts file which is as follows
53 >
54 > *127.0.0.1 <http://127.0.0.1> localhost
55 >
56 > *Tried scanning 127.0.0.1 <http://127.0.0.1> with nmap:
57 >
58 > *nmap -sT -PT 127.0.0.1 <http://127.0.0.1>
59 >
60 > Starting Nmap 4.20 ( http://insecure.org <http://insecure.org> )
61 > at 2007-11-22 17:11 MST
62 > Note: Host seems down. If it is really up, but blocking our ping
63 > probes,
64 > try -P0
65 > Nmap finished: 1 IP address (0 hosts up) scanned in 3.342 seconds
66 >
67 > *And now a ping
68 > *
69 > ping -c 5 localhost
70 > PING localhost (127.0.0.1 <http://127.0.0.1>) 56(84) bytes of data.
71 > From 10.132.0.1 <http://10.132.0.1> icmp_seq=1 Destination Net
72 > Unreachable
73 > From 10.132.0.1 <http://10.132.0.1> icmp_seq=3 Destination Net
74 > Unreachable
75 > From 10.132.0.1 <http://10.132.0.1> icmp_seq=4 Destination Net
76 > Unreachable
77 > From 10.132.0.1 <http://10.132.0.1> icmp_seq=5 Destination Net
78 > Unreachable
79 >
80 > --- localhost ping statistics ---
81 > 5 packets transmitted, 0 received, +4 errors, 100% packet loss,
82 > time 4000ms
83 >
84 > *localhost seems to be resolved properly to 127.0.0.1
85 > <http://127.0.0.1> but what I don't
86 > understand is where the 10.132.0.1 <http://10.132.0.1> comes from.
87 > This computer's ip on the
88 > network is 192.168.0.104 <http://192.168.0.104> (static) and my ip
89 > on the internet is
90 > 77.something.something.something (was when I did the ping at least).
91 >
92 > I hope the above is enough information. Suggestions on why Apache
93 > won't
94 > start listening on port 80 and why I can't connect to localhost:8080
95 > from firefox when Apache is running are welcome.
96 >
97 > Thanks
98 > Jordan
99 > *
100 > --
101 > gentoo-user@g.o <mailto:gentoo-user@g.o> mailing list
102 >
103 >
104 > This may sound like a silly question, but is loopback running
105 > (/etc/init.d/lo)?
106 >
107 > --
108 > - Mark Shields
109 This was exactly the problem. I switched from the traditional startup
110 scripts to NetworkManager a while back and I guess NM doesn't handle lo
111 by default. Does anyone happen to know if NM handles the loopback
112 adapter at all?
113 --
114 gentoo-user@g.o mailing list