Prepare for Kubernetes Visibility Agent deployment
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
Prepare for Kubernetes Visibility Agent deployment
Prepare your ServiceNow instance and the Kubernetes cluster for Kubernetes Visibility Agent deployment.
Before you begin
- Ensure that the following applications are installed and activated:
- Discovery and Service Mapping Patterns
- The latest version of Agent Client Collector for Visibility – Content
- Ensure that the Kubernetes command line tool kubectl is installed and configured to communicate with your cluster.
- If you plan to use a Helm chart for the installation, ensure that the Helm tool is available. For more information, see the Helm documentation.
Role required: admin for steps performed on the ServiceNow instance.
Procedure
- On the ServiceNow instance, navigate to All > User Administration > Users.
- Choose or create a user with at least the discovery_admin and mid_server role.
- In the Kubernetes cluster, choose or create a namespace in which you want to deploy Kubernetes Visibility Agent.
To create a namespace:
- Open the kubectl command line tool.
- Run the following command, after replacing NAMESPACE with the relevant value:
kubectl create namespace NAMESPACE
- Create a Kubernetes secret that contains the ServiceNow credentials for accessing your ServiceNow instance.
Note: Ensure that the credentials correspond to the user you created or identified in the earlier step.
- Open the kubectl command line tool.
- Run the following command, after replacing INSTANCE_NAME, USERNAME, PASSWORD and NAMESPACE with the relevant values
kubectl create secret generic k8s-informer-cred-INSTANCE_NAME --from-literal=.user=USERNAME --from-literal=.password=PASSWORD -n NAMESPACE
Note:
- If the Informer connects to the ServiceNow instance through a proxy server, you can provide the proxy user and password by adding the .proxyUser and .proxyPassword keys to the secret. For example:
kubectl create secret generic k8s-informer-cred-INSTANCE_NAME --from-literal=.user=USERNAME --from-literal=.password=PASSWORD --from-literal=.proxyUser=PROXY_USER --from-literal=.proxyPassword=PROXY_PASSWORD -n NAMESPACE.
- As an alternative to basic authentication, the Informer can use OAuth 2.0 authorization to connect to the ServiceNow instance for enhanced security. When the Informer uses OAuth 2.0, the instance issues an access token with an expiry time rather than requiring login credentials with each resource request.
- (Optional) If your organization's policy requires it, place the Informer docker image in your organization’s image repository.
Note: Starting in Kubernetes Visibility Agent version 3.9.0 (Informer version 2.3.0), released in November 2024, the docker image supports both arm64 and amd64 architectures. Upgrading from the previous image to the new one will not cause any disruptions. However, the new image requires more storage space in your image repository than the previous one did.
- Pull the image from Docker Hub and push it to your organization’s repository.Replace VERSION with the number of the most recent release, provided in the CNO for Visibility Helm Chart and Kubernetes YAML file releases [KB1564347] article in the Now Support Knowledge Base.
Docker pull docker.io/servicenowdocker/informer:VERSION
Docker tag docker.io/servicenowdocker/informer:VERSION COMPANY_REPO:VERSION
Docker push COMPANY_REPO:VERSION
- If the image repository requires authentication, create a secret named k8s-informer-repo-cred in the designated namespace.
- For example:
- (Optional) If outgoing traffic from your cluster flows through a proxy, identify the proxy host name and port used in your cluster.
- Note: Ask your organization’s Kubernetes team for this information. You need to provide it in the installation process.
- (Optional) Enable Kubernetes Visibility Agent to process more data simultaneously.By default, the Informer’s back-end side can handle data from around 300 clusters at the same time. If you have more clusters or your clusters undergo frequent changes, you can increase the number of concurrent worker threads used for processing the data.
Result
Your ServiceNow instance and the Kubernetes cluster are ready for Kubernetes Visibility Agent deployment.
Install Kubernetes Visibility Agent
You can install Kubernetes Visibility Agent using either a Helm chart or the Kubernetes YAML file.
This procedure describes the standard Kubernetes Visibility Agent installation process. Typically, you would use a Helm chart to perform the installation, but you can also configure and run the Kubernetes YAML file provided by ServiceNow.
Procedure
Install Kubernetes Visibility Agent using either a Helm chart or the Kubernetes YAML file provided by ServiceNow.
- Install Kubernetes Visibility Agent using a Helm chart.
- Edit the Helm install command.
- In the following command, replace NAMESPACE, INSTANCE_NAME, and CLUSTER_NAME with the relevant values and replace the HELM_URL with the URL of the most recent version, provided in the CNO for Visibility Helm Chart and Kubernetes YAML file releases [KB1564347] article.
Link -https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB1564347
helm install -n NAMESPACE --set acceptEula=Y --set instance.name=INSTANCE_NAME --set clusterName="CLUSTER_NAME" {--set image.repository=COMPANY_REPO --set image.tag=COMPANY_TAG} {--set proxyUrl=http://proxy_host:proxy_port} k8s-informer HELM_URL
Note:
- The curly brackets indicate that the code segments they surround are optional. Use these code segments if the image must be pulled from your organization’s image repository or if outgoing traffic from your cluster flows through a proxy.
- By passing --set acceptEula=Y, you agree to the End-User License Agreement. You can read the End-User License Agreement by extracting the EULA.pdf from informer-helm-<VERSION_NUMBER>.tgz.
- If the Informer is installed in OpenShift, add the openShift parameter to the command and set it to true
helm install -n NAMESPACE --set acceptEula=Y --set instance.name=INSTANCE_NAME --set clusterName="CLUSTER_NAME" {--set image.repository=COMPANY_REPO --set image.tag=COMPANY_TAG} {--set proxyUrl=http://proxy_host:proxy_port} {--set openShift=true} k8s-informer HELM_URL
Note: If the Informer is not installed in OpenShift, there is no need to set this parameter.
Install Kubernetes Visibility Agent using the Kubernetes YAML file.
- Download the Kubernetes YAML zip file provided in the CNO for Visibility Helm Chart and Kubernetes YAML file releases [KB1564347] article in the Now Support Knowledge Base.
- Extract the k8s_informer.yaml and EULA.pdf files from the zip file.
- Edit the k8s_informer.yaml file.
- Change the value of ACCEPT_EULA to "Y", as follows
- name: ACCEPT_EULA
value: "Y"
Note: By changing the value to "Y", you agree to the End-User License Agreement included in the EULA.pdf file.
- Replace all occurrences of <NAMESPACE> with the namespace in which you want to install the Informer.
- Replace all occurrences of <INSTANCE_NAME> with the name of your instance, without the domain name.
- Replace <CLUSTER_NAME> with the name of your cluster as it appears in the CMDB.
- If the Informer is installed in OpenShift, change the value of the OPENSHIFT environment variable to true.
- Run the command
kubectl apply -f k8s_informer.yaml
Result
Kubernetes Visibility Agent is deployed on the Kubernetes cluster and begins to stream data into your instance.