Sep 282014
 

If you’ve been reading some of my previous posts you would probably have noticed that I’ve been writing a fair amount about vCenter Operations. There is a reason for this; it’s a very extensible product. There is a decent amount of third-party integration with vCenter Operations as well as a high amount of customization out of the box. I hate having to use seven different tools to monitor apps and infrastructure. I think it’s awesome that VMware has enabled their partners to plug-in to this product and as I come across more integration I feel it’s important to let others know its capabilities. The PernixData FVP integration with vCenter Operations uses the SQL Loader Adapter which can be found in the VMware Cloud Management Marketplace. You will need to create an account, but you can download the adapter for free. There are a few steps that need to be done to get this going, so enough talky talk.

Ok, I know I said enough “talky talk” about 4 seconds ago, but I wanted to give a big thanks to Daniel Ricks (Twitter). Dan is an SE at PernixData and he not only took the time to figure out the process, generate the scripts, and get everything working, but Dan also took time out of his schedule to walk me through the process and even help me do some troubleshooting. Thanks Dan!

*** In this example I’m using vCenter Operations 5.8.2 Build 1885282 ***

Download and install the SQL Loader Adapter

  1. Download the SQL Loader Adapter from the URL mentioned above
  2. Install the SQL Loader Adapter
    1. Navigate to https://<ip of vcops UI vm>/admin and log in with the admin account
    2. Click the Update tab
    3. Click the Browse button and find the .pak file you downloaded in step 1 and click the Update button
    4. Click OK to the confirmation message > accept the EULA agreement and click OK
    5. Once complete close the admin page
  3. Log in to the custom UI for vCenter Operations (https://<ip of vcops UI vm>/custom>
  4. In the top right of the page click the Support hyperlink > click the Info tab and then click the Describe button, as shown below
  5. image
  6. Once the redescribe process happens you’ll see the General Sql Data Loader appear under the Name column

Upload and Configure Scripts

  1. Using WinSCP or some other tool to upload files, connect to the Analytics VM
  2. You’ll need to copy the following files to /usr/lib/vmware-viperl/apps/general/
    1. prnx-fvp-vcops.pl
    2. credstore_admin.pl
  3. SSH into the Analytics VM with the root credentials
  4. Navigate to /usr/lib/vmware-viperl/apps/general and run the following commands:
    1. chmod 555 prnx-fvp-vcops.pl
    2. chmod 555 credstore_admin.pl
  5. Now let’s store the vCenter administrator credentials so they aren’t plain text. Run the following command from the /usr/lib/vmware-viperl/apps/general directory:
    1. ./credstore_admin.pl add –server <vcenter-server> –username <username>   <<<< If you are prefacing the username with a domain make sure you use enclose it with quotes e.g. “labs\josh.coen”
    2. When prompted, enter the password for the user account you specified in the previous line and then confirm it
  6. The SQL loader adapter depends on a SQL query file that will run to collect the metrics from a given SQL database (we’ll configure this later). The prnx-fvp-vcops.pl file is what is used to generate that query file. Let’s edit the crontab file to have this file execute every 5 minutes. While still in the Analytics VM, do the following:
    1. Run crontab -e
    2. Press A to append the file and type */5 * * * * /usr/lib/vmware-viperl/apps/general/prnx-fvp-vcops.pl –server <vcenter-server> –username <username>  <<<< Make sure vCenter and the Username are the same as specified when you did step 5
    3. Press the Esc key and type :wq! and press Enter

Configure the SQL Loader Adapter

*** The SQL Loader Adapter does not support Windows integrated authentication. If you don’t have an internal SQL user account for the PernixData FVP database (the name of the database by default is prnx) then you, or your DBA, need to create a local SQL account and give it the db_owner role. The db reader role may be sufficient, but I’m not exactly sure. ***

  1. Log in to the custom UI for vCenter Operations (https://<ip of vcops UI vm>/custom>
  2. Hover over Environment > Configuration > click Adapter Instances
  3. image
  4. Click the Add button, it’s a green plus icon > select your collector > select General Sql Data Loader
  5. Fill out the form using the following information:
    1. Adapter Instance Name: Choose a name
    2. DB Type: MsSql
    3. Host: <sql server>
    4. Port: enter in the port for SQL Server. Standard SQL is 1433. Will be different if using SQL Express
    5. DB Name: prnx
    6. Timezone: Choose timezone of your Analytics VM. Mine is UTC
    7. Sql File: DB_QUERY_1.sql
    8. Properties File: DB_QUERY_1.properties
    9. Autodiscovery: true
    10. Credential: You need to first add a crednetial:
      1. Click the Add button
      2. Adapter kind: should already be set to General Sql Data Loader
      3. Credential Kind: General Sql Data Loader Credentials
      4. Instance Name: <ip of sql server>    <<<< if you have a named instance for your SQL server you need to add a “\<name of instance>” to the instance name, after the IP
      5. User Name: this is the SQL user that has access to the prnx database
      6. Password: <password for SQL user>
      7. Click OK
    11. image
    12. Choose the Credential you just created in step 10 and click the Test button. You should get a message that the test was successful. If you don’t then either the Host, Port, DB Name, credential, or a combination of those is incorrect. Here’s what the form looks like filled out:

image

Verify Everything is Working

Now we need to verify that the scripts we uploaded and configured, and the SQL Data Loader adapter we configured is correct. To do this we need to look and see if new resource kinds specific to PernixData FVP are now visible inside of vCenter Operations. To do this:

  1. While still logged into the vCenter Operations custom UI, navigate to Environment > Environment Overview
  2. Expand Resource Kinds > you should now see four additional resource kinds:
    1. PRNX:Flash Cluster
    2. PRNX:Flash Provider
    3. PRNX:Host
    4. PRNX:Virtual Machine
  3. image
  4. The resources listed under PRNX:Host and PRNX:Virtual machines have the same names as your standard host and virtual machine resources, but they have to be a different resource object instead of merging the new PernixData FVP metrics into you existing host and virtual machine objects

Practical Uses

Here are a few dashboards I threw together with our newly ingested metrics. The first one is a heatmap displays all virtual machines using FVP (using the resource kind PRNX:Virtual Machine). The size of each VM is based on the amount of local flash being used. The bigger the block, the more local flash is being used. The color is based on latency, with a very short scale. One end of the spectrum is set to 0ms of latency, that’s green. The other end is set to 5ms, that’s red. As you can see from the screen shot, all of these VMs are <5ms of latency. This is total latency, so read and write.

image

The second dashboard is a general scoreboard. This is showing how much local flash is being utilized by each of the hosts

image

The third dashboard is also a general scoreboard. This shows much network flash is being used by the VMs

image

 

Thanks for sticking with me through the process, if you’re trying to get this configured and run into issues, please feel free to reach out to me or Dan Ricks in the comments or on Twitter.

The two files I mentioned earlier, prnx-fvp-vcops.pl and credstore_admin.pl can be downloaded here. Again, big shout out to Dan Ricks who wrote the scripts to generate the SQL query files in order to feed the proper data into the Sql Data Loader Adapter. Great work, Dan.

Aug 272014
 
Visualizing vscsiStats via CloudPhysics

I was able to get a sneak peak at an unreleased feature from CloudPhysics last week and found out they are also showing it at their booth. The feature is called IO Workload Shapes and essentially it is the vscsiStats tool in a visual form. It is stunning (literally). I grabbed a few photos from [...]

Jul 172014
 
Operationalizing vCenter Operations - Part 1

I’ve been doing a lot of work with vCenter Operations over the last few months. I spent a lot of time with custom dashboards, super metrics and custom widgets based on XML files and widget interactions. The environment I’m in has an operations team responsible for monitoring 15+ vCenter environments. Most of the time spent [...]

Jul 082014
 
Varrow Bound

Starting July 28th, 2014 I will be moving to Varrow as a principal cloud architect. I am currently working with my boss (the illustrious Chris Horn) on what that is, so please, don’t ask. Seriously though, I will be covering things associated with the following words: Secure Cyber Metadata Scalable Five 9s Resilient Agnostic Cloud [...]

Jun 242014
 
Programmatically Push Custom Data into vCenter Operations

I’ve been doing a lot of customization with vCenter Operations Manager lately, mainly customized dashboards, and I wanted to explore ways of getting data into vCOps other than having to use a third party adapter (such as Hyperic) or make my own adapter. Enter the HTTP Post Adapter. The HTTP Post adapter comes with vCenter [...]

May 152014
 
Finding orphaned Virtual Machines - The Python Way

For the past few years I’ve done a little dabbling in Powershell for on-demand automation. I wanted to expand my horizons outside the realm of Powershell and find something more powerful, not only for vSphere, but other technologies that have APIs accessible via Python. I had never used Python, but had to start somewhere. I decided [...]

Apr 152014
 

In 2006 I had no idea what VMware was, let alone what virtualization was. At the time I was an active duty member in the United States Air Force working in communications doing AD migrations and file server consolidations onto CX700s. Fast forward to February 2014 and I’m VCDX #129. I first learned about virtualization [...]