CCIE or Null!

My journey to CCIE!

Poll individual virtual server statistics on F5 LTM’s using SNMP.

with 5 comments

It’s easy enough to log into an F5 LTM and view the current statistics concerning connections and other traffic statistics involving particular virtual servers but lets say you wanted to view this information over a specific time frame. Well that is were it gets a little tricky since you can’t view any historical information on the statistics page built-in on the F5 appliance. Which is one thing I really wish F5 would improve on, viewing historical performance information concerning virtual servers & pool members.

Luckily all the information found on the statistics page comes from internal MIB tables, meaning we can poll this same information into our NMS (Network Management Server) via SNMP. Finding the right OID is a bit tedious but it is a straight forward process. So lets run through at a high level regarding how to find out what MIB we need to poll for, and then we will look at an example.

  1. Decide which statistics you want to poll for. (Current Connection, Max Connections, etc)
    1. I recommend using a MIB Browser and Navigating to “1.3.6.1.4.1.3375.2.2.10.2.3.1” to see information that is available for you to poll for.
  2. LTM_VS_Stats
  3. Once you decide which statistic you want and you’ve located the OID in the MIB browser, copy or type it out the OID into notepad (or your preferred version of *pad)
  4. Now, go back to the F5 appliance and find the virtual server you want to collect this information from.
  5. Count the number of ASCII characters that are in the name of the virtual server. Including any underscores, dashes, etc.
    1. Once you this number tack it on to the end of the OID you copied in step #2.
  6. This is where the real fun begins. Now we need to convert the name of the virtual server from ASCII to Decimal. Including any underscores, dashes, etc.
    1. You can use an ASCII to Decimal calculator to make the conversation a bit easier.
    2. You will need to place a ‘.’ (Period) after each character in decimal format.
  7. Once you have the name converted decimal copy that information and append it to the end of the OID from step #4. (The OID in our notepad document off to the side)
  8. The OID you end up with, is what you need to poll for to get the particular virtual server information you are looking for.

To walk through this example one more time. Let’s say I want to poll for the number of current connections to a virtual server named ‘vs_web_http’.

  • First I’m am going to find the OID for virtual server current connections.

Which is:

1.3.6.1.4.1.3375.2.2.10.2.3.1.12.

  • The virtual server name has 11 characters in it, so now I need to update my OID with that information.

So my OID is now:

1.3.6.1.4.1.3375.2.2.10.2.3.1.12.11

  • Now I need to convert the name of my virtual server to decimal.

vs_web_http converted to ‘118.115.95.119.101.98.95.104.116.116.112’

Now to add that to my OID:

1.3.6.1.4.1.3375.2.2.10.2.3.1.12.11.118.115.95.119.101.98.95.104.116.116.112

And there we have it, that OID right there will pull the current connections on the virtual server ‘vs_web_http’.

Here is a quick breakdown of the OID format. Any other statistics follows this same format, so if you are planning to poll for a few different statistics on the same virtual server you simple need to replace the beginning of the OID with the OID you want to poll for.

OID

A few more extra details:

  • OID “1.3.6.1.4.1.3375.” marks the beginning of the F5 private MIB structure, which is where it branches off into the different ‘applications’ (LTM, ASM, etc)
  • OID “1.3.6.1.4.1.3375.2.2.10.” marks the beginning of F5 LTM Virtual Server information
  • All the F5 LTM Virtual Server statistics OID: “1.3.6.1.4.1.3375.2.2.10.2.3.1.” are contained within a table so depending on your management server you may have to specify the table information, or set it as a ‘Counter64’. In my experience with SolarWinds, I had to set the UnDP to poll for the ‘raw value’
  • You can download the F5 MIB directory off your F5 appliance from the main ‘overview’ page. This is pretty much your map for navigating the F5 MIB structure. There is a lot of useful information here if you have the time to actually dig through it. You can find a high level overview of the F5 MIB structure here.
LTM_MIB_DL

Screenshot from the ‘overview’ page on the F5 appliance.

Written by Stephen J. Occhiogrosso

January 6, 2014 at 10:59 AM

5 Responses

Subscribe to comments with RSS.

  1. This is awesome.

    Ryan G.

    April 28, 2014 at 12:09 PM

  2. Great article. One small thing I ran in to:

    Instead of adding the number of ascii characters after the location of the table, I had to add the partition name in ascii, and then the server name. For example:

    OID for current connections:1.3.6.1.4.1.3375.2.2.10.2.3.1.12.
    Partition name: /common/ (47.99.111.109.109.111.110.47)
    Virtual server name: vs_Example (118.115.95.69.120.97.109.112.108.101)

    Final OID to poll current connections for Virtual server “vs_Example”

    1.3.6.1.4.1.3375.2.2.10.2.3.1.12.47.99.111.109.109.111.110.47.118.115.95.69.120.97.109.112.108.101

    I am running version 11, this may have been changed from version 10, but I haven’t verified that anywhere. I can verify that this worked and the method you described did not, for some reason.

    dallanwagz (@dallanwagz)

    September 22, 2014 at 5:06 PM

    • Thanks for the heads up.

      When I initially wrote this I was running v10 in my environment.

      I’ve since upgraded to v11 I have not had a chance to visit this. Are you by any chance running multiple vCMP’s?

      Stephen J. Occhiogrosso

      September 22, 2014 at 7:55 PM

      • Excuse my ignorance, what is a vCMP?

        dallanwagz (@dallanwagz)

        September 23, 2014 at 12:04 AM

      • Virtualized Clustered Multiprocessing, it’s a VDC for a Nexus 7k or security context running a Cisco ASA but for F5’s. Multiple separate virtual instances running on the same hardware.

        Sorry for delayed response, I could swear I replied to you question over a week ago but it never posted.

        Also you are current I did some MIB walking on my 5200v and the OID structure has changed with v11! The common partition is now included!

        Thank you for letting me know!

        Stephen J. Occhiogrosso

        October 8, 2014 at 5:16 PM


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: