Add support for non-standard ports to fence_ipmilan.
We can now pass a parameter to fence_ipmilan resources to set the target IP port to a non-default value. In particular, this makes it possible to talk to multiple instances of vbmc. Partial-Bug: #1649695 Change-Id: I341deba4afbfc0fd73253607d3d0d270b5480c6f
This commit is contained in:
parent
9eb4361b6a
commit
b01145b723
|
@ -20,6 +20,11 @@ To use fence_ipmilan with HP iLO 3 or HP iLO 4 you have to enable lanplus option
|
|||
<content type="string" />
|
||||
<shortdesc lang="en">IPMI Lan IP to talk to</shortdesc>
|
||||
</parameter>
|
||||
<parameter name="ipport" unique="0" required="0">
|
||||
<getopt mixed="-u" />
|
||||
<content type="string" />
|
||||
<shortdesc lang="en">IPMI Lan port to talk to</shortdesc>
|
||||
</parameter>
|
||||
<parameter name="passwd" unique="0" required="0">
|
||||
<getopt mixed="-p" />
|
||||
<content type="string" />
|
||||
|
|
|
@ -13,6 +13,9 @@
|
|||
# [*ipaddr*]
|
||||
# IPMI Lan IP to talk to
|
||||
#
|
||||
# [*ipport*]
|
||||
# IPMI LAN port to talk to
|
||||
#
|
||||
# [*passwd*]
|
||||
# Password (if required) to control power on IPMI device
|
||||
#
|
||||
|
@ -90,6 +93,7 @@
|
|||
define pacemaker::stonith::fence_ipmilan (
|
||||
$auth = undef,
|
||||
$ipaddr = undef,
|
||||
$ipport = undef,
|
||||
$passwd = undef,
|
||||
$passwd_script = undef,
|
||||
$lanplus = undef,
|
||||
|
@ -119,6 +123,10 @@ define pacemaker::stonith::fence_ipmilan (
|
|||
undef => '',
|
||||
default => "ipaddr=\"${ipaddr}\"",
|
||||
}
|
||||
$ipport_chunk = $ipport ? {
|
||||
undef => '',
|
||||
default => "ipport=\"${ipport}\""
|
||||
}
|
||||
$passwd_chunk = $passwd ? {
|
||||
undef => '',
|
||||
default => "passwd=\"${passwd}\"",
|
||||
|
@ -187,7 +195,7 @@ define pacemaker::stonith::fence_ipmilan (
|
|||
'fence-agents-ipmilan': ensure => installed,
|
||||
} ->
|
||||
exec { "Create stonith-fence_ipmilan-${safe_title}":
|
||||
command => "/usr/sbin/pcs stonith create stonith-fence_ipmilan-${safe_title} fence_ipmilan pcmk_host_list=\"${pcmk_host_value_chunk}\" ${auth_chunk} ${ipaddr_chunk} ${passwd_chunk} ${passwd_script_chunk} ${lanplus_chunk} ${login_chunk} ${action_chunk} ${timeout_chunk} ${cipher_chunk} ${method_chunk} ${power_wait_chunk} ${delay_chunk} ${privlvl_chunk} ${verbose_chunk} op monitor interval=${interval}",
|
||||
command => "/usr/sbin/pcs stonith create stonith-fence_ipmilan-${safe_title} fence_ipmilan pcmk_host_list=\"${pcmk_host_value_chunk}\" ${auth_chunk} ${ipaddr_chunk} ${ipport_chunk} ${passwd_chunk} ${passwd_script_chunk} ${lanplus_chunk} ${login_chunk} ${action_chunk} ${timeout_chunk} ${cipher_chunk} ${method_chunk} ${power_wait_chunk} ${delay_chunk} ${privlvl_chunk} ${verbose_chunk} op monitor interval=${interval}",
|
||||
unless => "/usr/sbin/pcs stonith show stonith-fence_ipmilan-${safe_title} > /dev/null 2>&1",
|
||||
tries => $tries,
|
||||
try_sleep => $try_sleep,
|
||||
|
|
Loading…
Reference in New Issue