When Anthos clusters on bare metal creates or upgrades clusters, it deploys a
Kubernetes in Docker (kind) cluster to temporarily
host the Kubernetes controllers needed to create or upgrade clusters. This
transient cluster is called a bootstrap cluster.
If a kind cluster already exists in your deployment when you attempt to install,
Anthos clusters on bare metal deletes the existing kind cluster. Deletion only
happens after the installation or upgrade is successful.
To preserve the existing kind cluster even after success, use the
--reuse-bootstrap-cluster flag of
Anthos clusters on bare metal creates a configuration file for the bootstrap cluster
WORKSPACE_DIR/.kindkubeconfig. You can connect to the
bootstrap cluster only during cluster creation and upgrade.
The bootstrap cluster needs to access a Docker repository to pull images. The
registry defaults to Container Registry unless you are using a
private registry. During cluster creation,
bmctl creates the following files:
bmctl-workspace/config.json: Contains Google Cloud service account credentials for the registry access. The credentials are obtained from the
gcrKeyPathfield in the cluster configuration file.
bmctl-workspace/config.toml: Contains the containerd configuration in the kind cluster.
Debug the bootstrap cluster
To debug the bootstrap cluster you can take the following steps:
- Connect to the bootstrap cluster during cluster creation and upgrade.
- Get the logs of the bootstrap cluster.
You can find the logs in the machine you use to run
bmctl in the following
the name of your cluster and the corresponding system's time.
To get the logs from the bootstrap cluster directly, you can run the following command during cluster creation and upgrade:
docker exec -it bmctl-control-plane bash
The command opens a terminal inside the bmctl control plane container that runs in the bootstrap cluster.
To inspect the
containerd logs, use the following commands and
look for errors or warnings in the output:
journalctl -u kubelet journalctl -u containerd