IPaddr2, on stop, if it just removed the last IPv4 address, does
ip link set down
What is the rational behind that?
I see a problem with this, if we have IPv6 addresses on that link
as well.
I understand full well that IPaddr2 on start does a "ip link set up".
The "down" on stop however serves no purpose I can see,
but may cause harm.
I suggest to just remove it.
What am I missing?
Opinons?
Lars
How to reproduce...
# ( ip -o a s dev eth3 ;
OCF_ROOT=/usr/lib/ocf \
OCF_RESKEY_ip=192.168.145.2 \
OCF_RESKEY_nic=eth3 \
OCF_RESKEY_cidr_netmask=255.255.255.0 \
bash -vx /usr/lib/ocf/resource.d/heartbeat/IPaddr2 stop ;
ip -o a s dev eth3 ;
OCF_ROOT=/usr/lib/ocf \
OCF_RESKEY_ip=192.168.145.2 \
OCF_RESKEY_nic=eth3 \
OCF_RESKEY_cidr_netmask=255.255.255.0 \
bash -vx /usr/lib/ocf/resource.d/heartbeat/IPaddr2 start ;
ip -o a s dev eth3
) 2>&1 | tee -a IPaddr2.debug.log
# grep -e "^[0-9]\+:" -e "^. ip link set" IPaddr2.debug.log
4: eth3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP
qlen 1000\ link/ether 00:1b:21:23:95:5e brd ff:ff:ff:ff:ff:ff
4: eth3 inet 192.168.145.2/24 brd 192.168.145.255 scope global eth3
4: eth3 inet6 fe80::21b:21ff:fe23:955e/64 scope link \ valid_lft
forever preferred_lft forever
both ipv4 and ipv6 address running fine.
+ ip link set eth3 down
4: eth3: <BROADCAST,MULTICAST> mtu 1500 qdisc pfifo_fast state DOWN qlen 1000\
link/ether 00:1b:21:23:95:5e brd ff:ff:ff:ff:ff:ff
Doh. Link down.
+ ip link set eth3 up
4: eth3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP
qlen 1000\ link/ether 00:1b:21:23:95:5e brd ff:ff:ff:ff:ff:ff
4: eth3 inet 192.168.145.2/24 brd 192.168.145.255 scope global eth3
4: eth3 inet6 fe80::21b:21ff:fe23:955e/64 scope link tentative \
valid_lft forever preferred_lft forever
There, link is back,
and the ipv6 link scope address will soon leave the tentative state.
This was just an example.
_______________________________________________________
Linux-HA-Dev: [email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/