Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add serial console support to QEMU orchestrator. #1707

Merged
merged 3 commits into from
Jan 25, 2022

Conversation

cwize1
Copy link
Contributor

@cwize1 cwize1 commented Jan 22, 2022

  1. Add support for libvirt event callbacks. Libvirt requires
    setting up a single process-wide event loop for handling the
    events. This change provisions a separate Python thread for
    this purpose.

  2. Create a reader for the libvirt console stream that writes
    the console output to file. (Ideally we would use the inbuilt
    libvirt support for writing the console to file. But SELinux
    doesn't like this for whatever reason.) This mimics the Azure
    API that provides the serial console output as a log that can
    be downloaded.

  3. Implement the orchestrator serial console feature. This
    just reads and dumps the console log file.

  4. Fix a minor bug in NodeSpace schema class, that causes
    a crash for some runbook configurations.

1. Add support for libvirt event callbacks. Libvirt requires
setting up a single process-wide event loop for handling the
events. This change provisions a separate Python thread for
this purpose.

2. Create a reader for the libvirt console stream that writes
the console output to file. (Ideally we would use the inbuilt
libvirt support for writing the console to file. But SELinux
doesn't like this for whatever reason.) This mimics the Azure
API that provides the serial console output as a log that can
be downloaded.

3. Implement the orchestrator serial console feature. This
just reads and dumps the console log file.

4. Fix a minor bug in NodeSpace schema class, that causes
a crash for some runbook configurations.
lisa/schema.py Outdated Show resolved Hide resolved
node_capabilities = schema.NodeSpace()
node_capabilities.name = "QEMU"
node_capabilities.node_count = 1
node_capabilities.core_count = 2
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Make sure the deployment phase will use those values.

node_capabilities.memory_mb = 4096
node_capabilities.disk = schema.DiskOptionSettings()
node_capabilities.network_interface = schema.NetworkInterfaceOptionSettings()
node_capabilities.network_interface.max_nic_count = 1
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It needs to set nic_count too. the max_nic_count is used to limited how many nics can be created in some cases, which hot add nics.

@squirrelsc squirrelsc merged commit c0e38a9 into microsoft:main Jan 25, 2022
@cwize1 cwize1 deleted the user/chrisgun/QemuConsole2 branch March 4, 2022 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants