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

Improve QEMU debugging #121

Merged
merged 4 commits into from
Jul 31, 2020
Merged

Improve QEMU debugging #121

merged 4 commits into from
Jul 31, 2020

Conversation

pothos
Copy link
Member

@pothos pothos commented Jul 30, 2020

  • platform/machine/qemu: Log IP address in debug mode
  • platform/machine/unprivqemu: Log localhost port for SSH connections
  • Log PIDs of qemu machine processes for manual cleanup
  • kola: Remove unnecessary deletion of test machines
    The cluster deletes all machines if needed. Deleting them inside the
    tests broke the --remove=false flag to keep machines for debugging.

How to use/testing done

# --key PATH is needed because we run as root
sudo ./kola run -d --remove=false --key ~/.ssh/id_rsa.pub -k --board=amd64-usr --channel=alpha --parallel=1 --platform=qemu --qemu-bios=bios-256k.bin --qemu-image flatcar_production_qemu_image.img systemd.journal.remote 2> >(tee pidlog >&2)
# See test failing, enter with SSH:
ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o ProxyCommand="sudo nsenter -n -t $(grep 'dnsmasq.*manual cleanup needed' pidlog | cut -d : -f 5) nc %h %p" -p 22 [email protected]
# Later kill the qemu and dnsmasq processes:
sudo kill $(grep 'manual cleanup needed' pidlog | cut -d : -f 5)

Copy link
Member

@sayanchowdhury sayanchowdhury left a comment

Choose a reason for hiding this comment

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

LGTM

@pothos pothos merged commit 5d44f28 into flatcar-master Jul 31, 2020
@pothos pothos deleted the kai/qemu-debug branch July 31, 2020 13:54
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.

2 participants