IP alias - SIOCSIFFLAGS: Cannot assign requested address
Hi,
I'm trying to set up IP alias on one NIC for MIMO (Nanostation M5) administration and network monitoring. There is one cable from MIMO to router and router network interface is configured for outer network. It works fine, but I can't set IP alias eth0:0 Code:
root@router:~# ifconfig eth0:0 172.16.172.1 netmask 255.255.255.0 up Code:
root@router:~# ifconfig eth0:0 up ifconfig: Code:
eth0 Link encap:Ethernet HWaddr 00:1A:4D:6E:B0:99 |
tried this now at home: seems like that error is misleading as the interface responds fine
Code:
# ifconfig eth1 maybe, also for you, it's only a matter of omitting the "up". |
Well, the "SIOCSIFFLAGS: Cannot assign requested address" error was probably caused by my IP address manipulation via ip tool. I tried to set IP address via 'ip' before, in case it would work
Code:
$ ip address add 172.16.172.1/24 dev eth0 Now I can assign address to eth0:0 and ifconfig recognizes it Code:
eth0 Link encap:Ethernet HWaddr 00:1A:4D:6E:B0:99 Code:
root@router:~# ping 172.16.172.31 Of course I tried Google, but all I came across was "is your cable plugged in?", "does your NIC actually work?", etc. I'm pretty sure wiring and NIC are OK, cause there is working network over eth0, but I can't completely rule out hardware malfunction. |
Eventually I figured it out. Firewall rules were causing trouble
Code:
iptables -A OUTPUT -p all -s $outer_ip -j ACCEPT Code:
iptables -A OUTPUT -p all -s 172.16.172.1 -j ACCEPT |
All times are GMT -5. The time now is 01:38 AM. |