I see a lot of customers asking about being able to deploy an OpenShift Baremetal IPI lab or proof of concepts in VmWare. Many want to do it to try out the deployment method without having to invest in the physical hardware. The problem faced with VmWare is the lack of an Intelligent Platform Management Interface (IPMI) for the virtual machines. I am not knocking VmWare either in this case because they do offer a robust API via Vcenter that lets one do quite a bit via scripting for automation. However the OpenShift Baremetal IPI install process requires IPMI or RedFish which are standards on server hardware. There does exist though a project that can possibly fill this gap though but it should only be used for labs and proof of concepts not production.
The project that solves this issue is called virtualbmc-for-vsphere. If the name virtualbmc sounds familiar its because that project was originally designed to provide IPMI to KVM virtual machines. However this forked version of virtualbmc-for-vsphere uses the same concepts to provide an IPMI interface for VmWare virtual machines. Only the code knows how to talk to Vcenter to power on/of and set bootdevices of the virtual machines. Here are some example of what IPMI commands are supported:
# Power the virtual machine on, off, graceful off, reset, and NMI. Note that NMI is currently experimental ipmitool -I lanplus -U admin -P password -H 192.168.0.1 -p 6230 power on|off|soft|reset|diag # Check the power status ipmitool -I lanplus -U admin -P password -H 192.168.0.1 -p 6230 power status # Set the boot device to network, disk or cdrom ipmitool -I lanplus -U admin -P password -H 192.168.0.1 -p 6230 chassis bootdev pxe|disk|cdrom # Get the current boot device ipmitool -I lanplus -U admin -P password -H 192.168.0.1 -p 6230 chassis bootparam get 5 # Get the channel info. Note that its output is always a dummy, not actual information. ipmitool -I lanplus -U admin -P password -H 192.168.0.1 -p 6230 channel info # Get the network info. Note that its output is always a dummy, not actual information. ipmitool -I lanplus -U admin -P password -H 192.168.0.1 -p 6230 lan print 1
# podman pull ghcr.io/kurokobo/vbmc4vsphere:0.0.4 Trying to pull ghcr.io/kurokobo/vbmc4vsphere:0.0.4... Getting image source signatures Copying blob 7a5d07f2fd13 done Copying blob 25a245937421 done Copying blob 2606867e5cc9 done Copying blob 385bb58d08e6 done Copying blob ab14b629693d done Copying blob bf5952930446 done Copying config 789cdc97ba done Writing manifest to image destination Storing signatures 789cdc97ba7461f673cc7ffc8395339f38869abb679ebd0703c2837f493062db
# podman run -d --name vbmc4vsphere -p "6801:6801/udp" -v vbmc-volume:/vbmc/.vbmc ghcr.io/kurokobo/vbmc4vsphere:0.0.4 ddf82bfdb7899e9232462ae3e8ea821d327b0db1bc8501c3827644aad9830736 # podman ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES ddf82bfdb789 ghcr.io/kurokobo/vbmc4vsphere:0.0.4 --foreground 3 seconds ago Up 3 seconds ago 0.0.0.0:6801->6801/udp vbmc4vsphere
# podman exec -it vbmc4vsphere /bin/bash root@ddf82bfdb789:/#
root@ddf82bfdb789:/# vbmc add rheltest --port 6801 --username admin --password password --viserver 192.168.0.30 --viserver-password vcenterpassword --viserver-username administrator@vsphere.local root@ddf82bfdb789:/# vbmc list +----------+--------+---------+------+ | VM name | Status | Address | Port | +----------+--------+---------+------+ | rheltest | down | :: | 6801 | +----------+--------+---------+------+ root@ddf82bfdb789:/#
root@ddf82bfdb789:/# vbmc start rheltest root@ddf82bfdb789:/# vbmc list +----------+---------+---------+------+ | VM name | Status | Address | Port | +----------+---------+---------+------+ | rheltest | running | :: | 6801 | +----------+---------+---------+------+ root@ddf82bfdb789:/# exit exit #
# ip addr show dev ens3 2: ens3: <ltBROADCAST,MULTICAST,UP,LOWER_UP>gt mtu 1500 qdisc fq_codel state UP group default qlen 1000 link/ether 52:54:00:b9:97:58 brd ff:ff:ff:ff:ff:ff inet 192.168.0.10/24 brd 192.168.0.255 scope global noprefixroute ens3 valid_lft forever preferred_lft forever inet6 fe80::6baa:4a96:db6b:88ee/64 scope link noprefixroute valid_lft forever preferred_lft forever
# ipmitool -I lanplus -U admin -P password -H 192.168.0.10 -p 6801 power status Chassis Power is on # ping 192.168.0.226 -c 4 PING 192.168.0.226 (192.168.0.226) 56(84) bytes of data. 64 bytes from 192.168.0.226: icmp_seq=1 ttl=64 time=0.753 ms 64 bytes from 192.168.0.226: icmp_seq=2 ttl=64 time=0.736 ms 64 bytes from 192.168.0.226: icmp_seq=3 ttl=64 time=0.651 ms 64 bytes from 192.168.0.226: icmp_seq=4 ttl=64 time=0.849 ms --- 192.168.0.226 ping statistics --- 4 packets transmitted, 4 received, 0% packet loss, time 3109ms rtt min/avg/max/mdev = 0.651/0.747/0.849/0.072 ms
# ipmitool -I lanplus -U admin -P password -H 192.168.0.10 -p 6801 power off Chassis Power Control: Down/Off
# ipmitool -I lanplus -U admin -P password -H 192.168.0.10 -p 6801 power status Chassis Power is off # ping 192.168.0.226 -c 4 -t 10 PING 192.168.0.226 (192.168.0.226) 56(84) bytes of data. From 192.168.0.10 icmp_seq=1 Destination Host Unreachable From 192.168.0.10 icmp_seq=2 Destination Host Unreachable From 192.168.0.10 icmp_seq=3 Destination Host Unreachable From 192.168.0.10 icmp_seq=4 Destination Host Unreachable --- 192.168.0.226 ping statistics --- 4 packets transmitted, 0 received, +4 errors, 100% packet loss, time 3099ms pipe 4
# ipmitool -I lanplus -U admin -P password -H 192.168.0.10 -p 6801 power on Chassis Power Control: Up/On
# ipmitool -I lanplus -U admin -P password -H 192.168.0.10 -p 6801 power status Chassis Power is on # ping 192.168.0.226 -c 4 PING 192.168.0.226 (192.168.0.226) 56(84) bytes of data. 64 bytes from 192.168.0.226: icmp_seq=1 ttl=64 time=0.860 ms 64 bytes from 192.168.0.226: icmp_seq=2 ttl=64 time=1.53 ms 64 bytes from 192.168.0.226: icmp_seq=3 ttl=64 time=0.743 ms 64 bytes from 192.168.0.226: icmp_seq=4 ttl=64 time=0.776 ms --- 192.168.0.226 ping statistics --- 4 packets transmitted, 4 received, 0% packet loss, time 3066ms rtt min/avg/max/mdev = 0.743/0.976/1.528/0.323 ms