Skip to content

Commit

Permalink
incusd/network/ovn: Wait up to 1s for dynamic IPs
Browse files Browse the repository at this point in the history
Apparently 500ms isn't always quite enough for OVN.

Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
  • Loading branch information
stgraber committed May 2, 2024
1 parent 0f798e9 commit 233514a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/server/network/driver_ovn.go
Original file line number Diff line number Diff line change
Expand Up @@ -3693,7 +3693,7 @@ func (n *ovn) InstanceDevicePortStart(opts *OVNInstanceNICSetupOpts, securityACL
var dynamicIPs []net.IP

// Retry a few times in case port has not yet allocated dynamic IPs.
for i := 0; i < 5; i++ {
for i := 0; i < 10; i++ {
dynamicIPs, err = n.state.OVNNB.LogicalSwitchPortDynamicIPs(instancePortName)
if err == nil {
if len(dynamicIPs) > 0 {
Expand Down

0 comments on commit 233514a

Please sign in to comment.