WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud Foundation
  • VKS
  • Homelab
    • Resources
    • Nested Virtualization
  • VMware Nostalgia
  • Apple

Extracting VIN (vSphere Infrastructure Navigator) information using PowerCLI & vROps REST API

02.22.2017 by William Lam // 2 Comments

A request that I continue to receive from customers on a fairly regular basis is a way to extract the virtual machine application services and dependencies that is provided by vSphere Infrastructure Navigator (VIN) solution. Below is an example of what a VIN discovery might look like and in this case, it is actually mapping out the application and dependencies of itself.


Today, there is not a public API for VIN and although I have published several methods here, here and here on how to extract the information from VIN, the experience is still not very user friendly or easy to do.

Last week, while talking to a fellow colleague who works in our VMware Validated Design team, I found out that VIN actually has a vRealize Operations Manager (vROps) Management Pack and could potentially be useful in helping us retrieve the information generated by VIN.


Not having spent much time with vROps Management Packs, I understood at a high level they provided custom dashboards for vROps, but I was not sure if the data provided by the management packs could also be retrieved programmatically? It has also been some time since I have looked at the vROps REST API and specifically the "public" REST API which allows customers to retrieve the metrics collected from within vROps.

[Read more...]

Categories // Automation, PowerCLI, vRealize Suite Tags // infrastructure navigator, PowerCLI, vIN, vRealize Operations Manager, vROps

Automate forwarding of vRealize Operations Manager logs to Syslog Server

01.06.2015 by William Lam // 3 Comments

Forwarding logs to a syslog server from vRealize Operations Manager has been greatly simplified with the latest 6.0 release. Instead of having to manually tweak syslog-ng.conf with past releases, there is now a new UI option under Administration->Support->Logs which allows you to easily configure syslog configurations. There are currently 4 loggers (Analytics, Collector, Web & SuiteAPI) that can be configured to be forwarded to a syslog server.

forward-vrealize-operations-manager-to-syslog-0
To configure using the vROps UI, you select the root logger folder and then click on the gears icon at the top. From here, you can configure the syslog server as well as the syslog port.

forward-vrealize-operations-manager-to-syslog-1
Though this is a nice UI enhancement, it would have been really nice to have been able to configure this using an API. In doing some digging, I found that you could still automate the syslog configurations by simply adding a couple of lines into the respective log4j.properties files:

vROps Logger Configuration File
Analytics /usr/lib/vmware-vcops/user/conf/analytics/log4j.properties
Collector /usr/lib/vmware-vcops/user/conf/collector/log4j.properties
Web /usr/lib/vmware-vcops/user/conf/web/log4j.properties
SuiteAPI /usr/lib/vmware-vcops/tomcat-enterprise/webapps/suite-api/WEB-INF/log4j.properties

Here is a simple shell script called configurevROpsSyslog.sh that you can run against your vROps instance to forward your logs. There are two variables SYSLOG_SERVER and SYSLOG_SERVER_PORT that will need to be updated before running the script. Here is an example of running the script that can come in handy to forwarding your logs to your favorite syslog server such as vRealize Operations Insight.

forward-vrealize-operations-manager-to-syslog-2
UPDATE (01/17/15) - Thanks to Steve Flanders for letting me know there is one additional location for configuring syslog which is the Audit logs located in under Administration->Audit. It looks like the configuration also goes into the Collector log4j.properties and I have updated my script to ensure this is also configured as part of the script.

Screen Shot 2015-01-17 at 9.43.35 PM

Categories // Automation, vRealize Suite Tags // log4j.properties, syslog, vcops, vRealize Operations Manager, vROps

Automating Deployment & Configuration of vRealize Operations Manager 6.0 Part 2

12.12.2014 by William Lam // 4 Comments

Continuing from Part 1 of this three part series, you should now have a fully deployed vRealize Operations Manager connected on the network. You should see the following "Get Started" page when connecting to vROps via a web browser.

