Re: stupied userspace programs or kernel bug ?

From: Mark Watts
Date: Wed Jul 07 2004 - 09:20:57 EST


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1


> Hello ;
> That is a problem:
> linux#ifconfig eth0 192.168.1.1

Because you didn't specify a netmask, it defaulted to 255.255.255.0

> linux#ifconfig lo:1 192.168.1.100 netmask 255.255.255.255 up

Although you specified a tighter netmask here, the routing table is such that
192.168.1.0/24 is routed out eth0, overriding the fact that 1.100 is on lo:1

I'll bet the kernel responds to the ICMP echo request because it knows it
holds the IP for 1.100 so it should respond, yet its outbound routing tells
it to respond via eth0. (somone connect me if I'm wrong)

This is probably a side effect of having two interfaces on the same subnet,
and having the /24 subnet higher up the routing rable than the /32 host.

I believe the behaviour you are seeing is 'by design' although the merits of
this have been discussed to death in the past (IIRC)

Mark.

- --
Mark Watts
Senior Systems Engineer
QinetiQ Trusted Information Management
Trusted Solutions and Services group
GPG Public Key ID: 455420ED

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFA7AVuBn4EFUVUIO0RAlXpAJ9I1FBUhqDDgV3Tvs53NjSM9BQq9QCeIVeu
f4Jzs0L/LlvjOsm8CcMNoJs=
=/jLZ
-----END PGP SIGNATURE-----
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/