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

watchdog.cfg: support for a 'TCO' watchdog #3751

Merged
merged 1 commit into from
Nov 22, 2023

Conversation

yiqianwei
Copy link
Contributor

@yiqianwei yiqianwei commented Jun 16, 2023

The Q35 machine type chipset comes with unconditional support for a 'TCO' watchdog

ID: 1462

@yiqianwei yiqianwei force-pushed the bz2215497 branch 2 times, most recently from 4282fe7 to 9a56401 Compare June 16, 2023 09:51
@yiqianwei
Copy link
Contributor Author

@yanan-fu and @jingzhao84 , Could you help to review this patch? thanks a lot

@jingzhao84
Copy link
Contributor

jingzhao84 commented Jun 20, 2023

@yiqianwei

Check the log and no command of "-global ICH9-LPC.noreboot=false "
Could you double-check it?

Thanks
Jing

@jingzhao84
Copy link
Contributor

@yiqianwei
By the way,
-global ICH9-LPC.noreboot=false
-watchdog-action poweroff
Does it default on libvirt side?

Thanks
Jing

@jingzhao84
Copy link
Contributor

jingzhao84 commented Jun 20, 2023

@yiqianwei
How about RHEL 8, should we disable it on RHEL 8?

Thanks
Jing

@yiqianwei
Copy link
Contributor Author

@yiqianwei By the way, -global ICH9-LPC.noreboot=false -watchdog-action poweroff Does it default on libvirt side?

Thanks Jing
for libvirt-9.3.0-2.el9.x86_64 version, The default command is as follows:
-global ICH9-LPC.noreboot=off
-watchdog-action reset

@jingzhao84
Copy link
Contributor

@yiqianwei By the way, -global ICH9-LPC.noreboot=false -watchdog-action poweroff Does it default on libvirt side?
Thanks Jing
for libvirt-9.3.0-2.el9.x86_64 version, The default command is as follows:
-global ICH9-LPC.noreboot=off
-watchdog-action reset

@yiqianwei
So maybe we need to change the code as well, right?
set the related command line as default when boot guest?

Thanks
Jing

@yiqianwei
Copy link
Contributor Author

yiqianwei commented Jun 20, 2023

@yiqianwei

Based on these comments, how about RHEL 8, should we disable it on RHEL 8?

Thanks Jing

Hi @jingzhao84 ,

I try it with rhel8.9.0 guest in rhel8.9.0 host, also can work normally.

@yanan-fu
Copy link
Contributor

@yiqianwei Could you update this patch based on the latest change in avocado-vt ? Thanks!

@yiqianwei
Copy link
Contributor Author

@yanan-fu , please help to review this patch again? thanks

@yanan-fu
Copy link
Contributor

yanan-fu commented Nov 3, 2023

For this watchdog type, does the heartbeat_test need be covered or not ?

@yiqianwei
Copy link
Contributor Author

yiqianwei commented Nov 15, 2023

For this watchdog type, does the heartbeat_test need be covered or not ?

@yanan-fu, Not need be covered it. Fail to initialized with heartbeat=-1 in dmesg on rhel9.4.0 project.
Developer is also unclear, Anyway, we don't need cover it now. What do you think so ?

dmesg | grep -i itco

  1. boot a guest with itco watchdog
    [ 7.070824] iTCO_vendor_support: vendor-support=0
    [ 7.089847] iTCO_wdt iTCO_wdt.1.auto: Found a ICH9 TCO device (Version=2, TCOBASE=0x0660)
    [ 7.090657] iTCO_wdt iTCO_wdt.1.auto: initialized. heartbeat=30 sec (nowayout=0)

  2. Remove it and Reload with heartbeat=-1
    [ 117.763343] iTCO_vendor_support: Module Unloaded
    [ 168.237905] iTCO_vendor_support: vendor-support=0

  3. fail to heartbeat=-1 sec (nowayout=0), should to heartbeat=30 sec (nowayout=0)
    [ 168.239982] iTCO_wdt iTCO_wdt.1.auto: Found a ICH9 TCO device (Version=2, TCOBASE=0x0660)
    [ 168.240044] iTCO_wdt iTCO_wdt.1.auto: timeout value out of range, using 30
    [ 168.240572] iTCO_wdt iTCO_wdt.1.auto: initialized. heartbeat=-1 sec (nowayout=0)

@jingzhao84
Copy link
Contributor

@yanan-fu
Hello yfu
Based on @yiqianwei 's comments

  1. qemu initiative failed
  2. dev also have no idea until now
    So I think we can ignore it now and fix it when it can be supported, what do you think?

cc @yiqianwei

Thanks
Jing

@yanan-fu
Copy link
Contributor

@yiqianwei Please update the patch base on our discussion before.

And, suggest do not paste long test result in the patch, thanks!

@yiqianwei
Copy link
Contributor Author

@yanan-fu ,According to the test steps, only cover watchdog_action test. thanks

@yiqianwei
Copy link
Contributor Author

@yanan-fu , I have updated it

The Q35 machine type chipset comes with unconditional
support for a 'TCO' watchdog

Signed-off-by: Yiqian Wei <[email protected]>
@yiqianwei
Copy link
Contributor Author

@yanan-fu , add itco modprobe to watchdog.py. please check this patch again , thanks.
check test log info:
[stdlog] 2023-11-22 00:02:26,942 aexpect.client DEBUG| [10.73.104.156] Sending command: modprobe iTCO_wdt
[stdlog] 2023-11-22 00:02:27,047 aexpect.client DEBUG| [10.73.104.156] Sending command: echo $?
[stdlog] 2023-11-22 00:02:27,149 avocado.test INFO | Context: Checking watchdog load info
[stdlog] 2023-11-22 00:02:27,149 aexpect.client DEBUG| [10.73.104.156] Sending command: lsmod | grep iTCO_wdt
[stdlog] 2023-11-22 00:02:27,256 aexpect.client DEBUG| [10.73.104.156] Sending command: echo $?
[stdlog] 2023-11-22 00:02:27,359 avocado.test INFO | Watchdog device 'itco' add and init successfully
[stdlog] 2023-11-22 00:02:27,359 avocado.test DEBUG| Init info : 'iTCO_wdt 16384 0
[stdlog] iTCO_vendor_support 16384 1 iTCO_wdt
[stdlog] '

Copy link
Contributor

@yanan-fu yanan-fu left a comment

Choose a reason for hiding this comment

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

Ack

@yanan-fu yanan-fu merged commit 9cdf276 into autotest:master Nov 22, 2023
6 checks passed
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.

3 participants