Adding 2 Elastic IPS in a EC2

  • Create a routing table, I am using the name  eth1_route

echo ‘2 eth1_route’ >> /etc/iproute2/rt_tables

  • Create the interface configuration /etc/network/interfaces

vi /etc/network/interfaces

auto eth1
iface eth1 inet static
address 172.31.100.5
netmask 255.255.255.0
network 172.31.100.0
broadcast 172.31.100.255
up ip route add default via 172.31.100.1 dev eth1 table eth1_route
up ip rule add from 172.31.100.0/24 lookup eth1_route prio 1000

Done!

  1. Leave a comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: