1 |
I rebooted by Gentoo system, and regret it greatly -- some |
2 |
update or other has invalidated my network configuration, |
3 |
and I still don't know how to fix it. (I'm posting this from an |
4 |
Ubuntu machine). |
5 |
|
6 |
This machine's interface to the outside world is eth1 (eth0 |
7 |
exists, but is a local LAN). In /etc/conf.d/net, there was |
8 |
|
9 |
iface_eth1="64.166.164.49 broadcast 64.166.164.55 netmask 255.255.255.248" |
10 |
gateway="eth1/64.166.164.54" |
11 |
|
12 |
This used to work fine. Now it causes complaints about a deprecated syntax |
13 |
and advice to go look in /etc/conf.d/net.example. It also complains |
14 |
that there's |
15 |
no module to provide broadcast or netmask. Moreover, it does not bring up |
16 |
a useable network. Here's the output of route(1) |
17 |
|
18 |
Kernel IP routing table |
19 |
Destination Gateway Genmask Flags Metric Ref Use Iface |
20 |
64.166.164.48 * 255.255.255.248 U 0 0 0 eth1 |
21 |
loopback * 255.0.0.0 U 0 0 0 lo |
22 |
|
23 |
Note the lack of a gateway. |
24 |
|
25 |
I've tried various other things after looking into net.example, and here's |
26 |
the most likely thing I've come up with: |
27 |
|
28 |
config_eth1=( "64.166.164.49/29 brd 64.166.164.55" ) |
29 |
gateway=( "eth1/64.166.164.54" ) |
30 |
|
31 |
This no longer gives me syntax complaints, but also does not bring up a |
32 |
gateway: |
33 |
|
34 |
Kernel IP routing table |
35 |
Destination Gateway Genmask Flags Metric Ref Use Iface |
36 |
64.166.164.48 * 255.255.255.248 U 0 0 0 eth1 |
37 |
loopback * 255.0.0.0 U 0 0 0 lo |
38 |
|
39 |
So I tried going back to tried and true things: ifconfig. I tried this script: |
40 |
ifconfig eth1 down |
41 |
ifconfig eth1 64.166.164.49 netmask 255.255.255.248 |
42 |
ifconfig eth1 up |
43 |
route add 0.0.0.0 gw 64.166.164.54 |
44 |
|
45 |
And now I have a gateway of sorts, but it does not work: |
46 |
|
47 |
Kernel IP routing table |
48 |
Destination Gateway Genmask Flags Metric Ref Use Iface |
49 |
default router 255.255.255.255 UGH 0 0 0 eth1 |
50 |
64.166.164.48 * 255.255.255.248 U 0 0 0 eth1 |
51 |
loopback * 255.0.0.0 U 0 0 0 lo |
52 |
|
53 |
I compared this to the output of route(1) on this Ubuntu box, and notice that |
54 |
the flags contain "H", which means 'the target is a host'. This also happens |
55 |
if I give a netmask of 0.0.0.0 in the route command. I know it's not working |
56 |
because any attempt I've made to send packets beyond the router have |
57 |
failed with "network unreachable", and tcpdump indicates that NO packets |
58 |
were sent. On the other hand, pinging the router itself works, and tcpdump |
59 |
can see it. The router in in the telco CO, not here, and is also used by this |
60 |
Ubuntu machine, so it is not implicated. |
61 |
|
62 |
I also know that the interface card is working locally, because I can get |
63 |
in via ssh from this Ubuntu machine. I cannot get in from beyond the |
64 |
router because the host does not know to send reply packets to the |
65 |
gateway. |
66 |
|
67 |
It appears that I need to have a gateway (so my /etc/conf.d/net needs to |
68 |
do that) and it may need to have the "H" flag off. |
69 |
|
70 |
Can anyone else who uses a static IP setup take a look and see what |
71 |
I'm doing differently? |
72 |
|
73 |
++ kevin |
74 |
|
75 |
-- |
76 |
Kevin O'Gorman, PhD |
77 |
-- |
78 |
gentoo-user@g.o mailing list |