LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Ip Alias problem (https://www.linuxquestions.org/questions/linux-networking-3/ip-alias-problem-462603/)

DarkSun4241 07-10-2006 08:34 AM

Ip Alias problem
 
I having problem with fedora core 5 and ip aliasing. This machine is used as a email server and dns server. The dns server is the on eth0:1. The problem is this interface seem to be going up and down. One minute I can get to it from the outside world and next I can't.
I thought that it maybe be firewall/router but the I have seen the same problem with a machine on the same subnet. I copy this ifcfg file from the old fedora core 1 machine. It never gave me any problems before.

ifcfg-eth0:1
DEVICE=eth0:1
BOOTPROTO=static
IPADDR=XXX.xxx.xxx.xxx
NETMASK=255.255.255.xxx
ONBOOT=yes
GATEWAY=xxx.xxx.xxx.xxx
TYPE=Ethernet
USERCTL=no
PEERDNS=no


eth0 Link encap:Ethernet HWaddr 00:07:E9:04:D2:98
inet addr:xxx.xxx.xxx.xxx Bcast:xxx.xxx.xxx.xxx Mask:255.255.255.xxx
inet6 addr: fe80::207:e9ff:fe04:d298/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:23036582 errors:0 dropped:0 overruns:0 frame:0
TX packets:5467666 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:2816637588 (2.6 GiB) TX bytes:1485310672 (1.3 GiB)
Base address:0x2040 Memory:fe6c0000-fe6e0000

eth0:1 Link encap:Ethernet HWaddr 00:07:E9:04:D2:98
inet addr:xxx.xxx.xxx.xxx Bcast:xxx.xxx.xxx.xxx Mask:255.255.255.xxx
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Base address:0x2040 Memory:fe6c0000-fe6e0000

eth1 Link encap:Ethernet HWaddr 00:07:E9:04:D2:99
inet addr:192.168.0.42 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::207:e9ff:fe04:d299/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:78900510 errors:0 dropped:0 overruns:0 frame:0
TX packets:63003691 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:100
RX bytes:447790209 (427.0 MiB) TX bytes:480741600 (458.4 MiB)
Base address:0x2000 Memory:fe6e0000-fe700000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:3228279 errors:0 dropped:0 overruns:0 frame:0
TX packets:3228279 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:596852978 (569.2 MiB) TX bytes:596852978 (569.2 MiB)

Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
xxx.xxx.xxx.xxx * 255.255.255.128 U 0 0 0 eth0
xxx.xxx.xxx.xxx * 255.255.255.0 U 0 0 0 eth1
xxx.xxx.xxx.xxx * 255.255.0.0 U 0 0 0 eth1
default xxx-xxx-xxx-xxx.s 0.0.0.0 UG 0 0 0 eth0

osor 07-11-2006 05:29 PM

Instead of ip aliasing, I think you might want to make VLAN devices (where each device responds to a separate MAC address, but there is only one physical device):
Code:

$ modprobe 8021q # This step may or may not be necessary, depending on your kernel
$ vconfig add eth0 1
$ ip link set dev eth0.1 address 00:07:E9:04:D2:9a # Change this to a MAC address whose uniqueness you can be pretty sure of

Now you have (virtually) two separate devices (with different MAC's) that can be configured (ip, mask, bcast, etc.) completely independently of each other. See if that helps.


All times are GMT -5. The time now is 02:58 PM.