Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I'm struggling to setup virtual eth interface on Suse 12

When I run:

ipconfig eth0:1 10.0.0.2 netmask 255.255.255.0

Output from ifconfig is as expected:

eth0      Link encap:Ethernet  HWaddr 00:01:02:03:04:05
          inet addr:10.0.0.1  Bcast:10.0.24.255  Mask:255.255.255.0

eth0:1    Link encap:Ethernet  HWaddr 00:01:02:03:04:05
          inet addr:10.0.0.2  Bcast:10.0.24.255  Mask:255.255.255.0

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0

However this setup is not persistent. When the system is restarted I can no longer see eth0:1

I tried adding the IPADDR1='10.0.0.2/24' to the /etc/sysconfig/network/if-eth0 config file and that seems to be working fine BUT I cannot see eth0:1 in the ifconfig output ?

am I missing something?

share|improve this question

migrated from serverfault.com Apr 10 at 21:46

This question came from our site for system and network administrators.

1 Answer 1

up vote 0 down vote accepted

After long search I have found the answer: https://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/tree/Documentation/networking/alias.txt

Looks like virtual/alias interfaces are deprecated and should be avoided and one should rather add multiple IP addresses directly to eth0

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.