What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general. You are invited to get involved by asking and answering questions!

Learn more

PRTG Network Monitor

Intuitive to Use. Easy to manage.
300.000 administrators have chosen PRTG to monitor their network. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free Download

Top Tags


View all Tags

SNMP Custom String Byte to Mega Byte Conversion

Votes:

0

Your Vote:

Up

Down

Hello

I have managed to extract value using regular expression. My result comes in as Byte But I want to display it as KiloByte or MegaByte

Thank you.

custom-string-sensor snmp snmp-custom-sensor

Created on Nov 10, 2014 5:55:24 AM by  amarc (0) 1



6 Replies

Votes:

0

Your Vote:

Up

Down

Hello,

Thank you very much for using PRTG. Please use a Sensor Factory Sensor here for the conversion.

best regards.

Created on Nov 10, 2014 8:28:43 AM by  Torsten Lindner [Paessler Support]



Votes:

0

Your Vote:

Up

Down

Hi Torsten,

Yes , that could be used. However , I am trying to do the following thing -

Step 1 - I have powershell script which can find out all VIP (virtual servers) on balancer and convert them to OID

Step 2- I am using PRTG API to check if there exists sensor for the above retrieved data(OID) from balancer.

Step 3- If there exists a sensor , skip that VIP. if not , I am cloning a demo/dummy custom string sensor and changing its OID to one of the VIPs.

So with this process , I can somewhat automate the graph generation for new VIPs on balancer's.

So For example , I have 100 VIP on 1 balancer which will generate 200 sensors (Traffic IN&Out) , Now using Sensor Factory Sensor I will have to create another 100 Sensors for data conversion. I don't think that would be feasible solution.

Would there be any other way for doing this ?

Thanks a lot, Amar

Created on Nov 10, 2014 8:37:53 AM by  amarc (0) 1



Votes:

0

Your Vote:

Up

Down

Well, then I'd suggest to convert the value inside your script.

Created on Nov 10, 2014 8:39:57 AM by  Torsten Lindner [Paessler Support]



Votes:

0

Your Vote:

Up

Down

Hi,

My script is not querying for traffic data , it will just create custom string sensor and give them the OID. So the custom string sensor can work on its own.

Sorry , Its little complicated , It took me long to figure this out. The flow of things are as below :

1. PowerShell Script (Get VIPs and converts them to OID)

2. Check PRTG for existing VIP sensors - compare OID

3. If there is no existing sensors , Clone a dummy sensor and change its OID

4. Start the new cloned dummy sensors with new OID (It works on its own hence forth)

This is what I am doing , Does this make sense ?

Thank You

Created on Nov 10, 2014 8:48:08 AM by  amarc (0) 1



Votes:

0

Your Vote:

Up

Down

Then the Sensor Factory is the only option.

Created on Nov 10, 2014 8:52:03 AM by  Torsten Lindner [Paessler Support]



Votes:

0

Your Vote:

Up

Down

Damn , I was really hoping to get this balancer thing working , I guess I will just have to move away from PRTG now. Please consider adding support(auto-discovery and all) for Balancers , They also are critical part of infrastructure , I have been testing PRTG for over 15 days now and I really don't think it should be that difficult , Most of the devices have pretty straight forward SNMP support.

Thanks for the help. Amar

Created on Nov 10, 2014 9:09:47 AM by  amarc (0) 1



Please log in or register to enter your reply.


Disclaimer: The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.