The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Special Forums > IP Networking
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #2 (permalink)  
Old 03-05-2009
otheus's Avatar
otheus otheus is offline Forum Staff  
Moderator ala Mode
  
 

Join Date: Feb 2007
Location: Innsbruck, Austria
Posts: 1,886
Two ways. Say the new ip address is 192.168.20.1 and the device to be associated with it is eth0
Code:
ifconfig eth0:1 192.168.20.1 netmask 255.255.255.0
The other way is the new "ip route2" tools, or just "iproute".
Code:
ip addr add 192.168.20.1 dev eth0
Saving this configuration for future use is a separate question and depends greatly on the distribution.