How to add multiple IP addresses manually?

There are cases where one has to bind multiple ip address to same ethernet card, here are some steps to add them into your network configuration.

# ifconfig

will output all the configured addresses. For example:

eth0: inet addr: Bcast: Mask:
…… and more information.

To add on extra IP addresses type:

# ifconfig eth0:1 netmask

for additional IP addresses, make sure you increment the 1 in eth0:1, for example, a third IP address (third one including your BASE IP) would be added:

# ifconfig eth0:2 netmask

Hope it helps anyone struggling!


Leave a Reply

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

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

Google+ photo

You are commenting using your Google+ 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 )

Connecting to %s