vsphere provider should configure IP addresses as static

Bug #1904612 reported by Felipe Reyes
28
This bug affects 5 people
Affects Status Importance Assigned to Milestone
Canonical Juju
Triaged
Low
Unassigned

Bug Description

juju controllers get their IP address from vmware's dhcp, but this one won't allocate a static IP address for the life of the virtual machine, so it has happened (on production environments) that controllers after some time have been given a new IP address which has broken juju expectations.

it would be appropriate that at the moment of "juju bootstrap" *and* when deploying any new machine after that the IP addresses are configured to be static/fixed in vpshere to avoid disruption.

Felipe Reyes (freyes)
tags: added: vsphere-provider
Revision history for this message
Pen Gale (pengale) wrote :

This isn't necessarily a problem just w/ the vsphere provider. Juju asks the underlying cloud provider to provision an ip address for an instance, but if the cloud provider doesn't guarantee a static ip address, that address can change on instance reboot.

The solution here might be to give operators a way to set a static ip on an instance, based on knowledge they have about the network, and available ip addresses.

Triaging this bug as medium. We very much want to do this, but it isn't on roadmap for this cycle.

Changed in juju:
status: New → Triaged
importance: Undecided → Medium
Revision history for this message
Pen Gale (pengale) wrote :

Quick follow-up comment: setting static ips explicitly isn't necessarily the best solution. It works, but it adds a lot of deployment specific info to the mix.

One workaround is to make sure that your DHCP provider doesn't have very short lease expiry settings. That way, if a machine crashes and doesn't come up for a bit, it doesn't lose its claim on an ip address.

Revision history for this message
Pen Gale (pengale) wrote :

... and one more follow-up. This probably relates to the discussion around providing a DNS. This breaks badly when a controller goes down and comes back up with a different IP address. Things would be much better if we had some sort of controller.my.local.domain that we could refer to ...

Revision history for this message
Felipe Reyes (freyes) wrote : Re: [Bug 1904612] Re: vsphere provider should configure IP addresses as static

On Tue, 2020-11-17 at 21:55 +0000, Pete Vander Giessen wrote:
> This isn't necessarily a problem just w/ the vsphere provider. Juju
> asks
> the underlying cloud provider to provision an ip address for an
> instance, but if the cloud provider doesn't guarantee a static ip
> address, that address can change on instance reboot.

When using maas provider the containers get registered and they get
assigned a static IP.

In OpenStack the IPs are (usually) delivered using DHCP, but they are
registered by neutron and they never change for the life of the VM.

In AWS, my understanding is that the interfaces associated with a VPC
get a fixed IP address as well.

So in general this is the expectation and I think juju could make the
extra effort to make it behave as other substrates and bootstrap a
reliable environment for juju managed workloads.

>
> The solution here might be to give operators a way to set a static ip
> on
> an instance, based on knowledge they have about the network, and
> available ip addresses.

If it's expected that the operator will need to configure this, then
should be mentioned by the docs and probably when doing "juju bootstrap
vsphere"

Revision history for this message
Pedro Victor Lourenço Fragola (pedrovlf) wrote :

I had the same behavior in another environment(vsphere/juju) that is something that is already repeated, the lease was set for 8 hours and after a power outage, the machines when they started took a new IP from the DHCP server.

In this case, even after forcing DHCP to set the old IPs, some machines in a k8s cluster(CDK charm) continued with the juju showing the old IP in the status, maybe it is some BUG or some configuration that needs to be validated.

In this environment after setting a lease for a longer time of a few days, after removing the juju machines/models for some reason the DHCP server is not releasing the IPs.

The big point is that having the option of static IPs would be an excellent option to avoid future issues.

Revision history for this message
Canonical Juju QA Bot (juju-qa-bot) wrote :

This Medium-priority bug has not been updated in 60 days, so we're marking it Low importance. If you believe this is incorrect, please update the importance.

Changed in juju:
importance: Medium → Low
tags: added: expirebugs-bot
Revision history for this message
Andy Wu (qch2012) wrote :

I had a customer request for this feature. The vm networks that juju connect to doesn't have DHCP server, the customer's current pactice is to allocate the IP address from external DHCP server (infoblox) first, then pass it to the ansible playbook to provision the machine. Now they are interested in to integrate the ansible workflow with juju, but we need first ensure juju can support adding static IP to machine

Revision history for this message
Peter Stevens (pstevens1) wrote :

I've run into this issue as well when trying to bootstrap vsphere. The subnet attached to these hosts doesn't have DHCP. It would be very useful to be able to provide a static IP via --config.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.