We are in the process of migrating this forum. A new space will be available soon. We are sorry for the inconvenience.

Slow startup, public cloud Ubuntu 14.04 with failoverip


robreiss
2016-02-24, 09:33 AM
I am testing an ovh eg-7 public cloud instance running Ubuntu 14.04 with a FailoverIp attached. When I configured the instance's /etc/network/interfaces file according to the OVH documentation I saw strange behavior upon restart. The restart would take a couple of minutes and the log would show: (notice the cloud-init-nonet failure)

Cloud-init v. 0.7.5 running 'init-local' at Mon, 22 Feb 2016 01:59:27 +0000. Up 7.22 seconds.
cloud-init-nonet[7.33]: waiting 10 seconds for network device
cloud-init-nonet[17.34]: waiting 120 seconds for network device
cloud-init-nonet[137.34]: gave up waiting for a network device.
Cloud-init v. 0.7.5 running 'init' at Mon, 22 Feb 2016 02:01:37 +0000. Up 137.47 seconds.

I was able to fix this by changing how /etc/network/interfaces is configured:
(xx.xx.xx.xx is ip address of FailoverIp)
OVH docs method:

auto eth0
iface eth0 inet dhcp

auto eth0:1
iface eth0:1 inet static
address xx.xx.xx.xx
netmask 255.255.255.255
post-up /sbin/ifconfig eth0:1 xx.xx.xx.xx netmask 255.255.255.255 broadcast xx.xx.xx.xx
pre-down /sbin/ifconfig eth0:1 down

New method that seems to work better:

auto eth0
iface eth0 inet dhcp

post-up /sbin/ip addr add xx.xx.xx.xx/32 dev eth0 brd xx.xx.xx.xx label eth0:0
pre-down /sbin/ip addr del xx.xx.xx.xx/32 dev eth0 brd xx.xx.xx.xx label eth0:0

I am not a system admin, so I don't know what is going on. Just wanted to put it out there in case anyone else runs into this problem.
P.S.
Should eth:0 be configured to use "static" instead of dhcp? Once my instance is assigned an IP will it always be able to use that IP?
Thanks,
Rob Reiss