Because we cannot use VirtualBox and are instead using Multipass, a script is provided to create the three VMs.
Run the VM deploy script from your Mac terminal application
./deploy-virtual-machines.sh
Verify you can connect to all three (two if your Mac only has 8GB RAM) VMs:
multipass shell controlplane
You should see a command prompt like ubuntu@controlplane:~$
Type the following to return to the Mac terminal
exit
Do this for node01
and node02
as well
If you encountered issues starting the VMs, you can try NAT mode. Note that in NAT mode you will not be able to connect to your NodePort services using your browser.
./delete-virtual-machines.sh
deploy-virtual-machines.sh
and change BUILD_MODE="BRIDGE"
to BUILD_MODE="NAT"
at line 15.When you have finished with your cluster and want to reclaim the resources, perform the following steps
Run the delete script from your Mac terminal application
./delete-virtual-machines.sh
Clean stale DHCP leases. Multipass does not do this automatically and if you do not do it yourself you will eventually run out of IP addresses on the multipass VM network.
Edit the following
sudo vi /var/db/dhcpd_leases
name
set to controlplane
, node01
or node02
{
name=controlplane
ip_address=192.168.64.4
hw_address=1,52:54:0:78:4d:ff
identifier=1,52:54:0:78:4d:ff
lease=0x65dc3134
}
Next: Connectivity
Prev: Prerequisites