Gentoo Archives: gentoo-user

From: Stroller <stroller@××××××××××××××××××.uk>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] IP aliasing problem
Date: Thu, 07 Oct 2010 19:53:57
Message-Id: 6618B87A-60A7-493B-BD8D-83C45B9305BA@stellar.eclipse.co.uk
In Reply to: Re: [gentoo-user] IP aliasing problem by BRM
1 On 7 Oct 2010, at 18:51, BRM wrote:
2
3 >> ServerName differently for each VirtualHost. Strangely though, I
4 >> still don't get stats for RX/TX from ifconfig:
5 >>
6 >> eth0 Link encap:Ethernet HWaddr [removed]
7 >> inet addr:1.2.3.1 Bcast:[removed] Mask:255.255.255.248
8 >> UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
9 >> RX packets:923677 errors:0 dropped:0 overruns:0 frame:0
10 >> TX packets:1444212 errors:0 dropped:0 overruns:0 carrier:0
11 >> collisions:0 txqueuelen:1000
12 >> RX bytes:124904402 (119.1 MiB) TX bytes:1880087116 (1.7 GiB)
13 >> Interrupt:40
14 >>
15 >> eth0:1 Link encap:Ethernet HWaddr [removed]
16 >> inet addr:1.2.3.2 Bcast:[removed] Mask:255.255.255.248
17 >> UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
18 >> Interrupt:40
19 >
20 > Remember eth0:1 is an alias for eth0.
21 >
22 > Your above info is slightly wrong in that eth0 should be listed as eth0:0; where
23 > instead ifconfig is showing eth0 generic information and eth0:0 information
24 > combined.
25 > That's probably the source of your confusion.
26
27 On a system running 2.4.25 here I have:
28
29 $ ifconfig
30 eth0 Link encap:Ethernet HWaddr 00:02:A5:1B:01:59
31 inet addr:213.x.y.91 Bcast:213.x.y.95 Mask:255.255.255.248
32 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
33 RX packets:211366804 errors:0 dropped:0 overruns:0 frame:0
34 TX packets:306200382 errors:0 dropped:0 overruns:0 carrier:0
35 collisions:0 txqueuelen:1000
36 RX bytes:1542358934 (1470.9 Mb) TX bytes:1547826181 (1476.1 Mb)
37 Interrupt:20 Base address:0xd000
38
39 eth0:1 Link encap:Ethernet HWaddr 00:02:A5:1B:01:59
40 inet addr:192.168.1.43 Bcast:192.168.255.255 Mask:255.255.255.0
41 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
42 RX packets:211366804 errors:0 dropped:0 overruns:0 frame:0
43 TX packets:306200384 errors:0 dropped:0 overruns:0 carrier:0
44 collisions:0 txqueuelen:1000
45 RX bytes:1542358934 (1470.9 Mb) TX bytes:1547826521 (1476.1 Mb)
46 Interrupt:20 Base address:0xd000
47
48 lo Link encap:Local Loopback
49 ...
50
51
52 The same TX & RX are shown for both interfaces.
53
54 I don't know whether the tools have changed much since those I'm using on this box, but the difference *might* be that Grant's IPs are on the same subnet. I *think* it's possible for the route (as in: `man route`) to configure packets that come in on 1.2.3.2 to be replied to via 1.2.3.1.
55
56 You might set up a spare test box to see how current ifconfig displays packets, comparing aliased addresses on the same and separate subnets.
57
58 Stroller.

Replies

Subject Author
Re: [gentoo-user] IP aliasing problem Grant <emailgrant@×××××.com>