[CentOS] Sending traffic through Secondary IP Address

Al Sparks data345 at yahoo.com
Mon Mar 5 20:09:21 UTC 2007


I have set up a secondary IP address in the same network as my primary.

So 
   eth0: 192.168.100.29 netmask 255.255.255.0
   eth0:0 192.168.100.45 netmask 255.255.255.0

And indeed when I invoke an apache instance that listens on the secondary IP address/interface it works, and it also makes it outside the LAN since the default gateway is defined in the routing tables for 192.168.100.0/24.

But I'd like to be able to send out some sort of broadcast on the network from that secondary interface so that the arp tables on various devices on the network get updated.

How would I, say, use nmap to do something like that?  Is there a generic way to force a particular program to use a secondary IP address instead of the default primary?

Obviously, something like BIND or Apache httpd has that hardcoded in so that you can tell them to use secondaries via their configuration files.

But how about those programs that don't?
    === Al





More information about the CentOS mailing list