Pacemaker - Azure Fence Agent "fence_azure_arm" failed to start after Python 3.11 interpreter was installed
This document (000021504) is provided subject to the disclaimer at the end of this document.
Environment
SUSE Linux Enterprise Server for SAP Applications 15 SP4
SUSE Linux Enterprise Server for SAP Applications 15 SP5
SUSE Linux Enterprise Server for SAP Applications 15 SP6
SUSE Linux Enterprise High Availability 15 SP4
SUSE Linux Enterprise High Availability 15 SP5
SUSE Linux Enterprise High Availability 15 SP6
Situation
https://www.suse.com/c/incompatible-changes-ahead-for-public-cloud-sdks/
Afterwards the Azure Fence Agent (AFA) failed to start in a Pacemaker cluster and the following error is shown in the /var/log/messages file:
2024-07-24T11:15:25.550247+00:00 x00dhnp01l1f4 fence_azure_arm: Azure Resource Manager Python SDK not found or not accessible
2024-07-24T11:15:25.550389+00:00 x00dhnp01l1f4 fence_azure_arm: Please use '-h' for usage
2024-07-24T11:15:25.560338+00:00 x00dhnp01l1f4 pacemaker-fenced[8853]: warning: fence_azure_arm[29901] stderr: [ 2024-07-24 11:15:25,549 ERROR: Azure Resource Manager Python SDK not found or not accessible ]
2024-07-24T11:15:25.560423+00:00 x00dhnp01l1f4 pacemaker-fenced[8853]: warning: fence_azure_arm[29901] stderr: [ ]
2024-07-24T11:15:25.560474+00:00 x00dhnp01l1f4 pacemaker-fenced[8853]: warning: fence_azure_arm[29901] stderr: [ 2024-07-24 11:15:25,549 ERROR: Please use '-h' for usage ]
2024-07-24T11:15:25.560504+00:00 x00dhnp01l1f4 pacemaker-fenced[8853]: warning: fence_azure_arm[29901] stderr: [ ]
Resolution
- Install latest patches and reboot the instance
- Verify installed Python version
- Make sure the required packages are installed
- Adjust the /usr/sbin/fence_azure_arm Python script so it can be executed using Python 3.11
- Basic tests
- Cleanup the Pacemaker cluster resource
Example:
1.) Install latest patches if required execute this command twice and reboot the instance:
x00dhnp01l0f4:~ # zypper -n patch x00dhnp01l0f4:~ # zypper -n patch x00dhnp01l0f4:~ # reboot
2.) Verify installed Python version:
x00dhnp01l0f4:~ # python3 --version Python 3.6.15 x00dhnp01l0f4:~ # python3.11 --version Python 3.11.9
3.) Make sure the required packages are installed:
x00dhnp01l0f4:~ # rpm -qa python311-msrestazure python311-msrestazure-0.6.4-150400.14.5.1.noarch x00dhnp01l0f4:~ # rpm -qa python311-pexpect python311-pexpect-4.8.0-150400.15.5.9.noarch x00dhnp01l0f4:~ # rpm -qa python311-pycurl python311-pycurl-7.45.2-150400.13.3.12.x86_64
4.) Adjust the "/usr/sbin/fence_azure_arm" Python script so it can be executed using Python 3.11:
Github: https://github.com/ClusterLabs/fence-agents/commit/2259b200fd1c6b60a81372097536b2175ba67c96 x00dhnp01l0f4:~ # rpm -qa fence-agents fence-agents-4.12.1+git.1677142927.bf55c675-150500.4.6.1.x86_64 x00dhnp01l0f4:~ # diff -d /usr/sbin/fence_azure_arm /usr/sbin/fence_azure_arm.orig 1c1 < #!/usr/bin/python3.11 -tt --- > #!/usr/bin/python3 -tt 75c75 < vmStatus = compute_client.virtual_machines.get(rgName, vmName, expand="instanceView") --- > vmStatus = compute_client.virtual_machines.get(rgName, vmName, "instanceView")
5.) Basic tests:
x00dhnp01l0f4:~ # fence_azure_arm --msi --action=list --subscriptionId=<subid> --resourceGroup=<rgname> DEV-WEEU-SAP01-X00-x00dhnp01l0f4b, DEV-WEEU-SAP01-X00-x00dhnp01l1f4b, x00dhnp01l0f4:~ # fence_azure_arm --msi --action=status --subscriptionId=<subid> --resourceGroup=<rgname> --plug=DEV-WEEU-SAP01-X00-x00dhnp01l0f4b Status: ON
6.) Cleanup the cluster resource:
x00dhnp01l0f4:~ # crm resource cleanup rsc_st_azure
Cause
A new fence-agents-azure-arm sub-package will be released.
SUSE Engineering is actively working on this issue to provide a fix.
Status
Disclaimer
This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.
- Document ID:000021504
- Creation Date: 24-Jul-2024
- Modified Date:25-Jul-2024
-
- SUSE Linux Enterprise Server
- SUSE Linux Enterprise Server for SAP Applications
For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback[at]suse.com