Security Consulting
  Unix Administration     Firewall     Intrusion Detection     Network Security     Hacking     MORE     HOME    

IP Aliasing

If you need multipel IP addresses on one interface, proceed as follows:
    modprobe ip_alias make sure the ip_alias module is compiled.
    ifconfig eth0 192.168.0.1 Define the first IP address
    ifconfig eth0:0 192.168.0.42 Define the second IP address
    ifconfig eth0:1 192.168.0.100 Define the third IP address
Now add the routes:
    route add -net 192.168.0.0 dev eth0
    route add -host 192.168.0.1 dev eth0
    route add -host 192.168.0.42 dev eth0:0
    route add -host 192.168.0.100 dev eth0:1



CopyLeft (l) 2003 by Raffael Marty