in Debian based distros you can create a sub-interface as follows..
Code:
it-etch:~# cat /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
# allow-hotplug eth0
# iface eth0 inet dhcp
auto eth0
iface eth0 inet static
address 192.168.0.4
netmask 255.255.255.0
gateway 192.168.0.1
network 192.168.0.0
broadcast 192.168.0.255
auto eth0:1
iface eth0:1 inet static
address 10.90.90.1
netmask 255.255.255.0
network 10.90.90.0
broadcast 10.90.90.255
Code:
it-etch:~# ifconfig -a
eth0 Link encap:Ethernet HWaddr 00:1A:A0:08:67:08
inet addr:192.168.0.4 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::21a:a0ff:fe08:6708/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:5695635 errors:0 dropped:0 overruns:0 frame:0
TX packets:338259 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:944543446 (900.7 MiB) TX bytes:36835014 (35.1 MiB)
Interrupt:201
eth0:1 Link encap:Ethernet HWaddr 00:1A:A0:08:67:08
inet addr:10.90.90.1 Bcast:10.90.90.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Interrupt:201
You should add your distro to your profile, to help insure the information you get is most relevant to your distro..