How to configure the privilege level of an IPMI user in fence_ipmilan in a RHEL 5 or 6 cluster
Environment
- Red Hat Enterprise Linux (RHEL) 5 or 6 with the High Availability Add On
- Red Hat Enterprise Virtualization Hypervisor (RHEV-H) 5
- Red Hat Enterprise Virtualization Hypervisor (RHEV-H) 6
- One or more hosts configured to use
fence_ipmilanas the fence agent- The fence device is configured with a user having a privilege level other than ADMIN
Issue
-
The fence_ipmilan man page indicates how to do this when running the fence agent manually (using the -L command line option), but does not explain the parameter name to include in the cluster.conf fence device definition.
-
Fencing using fence_ipmilan fails with the following error:
Jun 18 09:58:21 node1 fenced[68777]: fence node2 dev 0.0 agent fence_ipmilan result: error from agentBut manual fencing using the following command works:
fence_ipmilan -L operator -a "172.20.128.54" -l "rhcluster" -P -S "/usr/local/bin/hide_fence_passwd.sh" -o reboot -t 10 -T 4 -v -
The tool
fence_ipmilanhas no privilege level switch and the iLO user infence_ilohas only "Virtual Power and Reset" privileges. Is there a workaround for this? -
Unable to set iLO3 privilige level with
fence_ipmilan. -
Fencing is not working on Redhat two node cluster for the server which is having HP ILO 4:
[root@node1 ~]# fence_ilo4 -a X.X.X.X -P -l user -p xxxxxx -o status
Getting status of IPMI:X.X.X.X...Chassis power = Unknown
Failed
Resolution
First, ensure the necessary package releases have been installed:
RHEL 5
- Update
cmanto2.0.115-96.el5or later - For the ability to set the Privilege Level setting via Conga, update
luciandriccito release0.12.2-51.el5or later
RHEV-H 5
- Update
fence-agentstofence-agents-3.0.17-15.el5or later
RHEL 6 or RHEV-H 6
-
Update
fence-agentsto release3.1.5-10.el6or later -
For the ability to set the Privilege Level setting via Conga, update
lucito release0.26.0-37.el6or laterNext, configure the fence device with the correct privilege level setting:
Using fence_ipmilan from the Command Line
-
Add the
-Loption with the appropriate privilege level for the configured user:# fence_ipmilan -a 192.168.2.10 -l myUser -p password -P -o status -L USER
Configuring the fencedevice by editing /etc/cluster/cluster.conf
-
Add the
privlvlattribute with the appropriate privilege level for the configured user:<fencedevice ipaddr="192.168.2.10" username="myUser" password="password" lanplus="1" privlvl="USER"/>
Configuring the device via Conga
- Navigate to the configuration page for the fence device, and select the appropriate level from the
Privilege Leveldrop down
Root Cause
-
When interacting with a system management controller via
IPMIover LAN, theipmitooloffers aprivilege leveloption (-L) allowing the user to specify the level of the user. A similar option now exists incman(RHEL 5),fence-agents(RHEL 6), and Conga (RHEL 5 and 6) allowing a cluster administrator to configure fence devices for nodes that utilize this privilege level option. In some cases this may enhance security by not requiring the user to have more privileges than absolutely necessary over the system in question, and in those cases where different privilege levels are required, the fence agent may not work without being able to callipmitoolwith-L. -
The
-L/privlvloption forfence_ipmilanwas added to RHEL 5's cman in Bugzilla #726731 and to RHEL 6'sfence-agentsin Bugzilla #726571. Support for configuring this setting viaCongawas added to RHEL 5'sluciandriccivia Bugzilla #751359, and to RHEL 6'slucivia Bugzilla #821928. -
The available privilege levels are
CALLBACK,USER,OPERATOR, andADMINISTRATOR.
Diagnostic Steps
-
Attempt to communicate with the fence device using
fence_ipmilanwithout using-L:# fence_ipmilan -a 192.168.2.10 -l myUser -p password -P -o statusOnce this fails, try again (on the appropriate version of
cmanorfence-agentsfrom the Resolution above) using the appropriate privilege level:# fence_ipmilan -a 192.168.2.10 -l myUser -p password -P -o status -L USERIf confirmation is needed before updating the
cmanorfence-agentspackage, try callingipmitooldirectly using-L:# ipmitool -L user -H 192.168.2.10 -I lanplus -U myUser -P password chassis power status -v
This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.