SUSE / salt-shaptools

Salt execution module and state to manage SAP Applications (HANA only at the moment) and SUSE Linux Enterprise High Availability components
Apache License 2.0
14 stars 11 forks source link

Retry get json status when estimation sync time not calculated yet. #65

Closed nick-wang closed 4 years ago

nick-wang commented 4 years ago

Estimation sync time still need to be calculated based on the synced data. Though less than a sec, drbdsetup status --json will return an invalid json format "estimated-seconds-to-finish": nan, when not ready.

nick-wang commented 4 years ago

This issue is found by Stefano with the deployment on SLE12SP4. However, it may happen on other SLE as long as network is not that fast. Besides this change in drbd salt module, also working in progress on fix in drbd-utils. Though the later one will take longer time to upstream and back.

nick-wang commented 4 years ago

The fix in upstream https://github.com/LINBIT/drbd-utils/commit/104293030b2c0106b4791edb3eec38b476652a2e is the reason why this issue not shown in SLE15.

This commit doesn't need to be revert even the patch backported to SLE12SP4/SP5. Also this commit also helpful during the time of patch release in maintenance channel, which maybe quite long...

arbulu89 commented 4 years ago

The fix in upstream LINBIT/drbd-utils@1042930 is the reason why this issue not shown in SLE15.

This commit doesn't need to be revert even the patch backported to SLE12SP4/SP5. Also this commit also helpful during the time of patch release in maintenance channel, which maybe quite long...

@nick-wang Is there any plan to backport this to SLE12? This would avoid having the need to have workarounds in our salt code

nick-wang commented 4 years ago

@nick-wang Is there any plan to backport this to SLE12? This would avoid having the need to have workarounds in our salt code

@arbulu89 WIll backport the upstream fix to SLE12SP4/SP5, but still need this workaround before patch released. Change the loop to context convert in the latest commit.