changing charm's subnet-id does not seem to take effect

Bug #1965456 reported by Syed Mohammad Adnan Karim
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Openstack Integrator Charm
New
Undecided
Unassigned

Bug Description

I deployed k8s 1.23 on openstack focal-ussuri without setting the floating-network-id or subnet-id values. After deployment of the charm/bundle, I updated the config with:

# Set to floating-ip/external subnet
juju config openstack-integrator subnet-id=2d5fc65b-4b58-4613-a3b8-3eda93e22c07
# Set to floating-ip/external network
juju config openstack-integrator floating-network-id=6b911c79-816a-4c24-aff2-59edf648699e

Then, I tried to create a k8s service of type LoadBalancer and received the following error in the service description:

Error syncing load balancer: failed to ensure load balancer: error creating LB floatingip: Resource not found: {"NeutronError": {"type": "ExternalGatewayForFloatingIPNotFound", "message": "External network 6b911c79-816a-4c24-aff2-59edf648699e is not reachable from subnet 2d5fc65b-4b58-4613-a3b8-3eda93e22c07. Therefore, cannot associate Port 17307d04-918d-481c-acba-42c6c35db52c with a Floating IP.", "detail": ""}}

So to rectify the situation, I tried to update the charm's config again with:

# Set to tenant subnet
juju config openstack-integrator subnet-id=b3f182e6-e7a1-46d4-b738-0cac65e8db99

Then, I tried to create the k8s service of type LoadBalancer again and received the following error in the service description again:

Error syncing load balancer: failed to ensure load balancer: error creating LB floatingip: Resource not found: {"NeutronError": {"type": "ExternalGatewayForFloatingIPNotFound", "message": "External network 6b911c79-816a-4c24-aff2-59edf648699e is not reachable from subnet 2d5fc65b-4b58-4613-a3b8-3eda93e22c07. Therefore, cannot associate Port 17307d04-918d-481c-acba-42c6c35db52c with a Floating IP.", "detail": ""}}

So it looks like changing the charm's subnet-id/floating-network-id config option don't always work successfully. I tried to also remove-unit/add-unit to get around this but was only able to update the floating-network-id this way but the subnet-id always remained as "2d5fc65b-4b58-4613-a3b8-3eda93e22c07".

I was able to solve my problem by redeploying my bundle and having the floating-network-id and subnet-id preconfigured to the desired values but the charm should be able to update on demand.

Revision history for this message
Gustavo Sanchez (gustavosr98) wrote :

I do get updates at least on the configuration file as soon as I update the charm
Try checking here after updating a value on the charm

kubectl get -n kube-system secret cloud-controller-config -o jsonpath='{.data.cloud\.conf}'|base64 -d

Now, pods in the daemon do not get restarted, so might need to delete and recreate pods to take the new 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.