Skip to contentSkip to conversation

: Making "LIBXL_HOTPLUG_TIMEOUT" configurable through 'xl.conf'

Discussion Divin Raj 6 participants 10 messages Nov 15, 2023 – Nov 24, 2023

lore
Share & tools
lore

Divin Raj

author
#0 lore raw
Quoted 8 lines

Hi Xen community,

On one of our internal projects we came across an issue in the toolstack: when multiple network interfaces are initialized concurrently with other system workloads, the execution time of the hotplug script often exceeds 40 seconds, leading to an error. To mitigate this issue, we are considering making “LIBXL_HOTPLUG_TIMEOUT” configurable through ‘xl.conf’, instead of increasing the hard-coded “hotplug timeout”, do you think it could make sense?We would greatly appreciate any feedback, suggestions, or improvements you could provide. Thank you for your time and consideration.

Regards
Divin

#3 lore raw

Thu, 16 Nov 2023 08:45:43 +0100 Jan Beulich <[email protected]>:

Quoted 1 line

Did you ever submit it?

Likely not.

I think the approach to use a xenstore entry was used to avoid ABI incompatibilities due to changed .idl files.

In case anyone really wants up upstream such change, a global per-device timeout should not go into xl.conf, to make sure domUs managed by libvirt can also be tuned.

Olaf

#4 lore raw
Quoted 8 lines · Olaf Hering

Thu, 16 Nov 2023 08:45:43 +0100 Jan Beulich <[email protected]>:

Quoted 1 line

Did you ever submit it?

Quoted 8 lines

Likely not.

I think the approach to use a xenstore entry was used to avoid ABI incompatibilities due to changed .idl files.

In case anyone really wants up upstream such change, a global per-device timeout should not go into xl.conf, to make sure domUs managed by libvirt can also be tuned.

Hi Olaf,

I see your patch is handling this issue but maybe was not meant to be upstreamed, so I would like to ask if you are willing to make it upstream-able or if it’s not planned to do so.

Cheers,
Luca

#5 lore raw

Thu, 16 Nov 2023 09:21:06 +0000 Luca Fancellu <[email protected]>:

Quoted 3 lines

I see your patch is handling this issue but maybe was not meant to be upstreamed, so I would like to ask if you are willing to make it upstream-able or if it’s not planned to do so.

Right now I do not have the time to work on this.

First there need to be an agreement about how the timeout needs to be configured.

Olaf

author
#6 lore raw
Quoted 6 lines · Olaf Hering

Thu, 16 Nov 2023 09:21:06 +0000 Luca Fancellu <[email protected]>:

Quoted 3 lines

I see your patch is handling this issue but maybe was not meant to be upstreamed, so I would like to ask if you are willing to make it upstream-able or if it’s not planned to do so.

Quoted 6 lines

Right now I do not have the time to work on this.

First there need to be an agreement about how the timeout needs to be configured.

Olaf

Hello everyone,

Following our earlier discussion, we learned that there is already a solution to fix the LIBXL hotplug timeout issue. Currently, we have two options:

1. Xenstore Key/Value Approach: This is implemented in the patch "libxl.LIBXL_HOTPLUG_TIMEOUT.patch". This method does not require recompiling libxl. It involves setting up a key/value in Xenstore before domain creation. The patch can be viewed here: [https://build.opensuse.org/package/view_file/openSUSE:Factory/xen/libxl.LIBXL_HOTPLUG_TIMEOUT.patch?expand=1].

2. Configuration via 'xl.conf': We can make "LIBXL_HOTPLUG_TIMEOUT" configurable through the 'xl.conf' file.

I propose we have a discussion to determine the most suitable approach. Once we reach the best solution, we can move forward with the implementation/upstream.

Your feedback, suggestions, or any improvements would be greatly appreciated.

Thank you for your time and consideration.

Regards,
Divin

#7 lore raw
Quoted 12 lines · Divin Raj
Quoted 11 lines · Olaf Hering

Thu, 16 Nov 2023 09:21:06 +0000 Luca Fancellu <[email protected]>:

Quoted 3 lines

I see your patch is handling this issue but maybe was not meant to be upstreamed, so I would like to ask if you are willing to make it upstream-able or if it’s not planned to do so.

Right now I do not have the time to work on this.

First there need to be an agreement about how the timeout needs to be configured.

Quoted 7 lines
Quoted 1 line

Olaf

Hello everyone,

Following our earlier discussion, we learned that there is already a solution to fix the LIBXL hotplug timeout issue. Currently, we have two options:

1. Xenstore Key/Value Approach: This is implemented in the patch "libxl.LIBXL_HOTPLUG_TIMEOUT.patch". This method does not require recompiling libxl. It involves setting up a key/value in Xenstore before domain creation. The patch can be viewed here: [https://build.opensuse.org/package/view_file/openSUSE:Factory/xen/libxl.LIBXL_HOTPLUG_TIMEOUT.patch?expand=1].

I don't like this approach. It was used to solve the problem without affecting the ABI, but it is basically a hack.

Quoted 2 lines

2. Configuration via 'xl.conf': We can make "LIBXL_HOTPLUG_TIMEOUT" configurable through the 'xl.conf' file.

As Olaf has said already: this wouldn't cover actions e.g. by libvirt.

I think we might want something like libxl.conf (or xen.conf?) setting defaults for ALL tool stacks. I think we should even move some of the settings from xl.conf into the new file (like autoballoon, max_grant_frames, etc.).

Juergen

#8 lore raw

Fri, 24 Nov 2023 13:47:53 +0100 Juergen Gross <[email protected]>:

Quoted 1 line

As Olaf has said already: this wouldn't cover actions e.g. by libvirt.

Jim pointed me to /etc/libvirt/libxl.conf. So from this perspective both xl and libvirt is covered. Now it just takes someone to implement it.

Olaf

#9 lore raw
Quoted 6 lines · Olaf Hering

Fri, 24 Nov 2023 13:47:53 +0100 Juergen Gross <[email protected]>:

Quoted 1 line

As Olaf has said already: this wouldn't cover actions e.g. by libvirt.

Jim pointed me to /etc/libvirt/libxl.conf. So from this perspective both xl and libvirt is covered. Now it just takes someone to implement it.

I like Juergen's idea of libxl.conf or xen.conf for Xen. This would avoid the duplicate effort of adding support for such host-wide settings to the configuration of external libxl toolstacks like libvirt. And external stacks could immediately use any new settings added to the Xen configuration.

Regards,
Jim