In this blog post, we go through and configure VMware vRealize Operations Manager (vROps) which Cloud Admins/Platforms Operators can take advantage of to help with monitoring and alerting on the underlying PKS infrastructure (compute, storage & networking). In addition, through the use of vROps Management Packs, users can also get additional visibility into the individually deployed PKS managed Kubernetes (K8S) Clusters which can be useful when debugging and with your development teams.
If you missed any of the previous articles, you can find the complete list here:
- Getting started with VMware Pivotal Container Service (PKS) Part 1: Overview
- Getting started with VMware Pivotal Container Service (PKS) Part 2: PKS Client
- Getting started with VMware Pivotal Container Service (PKS) Part 3: NSX-T
- Getting started with VMware Pivotal Container Service (PKS) Part 4: Ops Manager & BOSH
- Getting started with VMware Pivotal Container Service (PKS) Part 5: PKS Control Plane
- Getting started with VMware Pivotal Container Service (PKS) Part 6: Kubernetes Go!
- Getting started with VMware Pivotal Container Service (PKS) Part 7: Harbor
- Getting started with VMware Pivotal Container Service (PKS) Part 8: Monitoring Tool Overview
- Getting started with VMware Pivotal Container Service (PKS) Part 9: Logging
- Getting started with VMware Pivotal Container Service (PKS) Part 10: Infrastructure Monitoring
- Getting started with VMware Pivotal Container Service (PKS) Part 11: Application Monitoring
- vGhetto Automated Pivotal Container Service (PKS) Lab Deployment
Step 1 - Download and deploy vROps. In my setup, I am using the latest release which is 6.7 and if you would like a detailed step by step instructions, please take a look at the vOps documentation here. For lab and proof of concept purposes, you can select the "Extra Small" size when deploying the vROPs appliance.
Step 2 - Once vROps is up and running, we can start off by configuring the vSphere Adapter. To do so, select the Administration tab the top and then Solutions on the left hand side and find the adapter. Then click on the gear box to start the configure as shown in the screenshot below. Here you will need to provide the credentials to your vCenter Server, which you can test the connection before saving. If the connection is successful, you should start seeing data being retrieved by the adapter.
Step 3 - Next, we will need to download the vROps Management Pack for Containers which will give us additional information about our deployed K8S Clusters.
Step 4 - To import the management pack, under the Solutions section click on the "+" icon and then select the *.pak file that you had downloaded from the previous step and follow the wizard for installation instructions.
Step 5 - With the Container management pack installed, we now have the ability to monitor individual PKS managed K8S Clusters that have been deployed by PKS, which is pretty slick. To do so, we will need to retrieve the credentials using the PKS CLI (similar to what we would do to provide the K8S configuration file to our developers).
Use the following command to identify the PKS Clusters you wish to add to vROPs:
pks clusters
Next, run the following command and specify the name of the PKS Cluster to generate the K8S configuration file:
pks get-credentials [PKS-CLUSTER-NAME]
At this point, you will need to extract the following four pieces of information from ~/.kube/config which will be needed in the next step as highlighted in the screenshot below:
- K8S Server endpoint
- PKS Cluster Name
- K8S Username
- K8S Token
Note: You will need to repeat this for each PKS Cluster you plan to monitor in vROps.
Step 6 - Head back to vROps Solutions screen and then select the container management pack and click on the gear box to add the PKS Clusters to vROPs.
Step 7 - Click on the "+" icon to add a PKS Cluster. Using data from Step 5, we will go ahead and populate the following vROps fields: Display Name, Master URL & Credential (use type Token).
In my example, I have following:
- Display Name: k8s-cluster-01
- Master URL: https://pks-cluster-01:8443
- Credential Username: 8ebcb...
- Credential Token: eyJ...
Before saving, you can verify the settings are correct by using the "Test Connection" button. Once successful, you can then save and proceed to add other PKS Clusters into vROps.
Step 8 - To enable our new container dashboard, click on the Dashboards tab at the top and select "Kuberentes Environment" from the drop down menu of "All Dashboards". This will add our container dashboard to the left hand panel for access.
Step 9 - As you can see from the screenshot below, vROps has already connected to my deployed PKS managed K8S Cluster and started to received health and configuration metrics about my deployment. It not only provides information about the K8S infrastructure but also the K8S namespaces, pods, containers and services. Pretty slick! and there are several other portlets that contain other pieces of useful information such as utilization and performance.
Similar to vRLI, the integration with vROps is also "light" and requires a few additional steps to be taken by the Cloud Admin/Platform Operator after a new PKS Cluster is deployed. I can imagine in the future, this process would be completely automated given a vROps endpoint within a PKS Tile configuration. For now, users can still automate this process by consuming both PKS and vROps APIs.
Hshin says
Hello, I'm setting on vrops solution management to integrate pks and vrops w/ management pack for containers. But I have trouble in testing connection in step 7. I don't know which value is input on credentials. Please give me a hint. Thx.