fix: change the BOOT_TIME_COMMAND for macOS to get higher time precision - #85537
fix: change the BOOT_TIME_COMMAND for macOS to get higher time precision#85537renzibei wants to merge 3 commits into
Conversation
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
@renzibei We are waiting for the Core team triage and will discuss this issue in that meeting. Will update the discussion here. |
bcoca
left a comment
There was a problem hiding this comment.
I would add a test to ensure we don't regress
* Use `/usr/sbin/sysctl kern.boottime` to replace the `who -b` for the BOOT_TIME_COMMAND of macOS
cd3bdad to
ad67575
Compare
|
@bcoca do you have a specific test in mind, beyond adjusting the existing one? |
|
The macOS remote reboots so quickly (~15 seconds; at least 30 seconds faster than last time I checked), so I can reproduce the issue now just by running - name: Reboot yet again in quick succession
reboot:
when: ansible_facts.os_family == "Darwin"Not sure there's a good way to guarantee integration coverage though, since it only occurs if two reboots occur within a minute. |
SUMMARY
Fix the issue #85070 "macOS boot time command incorrectly checks boot time if last reboot was at same minute".
Use
/usr/sbin/sysctl kern.boottimeto replace thewho -bfor the BOOT_TIME_COMMAND of macOS, to get higher time precision.ISSUE TYPE