automate-deployment-and-configuration-vRealize-operations-manager-6.0-2
In this article, I will demonstrate how you can perform the initial configuration of your new vROps instance which includes configuring a password for the "admin" account that will be used to access the UI interface afterwards. You will also have the opportunity to configure basic things like NTP settings as well as the role of your vROps instance. If this is your first deployment of vROps 6.0, you will need to create a new Cluster where other "Slices" or vROps Instances can join and contribute different functionality such as Admin, UI, Data, Data Collector and Replica roles. In this example, we will assume the installation will contain all roles within this single instance. In the future, you can easily expand and add other instances that provide specific roles and in a future post, I can show how that can be accomplished using the CLI/API if there is an interest.

To perform the initial configurations, I have created a simple shell script called configurevRops.sh which requires SSH connectivity to the vROps instance. Ensure that during your initial setup, you have either enabled SSH or have gone into the VM Console and enabled SSH access. The script will be using the following four commands found within the appliance:

  • /usr/lib/vmware-casa/bin/ntp_update.py
  • /usr/lib/vmware-vcopssuite/utilities/sliceConfiguration/bin/vcopsSetAdminPassword.py
  • /usr/lib/vmware-vcopssuite/utilities/sliceConfiguration/bin/vcopsConfigureRoles.py
  • /usr/lib/vmware-vcopssuite/utilities/sliceConfiguration/bin/vcopsClusterManager.py

There is only one mandatory variable VROPS_ADMIN_PASSWORD that needs to be edited prior to running the script which specifies the password for the "admin" account. There is also a CONFIGURE_NTP & NTP_SERVERS variables that can be edited to configure NTP. By default, I have this disabled this because the system will need to validate the NTP Servers. If you do not have valid NTP Servers or be able to reach the ones specified in the script, then you may run into an error.

Once you have saved your changes, you can simply run the script using the following command (please replace the IP Address with the IP of your vROps instance):

ssh [email protected] < configurevRops.sh

automate-deployment-and-configuration-vRealize-operations-manager-6.0-2-1
Note: If you would like to see more verbose details for each of these steps, you can remove the redirect to /dev/null for reach of the commands and can be useful in case something is not running correctly.

If everything was successfully configured, you should now be able to open a browser to your vROps instance and you should see the following screen asking you to now login:

automate-deployment-and-configuration-vRealize-operations-manager-6.0-2-2
Please login with the username "admin" and the password that you had set within the script. Once you have successfully login, you should now see the following wizard which will take you through the final steps of setting up your new vROps instance. Unfortunately, these last couple of steps could not be automated and will require some manual interaction before you are ready to start using your new vRealize Operations Manager.

automate-deployment-and-configuration-vRealize-operations-manager-6.0-2-3

If you do not wish to enable SSH by default and prefer a more programmatic approach on performing the initial configurations, stay tune for Part 3 where I will show you how to use the new vRealize Operations Manager Cluster Mgmt API also known as the CaSA API to perform this exact same configuration.

Categories // Automation, vRealize Suite Tags // casa api, ntp_update.py, vcops, vcopsClusterManager.py, vcopsConfigureRoles.py, vcopsSetAdminPassword.py, vRealize Operations Manager, vROps

  • 1
  • 2
  • Next Page »

Search

Thank Author

Author

William is Distinguished Platform Engineering Architect in the VMware Cloud Foundation (VCF) Division at Broadcom. His primary focus is helping customers and partners build, run and operate a modern Private Cloud using the VMware Cloud Foundation (VCF) platform.

Connect

  • Bluesky
  • Email
  • GitHub
  • LinkedIn
  • Mastodon
  • Reddit
  • RSS
  • Twitter
  • Vimeo

Recent

  • Programmatically accessing the Broadcom Compatibility Guide (BCG) 05/06/2025
  • Quick Tip - Validating Broadcom Download Token  05/01/2025
  • Supported chipsets for the USB Network Native Driver for ESXi Fling 04/23/2025
  • vCenter Identity Federation with Authelia 04/16/2025
  • vCenter Server Identity Federation with Kanidm 04/10/2025

Advertisment

Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy

Copyright WilliamLam.com © 2025

 

Loading Comments...