Difference between revisions of "OpenHPC:IPMI StaticIP"
(Created page with "=Configure Static IPMI IP address using the cluster IP as a basis= Assuming you have all your nodes setup on 10.10.0.0/24 and want to configure IPMI with an equivalent static...") |
|||
| Line 37: | Line 37: | ||
the command grabs the inet 10.10.'''0.103'''/24 section of the above and would work perfectly with a /16 segment too | the command grabs the inet 10.10.'''0.103'''/24 section of the above and would work perfectly with a /16 segment too | ||
| + | |||
| + | == changing SMC server IPMI shared state == | ||
| + | |||
| + | To get LAN mode: <pre>ipmitool raw 0x30 0x70 0x0c 0.</pre> | ||
| + | |||
| + | To set LAN mode dedicated: <pre>ipmitool raw 0x30 0x70 0x0c 1 0.</pre> | ||
| + | |||
| + | To set LAN mode onboard/shared: <pre>ipmitool raw 0x30 0x70 0x0c 1 1.</pre> | ||
| + | |||
| + | To set LAN mode failover: <pre>ipmitool raw 0x30 0x70 0x0c 1 2.</pre> | ||
Revision as of 16:23, 6 August 2019
Configure Static IPMI IP address using the cluster IP as a basis
Assuming you have all your nodes setup on 10.10.0.0/24 and want to configure IPMI with an equivalent static IP in 10.11.0.0/24 and you have ipmitool and pdsh installed:
pdsh compute[01-79],infra[01-14] 'ipmitool lan set 1 ipsrc static; octets=$(ip a | grep "10.10." | sed -rn "s/.+\.([0-9]+\.[0-9]+)\/24.+/\1/gp"); ipmitool lan set 1 ipaddr 10.11.$octets; ipmitool lan set 1 netmask 255.255.0.0; ipmitool lan set 1 defgw ipaddr 10.10.10.1' | dshbak ... infra13 ---------------- Setting LAN IP Address to 10.11.0.23 Setting LAN Subnet Mask to 255.255.0.0 Setting LAN Default Gateway IP to 10.10.10.1 ---------------- infra14 ---------------- Setting LAN IP Address to 10.11.0.24 Setting LAN Subnet Mask to 255.255.0.0 Setting LAN Default Gateway IP to 10.10.10.1
this expands up to run the following 3 commands on every node:
ipmitool lan set 1 ipsrc static
ipmitool lan set 1 ipaddr 10.11.0.103
ipmitool lan set 1 netmask 255.255.0.0
ipmitool lan set 1 defgw ipaddr 10.10.10.1
to adapt make sure that you match the appropriate section of the
ip a
command e.g.:
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
link/ether ac:1f:6b:b2:9f:06 brd ff:ff:ff:ff:ff:ff
inet 10.10.0.103/24 brd 10.10.10.255 scope global eth0
valid_lft forever preferred_lft forever
inet6 fe80::ae1f:6bff:feb2:9f06/64 scope link
valid_lft forever preferred_lft forever
the command grabs the inet 10.10.0.103/24 section of the above and would work perfectly with a /16 segment too
To get LAN mode:
ipmitool raw 0x30 0x70 0x0c 0.
To set LAN mode dedicated:
ipmitool raw 0x30 0x70 0x0c 1 0.
To set LAN mode onboard/shared:
ipmitool raw 0x30 0x70 0x0c 1 1.
To set LAN mode failover:
ipmitool raw 0x30 0x70 0x0c 1 2.