Upgrade Active Directory connector
This article describes how to upgrade the Active Directory connector.
Prerequisites
Before you can proceed with the tasks in this article, you need:
- To connect and authenticate to a Kubernetes cluster
- An existing Kubernetes context selected
- Azure Arc data controller deployed, either in
direct
orindirect
mode - Active Directory connector deployed
Install tools
To upgrade the Active Directory connector (adc), you need to have the Kubernetes tools such as kubectl installed.
The examples in this article use kubectl
, but similar approaches could be used with other Kubernetes tools such as the Kubernetes dashboard, oc
, or helm if you're familiar with those tools and Kubernetes yaml/json.
Limitations
Auto upgrade of Active Directory connector is applicable from imageTag v1.12.0_2022-10-11
and above and the Arc data controller must be at least v1.11.0_2022-09-13
version.
The active directory connector (adc) must be at the same version as the data controller before a data controller is upgraded.
There is no batch upgrade process available at this time.
Upgrade Active Directory connector for previous versions
For imageTag versions v1.11.0_2022-09-13
or lower, the Active Directory connector must be upgraded manually as below:
Use a kubectl command to view the existing spec in yaml.
kubectl get adc <adc-name> --namespace <namespace> --output yaml
Run kubectl patch to update the desired version.
kubectl patch adc <adc-name> --namespace <namespace> --type merge --patch '{"spec": {"update": {"desiredVersion": "v1.11.0_2022-09-13"}}}'
Monitor
You can monitor the progress of the upgrade with kubectl as follows:
kubectl describe adc <adc-name> --namespace <namespace>
Output
The output for the command will show the resource information. Upgrade information will be in Status.
During the upgrade, State
will show Updating
and Running Version
will be the current version:
Status:
Last Update Time: 2022-09-20T16:01:48.449512Z
Observed Generation: 1
Running Version: v1.10.0_2022-08-09
State: Updating
When the upgrade is complete, State
will show Ready
and Running Version
will be the new version:
Status:
Last Update Time: 2022-09-20T16:01:54.279612Z
Observed Generation: 2
Running Version: v1.11.0_2022-09-13
State: Ready
Troubleshooting
When the desired version is set to a specific version, the bootstrapper job will attempt to upgrade to that version until it succeeds. If the upgrade is successful, the RunningVersion
property of the spec is updated to the new version. Upgrades could fail for scenarios such as an incorrect image tag, unable to connect to registry or repository, insufficient CPU or memory allocated to the containers, or insufficient storage.
Run the below command to see if any of the pods show an
Error
status or have high number of restarts:kubectl get pods --namespace <namespace>
To look at Events to see if there is an error, run
kubectl describe pod <pod name> --namespace <namespace>
To get a list of the containers in the pods, run
kubectl get pods <pod name> --namespace <namespace> -o jsonpath='{.spec.containers[*].name}*'
To get the logs for a container, run
kubectl logs <pod name> <container name> --namespace <namespace>
To view common errors and how to troubleshoot them go to Troubleshooting resources.