Quantcast
Channel: THWACK: All Content - Orion SDK
Viewing all 2677 articles
Browse latest View live

AppInsight for IIS assing to node API

$
0
0

Associating a AppInsight for IIS to a node using API. I tried to use Orion.APM.Application.CreateApplication and Orion.APM.IIS.Application.CreateApplication and did not work


How to monitor for a HTTP 200 OK response?

$
0
0

I am trying to set up a API healthcheck against one of our vendors.

The url is: https://rxsx.xxx.com/xapi/healthcheck

This will return a HTTP 200 OK if there API is up and processing. 

 

I've tried to set it up using the HTTPS monitor by putting in the https://${IP}:${PORT}/xapi/healthcheck using Put and Get but it fails with underlying connection was closed.

How can I monitor this check for HTTP 200 OK?

 

 

Thanks,

Kat

how to delete unmanaged nodes in Solarwinds.

$
0
0

how to delete unmanaged nodes in Solarwinds.

Deleting Nodes (Can't get it to work with Perl LWP or Curl)

$
0
0

Hello All,

I'm working on a project that requires us to change the IP address of every server in our infrastructure. There are a number of operations that happen on different servers as part of this process. I'm using Perl for the controlling process, and it executes all these different operations on different servers. Some REST, some curl, a kerberos init, some SSH remote commands and so on. It talks to Windows and Linux as part of the process. In the case of SolarWinds, I have to perform several operations via REST; look up node ID (working), look up available IP addresses from the pool (working), delete the node (NOT working), and re-add the node when the other operations are completed at the end (untested).

 

The issue with deleting nodes seems to be related to how the request is being sent.  I get the same results whether I send the request with LWP::Simple or a or plain old command line curl. To reiterate, the SQL queries sent via either LWP, Net::SolarWinds::REST, or Curl all work as expected, only the DELETE does not work.

 

I can get the delete to work using WizTools RESTClient 3.5 (a freeware REST tool), using the same URL Perl and Curl are using, so I suspect there is some bit of syntax I'm missing.

 

Here's the Perl source in question (I don't see a way to mark up source, I hope it displays well):

The get works, the DELETE does not (error at the bottom)

################################################################################

## NAME: deleteSWNode

## PURPOSE: Deletes node from Solar Winds in prep for re-ip

## ex: my $rawDeleteOutput = deleteSWNode(drreconfigt1-1.secnet.domain.com);

################################################################################

sub deleteSWNode

{

  my $subName = "deleteSWNode";

    my ($targetNode) = @_;

    my ($browser, $request, $connString, $deleteString, $response, $req);

 

    ## set up the connection

    my $authString = "https://orion:17778/SolarWinds/InformationService/v3/Json/swis://MOSOLAR01.WINNT.secnet.domain.com/Orion/Orion.Nodes/NodeID=2512";

    $connString = "https://orion:17778/SolarWinds/InformationService/v3/Json/Query?query=SELECT+IPAddress+FROM+IPAM.IPNode+WHERE+IPAddress+LIKE+'172.27.13%'+AND+STATUS+=2";

 

  $browser = LWP::UserAgent->new;

  $browser->ssl_opts(verify_hostname => 0);

  ##$req =  HTTP::Request->new( GET => "$connString");

  $req =  HTTP::Request->new( DELETE => "$authString");

  $req->authorization_basic( "$aduser", "$adauth" );

 

    $response = $browser->request($req);

     if ($response->is_success)

     {

      print $response->decoded_content;

      return('DELETED');

  }

  else

  {

  my $stat1 = $response->decoded_content;

  my $stat2 = $response->status_line;

 

  print Dumper($stat1);

  print "\n\n";

  print Dumper($stat2);

  }

}

 

 

 

Delete from the command line with curl (works as expected for sending SQL):

[jdc@vsfileq2 ~]$ curl -k -i -H "Accept: application/json" --user jdc:'PASSHOLDER' -X DELETE 'https://orion:17778/SolarWinds/InformationService/v3/Json/swis://MOSOLAR01.WINNT.secnet.domain.com/Orion/Orion.Nodes/NodeID=2512'

HTTP/1.1 400 Bad Request

Content-Length: 580

Content-Type: application/json

Server: Microsoft-HTTPAPI/2.0

Date: Thu, 28 Jul 2016 21:52:37 GMT

 

 

 

Both attempts produce the same error:

{"Message":"No such entity instance.\u000d\u000aParameter name: uri","ExceptionType":"System.ArgumentException","FullException":"System.ArgumentException: No such entity instance.\u000d\u000aParameter name: uri\u000d\u000a   at SolarWinds.InformationService.Core.CrudProcessor.DeleteInternal(Boolean bulkMode, SwisUriResolver uriResolver, IQueryExecutionContext context)\u000d\u000a   at SolarWinds.InformationService.Core.CrudProcessor.Delete(SwisUri uri, IQueryExecutionContext context)\u000d\u000a   at SolarWinds.InformationService.Core.InformationService.Delete(String uri)"}

 

Any thoughts?

Deleting an Orion Agent and its Node using Powershell SDK instead of GUI

$
0
0

I want to replicate the behavior in the GUI that occurs if I go to:

 

https://myOrionServer/Orion/AgentManagement/Admin/ManageAgents.aspx

 

Select an Agent, and click Delete. This not only removes the Agent registration, it also deletes the Node and cleans up everything associated with it.

 

I THINK the correct way to do that with Powershell is:

 

invoke-swisverb $swis Orion.AgentManagement.Agent delete @($agentid)

 

Where $swis is the SwisConnection, Orion.AgentManagement.Agent is the Entity, delete is the Verb, and $agentid is the integer in the AgentId column in the Orion.AgentManagement.Agent table.

 

Am I correct in my syntax? Will this accomplish the same thing that using the GUI does when I select an Agent and click Delete? If not, what else would I need to do?

Populate AcknowledgedNote field in AlertActive table via Acknowledge Rest API call

$
0
0

Hi,

I am using the Rest API Method to acknowledge an active alert

 

bool Acknowledge(int[] alertObjectIds, string note).

 

With this method the note is appended in the AlertsStatus.Note field which is fine.

 

However I also want to populate the AcknowledgedNote field in the ActiveAlert table with a value when I acknowledged an Alert.

Are there any Rest API calls to do this? I know that the data in the  "ActiveAlert.AcknowledgeNote" field will be deleted once an Alert is not active and that's exactly what I want to achieve.

 

Thanks in Advance

 

Hitesh

List of properties that a node should have ? (a router for NPM)

$
0
0

Hello,

 

I'm new to this software so I have a few questions that might seem obvious.

 

Does anyone have a list of properties that a node should have when creating one using the api? I´m using a python code I found on the internet for adding nodes in NPM and I would like to know what are the names of the fields that you usually have to fill out to create a node. I've been trying to find some documentation about this, but without success.

 

Thank you in advance,

Orion SDK with PowerShell - manage/unmanage multiple nodes

$
0
0

I've been able to script unmanaging and managing nodes in powershell. However, for 400+ nodes, this ends up taking quite a while. Via script, it takes about 7 minutes to unmanage the nodes and over 10 minutes to remanage them. Doing this from the website takes about 25 seconds and no more than a minute, respectively. My guess is that the website somehow group updates the database instead of doing it one at a time. Anyone else seen this or have any idea how to do more than one node at a time? Below is sample code for how I am unmanaging a single node:

 

Invoke-SwisVerb $swis Orion.Nodes Unmanage @("N:$nodeid",$start,$end,"false")

 

Thanks for any advice you have!


SWQL queries not working in Custom Query and Custom Reports since NPM v12 but still working in SWQL studio

$
0
0

Hello World

 

before the upgrade to NPM v12 we were using some custom queries in order to extract IOPs per process from the database and create charts and tables with that. Everything was working beautifully until the upgrade to NPM v12, since then the query is not working (error message) on any web resources, however it still works in SWQL studio.

 

I've been troubleshooting the query and the issue is in the 'in (Select...)' statement. It works fine if you add values inside the in (example pec.componentid in ('10','20','30'...) but it doesn't with another WHERE clause.

 

 

It would be nice if we could get a response from the development team and if they could confirm that SWQL queries that are working in SWQL studio will also be working on the web interface? Otherwise, what's the point of SWQL studio? (yes, i know that there are lots of different things you can do with it, but this is one of the main ones, at least for a lot of SW users).

 

 

Query:

 

SELECT pec.componentid, ( pec.avgioreadoperationspersec + pec.avgiowriteoperationspersec )
AS avgiops, pec.timestamp, cst.componentprocessname, cst.componentprocessname + ' from ' + cst.componentname + ' on ' + n.caption
AS fullname
FROM orion.apm.processevidencechart pec inner join orion.apm.currentstatistics cst
ON cst.componentid = pec.componentid inner join orion.apm.component comp
ON comp.componentid = pec.componentid inner join orion.apm.applicationalert appl
ON appl.id = comp.applicationid inner join orion.nodes n
ON n.nodeid = appl.nodeid

WHERE pec.timestamp> ${FromTime} AND pec.timestamp< ${ToTime}
AND pec.componentid IN

 

(

SELECT top 10 componentid
FROM orion.apm.processevidencechart pec inner join orion.apm.component comp
ON comp.componentid = pec.componentid WHERE pec.timestamp> ${FromTime}
AND pec.timestamp< ${ToTime} AND avgioreadoperationspersec IS NOT NULL
AND avgiowriteoperationspersec IS NOT NULL AND comp.applicationid = ${applicationid}
GROUP BY componentid
ORDER BY avg ( avgioreadoperationspersec + avgiowriteoperationspersec )

DESC

)

 

The problem also is that we use this structure in order to extract other type of information....

 

Regards

 

Raul

 


Issue with API Creating Discovery

$
0
0

I am having an issue in my production environment this worked fine in a test lab but not production Solarwinds.

The error in the discovery is

 

A Network Discovery job has failed to complete.\r\nState: Failed\r\nProfile id: 106.\r\nThe Job Scheduler is reporting the following error:\r\nSolarWinds.JobEngine.WorkerProcess.JobExecutionException: System.Exception: Unable to deserialize job description. ---> System.Runtime.Serialization.SerializationException: Error in line 0 position 0. Element 'http://schemas.datacontract.org/2004/07/SolarWinds.Orion.Core.Models.Discovery:DiscoveryPluginJobDescriptionBase' contains data from a type that maps to the name 'http://schemas.solarwinds.com/2008/DeviceStudio:DeviceStudioDiscoveryPluginJobDescription'. The deserializer has no knowledge of any type that maps to this name. Consider using a DataContractResolver or add the type corresponding to 'DeviceStudioDiscoveryPluginJobDescription' to the list of known types - for example, by using the KnownTypeAttribute attribute or by adding it to the list of known types passed to DataContractSerializer.

 

 

Here is the code :

 

       public HttpResponseMessage Post([FromBody]NodeInfo info)

        {

             CustomNodeInfo cnInfo = new CustomNodeInfo();

            #region Hard Coded Values for SaaS

            //Hard coding these for now as this is for just the SaaS Poller currently

            info.EngineID = 12;

            cnInfo.Custom1 = "1";

            cnInfo.Custom2 = "2";

            cnInfo.Custom3 = "3";

            //End Hard Coded

            #endregion

 

 

            info.ObjectSubType = "SNMP";

            info.SNMPVersion = "2";

            info.EntityType = "Orion.Nodes";

            info.DynamicIP = false;

            info.Status = 1;

            info.UnManaged = false;

            info.Allow64BitCounters = false;

            if (ModelState.IsValid)

            {

                string query = "{\"query\":\"SELECT PropertyValue FROM Orion.EngineProperties WHERE EngineID=@e AND PropertyName='Orion.Standard.Polling'\",\"parameters\":{\"e\":" + info.EngineID + "}}";

 

 

                JObject pollingRate = JObject.Parse(SWJsonCall.Post("Json/Query", query));

 

 

                int curRate = (Int32)pollingRate["results"][0]["PropertyValue"];

                if (curRate < 85)

                {

                    #region Start Discovery on New Node

                    var dis = new DiscoveryInfo

                    {

                        Name = "API Add Node " + info.IPAddress,

                        EngineID = info.EngineID,

                        JobTimeoutSeconds = 3600,

                        SearchTimeoutMiliseconds = 5000,

                        SnmpTimeoutMiliseconds = 5000,

                        SnmpRetries = 2,

                        RepeatIntervalMiliseconds = 1800,

                        SnmpPort = 161,

                        HopCount = 0,

                        PreferredSnmpVersion = "SNMP2c",

                        DisableIcmp = false,

                        AllowDuplicateNodes = true,

                        IsAutoImport = true,

                        IsHidden = false,

                    };

                    dis.PluginConfigurations = new List<PluginItems> { new PluginItems { PluginConfigurationItem = DiscoveryProfiles.SNMPv2(info.Community, info.IPAddress) } };

 

 

                    DiscoveryInfo[] disArray = new DiscoveryInfo[] { dis };

 

 

                    string createDiscovery = SWJsonCall.Post("Json/Invoke/Orion.Discovery/StartDiscovery", JsonConvert.SerializeObject(disArray));

                    #endregion

 

 

                    JObject disStatus = null;

                    Stopwatch time = new Stopwatch();

                    time.Start();

                    do

                    {

                        string statusQuery = "{\"query\":\"SELECT Status,StatusDescription FROM Orion.DiscoveryProfiles where ProfileID=@id\",\"parameters\":{\"id\":\"" + createDiscovery + "\"}}";

                        disStatus = JObject.Parse(SWJsonCall.Post("Json/Query", statusQuery));

                        if (time.ElapsedMilliseconds > 120000) return Request.CreateResponse(HttpStatusCode.RequestTimeout, "This has taken over 120 seconds it should not take that long this might be something wrong with the information provided.");

                    } while (disStatus["results"][0]["Status"].ToString() == "0" || disStatus["results"][0]["Status"].ToString() == "1" || !disStatus["results"].HasValues);

 

 

                    if (disStatus["results"][0]["Status"].ToString() == "2")

                    {

                        string nodeQuery = "{\"query\":\"SELECT Uri,NodeID FROM Orion.Nodes where IPAddress=@ip AND EngineID=@e\",\"parameters\":{\"ip\":\"" + info.IPAddress + "\", \"e\": " + info.EngineID + "}}";

                        JObject nodeStatus = JObject.Parse(SWJsonCall.Post("Json/Query", nodeQuery));

                        string swisUrl = nodeStatus["results"][0]["Uri"].ToString();

                        string updateProps = SWJsonCall.Post("Json/" + swisUrl + "/CustomProperties", JsonConvert.SerializeObject(cnInfo));

                    }

                    else return Request.CreateResponse(HttpStatusCode.ExpectationFailed, disStatus["results"][0]["StatusDescription"].ToString());

 

 

                    return new HttpResponseMessage(HttpStatusCode.Created);

                }

                else

                {

                    return Request.CreateResponse(HttpStatusCode.InternalServerError, "Polling rate at dangerous level " + curRate + "%. Please consult Admins, node NOT added.");

                }

            }

            else

            {

                var message = string.Join(" | ", ModelState.Values.SelectMany(v => v.Errors).Select(e => e.ErrorMessage));

                var execption = string.Join(" | ", ModelState.Values.SelectMany(v => v.Errors).Select(e => e.Exception));

                return Request.CreateResponse(HttpStatusCode.BadRequest, "Error - " + message + " : " + execption);

            }

        }

 

 

 

Here is the discovery profile model.

 

        public static string SNMPv2(string community, string ipaddress)

        {

            string discoveryProfileXML = "<PluginItems xmlns=\"http://schemas.datacontract.org/2004/07/SolarWinds.Orion.Core.Models.Discovery\">\n" +

            "<knownTypes>\n" +

            "<ArrayOfstring xmlns=\"http://schemas.microsoft.com/2003/10/Serialization/Arrays\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\">\n" +

            "<string>SolarWinds.Orion.Core.Models.Discovery.CoreDiscoveryPluginConfiguration,SolarWinds.Orion.Core.Models</string>\n" +

            "</ArrayOfstring>\n" +

            "</knownTypes>\n" +

            "<pluginItem>\n" +

            "<ArrayOfDiscoveryPluginConfigurationBase xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\">\n" +

            "<DiscoveryPluginConfigurationBase i:type=\"d2p1:CoreDiscoveryPluginConfiguration\" xmlns:d2p1=\"http://schemas.solarwinds.com/2008/Orion\">\n" +

            "<d2p1:AddressRange/>\n" +

            "<d2p1:AgentsAddresses xmlns:d3p1=\"http://schemas.microsoft.com/2003/10/Serialization/Arrays\"/>\n" +

            "<d2p1:BulkList xmlns:d3p1=\"http://schemas.microsoft.com/2003/10/Serialization/Arrays\">\n" +

            "<d3p1:string>"+ipaddress+"</d3p1:string>\n" +

            "</d2p1:BulkList>\n" +

            "<d2p1:Credentials>\n" +

            "<d2p1:credentials>\n" +

            "<knownTypes>\n" +

            "<ArrayOfstring xmlns=\"http://schemas.microsoft.com/2003/10/Serialization/Arrays\">\n" +

            "<string>SolarWinds.Orion.Core.Models.Credentials.SnmpCredentialsV2,SolarWinds.Orion.Core.Models</string>\n" +

            "</ArrayOfstring>\n" +

            "</knownTypes>\n" +

            "<pluginItem>\n" +

            "<d2p1:ArrayOfCredential>\n" +

            "<d2p1:Credential i:type=\"d2p1:SnmpCredentialsV2\">\n" +

            "<d2p1:Description i:nil=\"true\"/>\n" +

            "<d2p1:ID i:nil=\"true\"/>\n" +

            "<d2p1:IsBroken>false</d2p1:IsBroken>\n" +

            "<d2p1:Name>"+community+"</d2p1:Name>\n" +

            "<d2p1:Owner i:nil=\"true\"/>\n" +

            "<d2p1:Community>"+community+"</d2p1:Community>\n" +

            "</d2p1:Credential>\n" +

            "</d2p1:ArrayOfCredential>\n" +

            "</pluginItem>\n" +

            "</d2p1:credentials>\n" +

            "</d2p1:Credentials>\n" +

            "<d2p1:DiscoverAgentNodes>false</d2p1:DiscoverAgentNodes>\n" +

            "<d2p1:SharedCredentials xmlns:d3p1=\"http://schemas.microsoft.com/2003/10/Serialization/Arrays\"/>\n" +

            "<d2p1:SubnetList/>\n" +

            "<d2p1:WmiRetries>1</d2p1:WmiRetries>\n" +

            "<d2p1:WmiRetryInterval>PT10S</d2p1:WmiRetryInterval>\n" +

            "</DiscoveryPluginConfigurationBase>\n" +

            "</ArrayOfDiscoveryPluginConfigurationBase>\n" +

            "</pluginItem>\n" +

            "</PluginItems>\n";

 

 

            return discoveryProfileXML;

        }

Using the API, is it possible to control the services?

$
0
0

Can the services be controlled much like the Service Manager "Start Everything" and "Stop Everything".

My environment has 10 pollers and it would be nice to be able to run a script to shut down all the services on each device, then start them again.

Node Discovery Error

$
0
0

I am currently running into an issue while running a Node Discovery via RestAPI.  I am seeing the following error in Status Description within SWQL Studio.   I have noticed is when I login into Orion and edit the Discovery Profile and click through it without modifying any settings the profile will run correctly and then the next attempted API call will work correctly without an error until the next day. 

 

I have also included my JSON for failed discovery in the attachment. 

(Updated information)

Through some additional testing the following has been found.

  • Receive this error when using secondary Orion Engine's
  • Will not receive error if click through failed Job and manual start discovery via Web Page.  The next jobs will work correctly for about 20 mins and then start failing again.

 

 

 

ERROR -

A Network Discovery job has failed to complete.\r\nState: Failed\r\nProfile id: 59.\r\nThe Job Scheduler is reporting the following error:\r\nSolarWinds.JobEngine.WorkerProcess.JobExecutionException: System.Exception: Unable to deserialize job description. ---> System.Runtime.Serialization.SerializationException: Error in line 0 position 0. Element 'http://schemas.datacontract.org/2004/07/SolarWinds.Orion.Core.Models.Discovery:DiscoveryPluginJobDescriptionBase' contains data from a type that maps to the name 'http://schemas.solarwinds.com/2008/DeviceStudio:DeviceStudioDiscoveryPluginJobDescription'. The deserializer has no knowledge of any type that maps to this name. Consider using a DataContractResolver or add the type corresponding to 'DeviceStudioDiscoveryPluginJobDescription' to the list of known types - for example, by using the KnownTypeAttribute attribute or by adding it to the list of known types passed to DataContractSerializer.

   at System.Runtime.Serialization.XmlObjectSerializerReadContext.InternalDeserialize(XmlReaderDelegator reader, String name, String ns, Type declaredType, DataContract& dataContract)

   at System.Runtime.Serialization.XmlObjectSerializerReadContext.InternalDeserialize(XmlReaderDelegator xmlReader, Int32 id, RuntimeTypeHandle declaredTypeHandle, String name, String ns)

   at ReadArrayOfDiscoveryPluginJobDescriptionBaseFromXml(XmlReaderDelegator , XmlObjectSerializerReadContext , XmlDictionaryString , XmlDictionaryString , CollectionDataContract )

   at System.Runtime.Serialization.CollectionDataContract.ReadXmlValue(XmlReaderDelegator xmlReader, XmlObjectSerializerReadContext context)

   at System.Runtime.Serialization.XmlObjectSerializerReadContext.ReadDataContractValue(DataContract dataContract, XmlReaderDelegator reader)

   at System.Runtime.Serialization.XmlObjectSerializerReadContext.InternalDeserialize(XmlReaderDelegator reader, String name, String ns, Type declaredType, DataContract& dataContract)

   at System.Runtime.Serialization.XmlObjectSerializerReadContext.InternalDeserialize(XmlReaderDelegator xmlReader, Int32 id, RuntimeTypeHandle declaredTypeHandle, String name, String ns)

   at ReadDiscoveryJobDescriptionFromXml(XmlReaderDelegator , XmlObjectSerializerReadContext , XmlDictionaryString[] , XmlDictionaryString[] )

   at System.Runtime.Serialization.ClassDataContract.ReadXmlValue(XmlReaderDelegator xmlReader, XmlObjectSerializerReadContext context)

   at System.Runtime.Serialization.XmlObjectSerializerReadContext.ReadDataContractValue(DataContract dataContract, XmlReaderDelegator reader)

   at System.Runtime.Serialization.XmlObjectSerializerReadContext.InternalDeserialize(XmlReaderDelegator reader, String name, String ns, Type declaredType, DataContract& dataContract)

   at System.Runtime.Serialization.XmlObjectSerializerReadContext.InternalDeserialize(XmlReaderDelegator xmlReader, Type declaredType, DataContract dataContract, String name, String ns)

   at System.Runtime.Serialization.DataContractSerializer.InternalReadObject(XmlReaderDelegator xmlReader, Boolean verifyObjectName, DataContractResolver dataContractResolver)

   at System.Runtime.Serialization.XmlObjectSerializer.ReadObjectHandleExceptions(XmlReaderDelegator reader, Boolean verifyObjectName, DataContractResolver dataContractResolver)

   at System.Runtime.Serialization.DataContractSerializer.ReadObject(XmlReader reader, Boolean verifyObjectName)

   at SolarWinds.Orion.Common.SerializationHelper.FromXmlReader[T](XmlReader reader, Boolean verifyObjectName, IEnumerable`1 knownTypes)

   at SolarWinds.Orion.Common.SerializationHelper.FromXmlReader[T](XmlReader reader, IEnumerable`1 knownTypes)

   at SolarWinds.Orion.Discovery.Job.OrionDiscoveryJob.GetDiscoveryJobContext(String jobDetailConfiguration, IDiscoveryPluginFactory pluginFactory, List`1& plugins)

   --- End of inner exception stack trace ---

   at SolarWinds.Orion.Discovery.Job.OrionDiscoveryJob.GetDiscoveryJobContext(String jobDetailConfiguration, IDiscoveryPluginFactory pluginFactory, List`1& plugins)

   at SolarWinds.Orion.Discovery.Job.OrionDiscoveryJob.ConfigureJobContext()

   at SolarWinds.Orion.Discovery.Job.OrionDiscoveryJob.Execute(IJobExecutionHost host)

   at SolarWinds.JobEngine.WorkerProcess.Job2Adapter.Execute(IInternalJobExecutionHost host)

   at SolarWinds.JobEngine.WorkerProcess.Job2Adapter.Execute(IInternalJobExecutionHost host)

   at SolarWinds.JobEngine.WorkerProcess.JobDecorator.Execute(IInternalJobExecutionHost host)

   at SolarWinds.JobEngine.WorkerProcess.AgentDispatcher.ExecuteJobSynchronously(ActiveJob activeJob)

   at SolarWinds.JobEngine.WorkerProcess.AgentDispatcher.ExecuteJob(ActiveJob activeJob)

   at SolarWinds.JobEngine.WorkerProcess.AgentDispatcher.WorkItemDispatched(Object state)

   at SolarWinds.JobEngine.WorkerProcess.Job2Adapter.Execute(IInternalJobExecutionHost host)

   at SolarWinds.JobEngine.WorkerProcess.JobDecorator.Execute(IInternalJobExecutionHost host)

   at SolarWinds.JobEngine.WorkerProcess.AgentDispatcher.ExecuteJobSynchronously(ActiveJob activeJob)

   at SolarWinds.JobEngine.WorkerProcess.AgentDispatcher.ExecuteJob(ActiveJob activeJob)

   at SolarWinds.JobEngine.WorkerProcess.AgentDispatcher.WorkItemDispatched(Object state)

 

Message was edited by: Shawn Stamper

SDK Introduction

$
0
0

Would anyone be able to point me to an article or reference material where some very basic and easy tasks are completed using the API ? 

SQL Query for DNS addresses - list of tables

$
0
0

I am looking to find the table that contains the 'Network Interfaces' information under the 'Asset Inventory' for a node so I can query the DNS entries and run a quick report.

 

Thanks for any help you can give me on where to find these tables.

Any new OrionSDK features in NPM 12.0?

$
0
0

I hear that NPM 12 will be reaching RC in the near future, does this release have any new API features? Anything which will make automation for adding new nodes will be welcomed.

 

Jon.


Discovering volume for a node in python

$
0
0

Im looking for a way to get the list of volume from a node.

 

I used SWQL to obtain the list from Orion NPM, but since none of the Node's volume have been discovered it return an empty list.

 

Is there a way to trigger a volume discovery from the API for a specific Node?

is this obtained by some pollers I need to assign to the node for this to happen?

How do I add CPU, RAM, and Disk pollers to a new SNMP node via the Python API?

$
0
0

I am attempting to add nodes via SNMP using python.  I have previously been using ICMP to add the nodes only for Status and response time polling, but would like to expand further and gather more information automatically.  Is there a good way to try to authenticate over SNMP using the SNMP string, and if the string verifies, add the node?  I currently am using this snippet of code, and it does successfully add an SNMP node, but the only statistics that show up on the node page are for Average Response Time and Packet Loss, but CPU load, Memory, and any disks are not detected.  I may not be fully understanding the polling aspect and how it works in regards to the API, but I would like to essentially recreate what happens when I "List Resources" on a node and select which disks, CPU, RAM, and other properties to monitor.  If someone could take a look at my poller options and let me know if I am making a mistake somewhere that would be great.


Also, can I use some sort of try/catch exception handling when adding SNMP nodes, in case the string does not authenticate, I can revert back to adding the node via simply ICMP?


Thanks!


uri = swis.create(EntityType,   IPAddress = IP_input,   IPAddressGUID = ip_to_guid(IP_input),   Caption = str(IP_input),   DynamicIP = False,   EngineID = 1,   Status = 1,   UnManaged = False,   Allow64BitCounters = True,   ObjectSubType = "SNMP",   MachineType = "",   VendorIcon = "",   RediscoveryInterval = 30,   PollInterval = 60,   StatCollection = 1,   City = "REDACTED",   Managed_Monitored = "REDACTED",     Node_Type = "TBD",   ALERT_CPU = 90,   ALERT_RAM = 90,   Community = 'REDACTED',   SNMPVersion=2   )  # Get all object properties for new node added  obj = swis.read(uri)  snmpDetailsUri = swis.create("Orion.Pollers", PollerType = "N.Details.SNMP.Generic", NetObject="N:" + str(obj["NodeID"]), NetObjectType="N", NetObjectID=obj["NodeID"])  snmpUptimeUri = swis.create("Orion.Pollers", PollerType = "N.Uptime.SNMP.Generic", NetObject="N:" + str(obj["NodeID"]), NetObjectType="N", NetObjectID=obj["NodeID"])  snmpCpuUri = swis.create("Orion.Pollers", PollerType = "N.Cpu.SNMP.HrProcessorLoad", NetObject="N:" + str(obj["NodeID"]), NetObjectType="N", NetObjectID=obj["NodeID"])  snmpMemoryUri = swis.create("Orion.Pollers", PollerType = "N.Memory.SNMP.NetSnmpReal", NetObject="N:" + str(obj["NodeID"]), NetObjectType="N", NetObjectID=obj["NodeID"])  snmpAssetInventoryUri = swis.create("Orion.Pollers", PollerType = "N.AssetInventory.Snmp.Generic", NetObject="N:" + str(obj["NodeID"]), NetObjectType="N", NetObjectID=obj["NodeID"])  snmpResponseTimeUri = swis.create("Orion.Pollers", PollerType = "N.ResponseTime.SNMP.Native", NetObject="N:" + str(obj["NodeID"]), NetObjectType="N", NetObjectID=obj["NodeID"])  snmpStatusUri = swis.create("Orion.Pollers", PollerType = "N.Status.SNMP.Native", NetObject="N:" + str(obj["NodeID"]), NetObjectType="N", NetObjectID=obj["NodeID"])  snmpTopologyUri = swis.create("Orion.Pollers", PollerType = "N.Topology_Layer3.SNMP.ipNetToMedia", NetObject="N:" + str(obj["NodeID"]), NetObjectType="N", NetObjectID=obj["NodeID"])

Where can a get a FULL listing of the verbs that are available within the SDK?

$
0
0

Where can a get a FULL listing of the verbs that are available within the SDK?

Python API

$
0
0

Is there an API I can connect to with Python?

I would like to query IPAM with Ansible/Python

Thanks.

Can you add nodes to NPM using Python or another language?

$
0
0

I'm automating provisioning/configuring Linux boxes using Ansible. I just finished automating the SNMP install/config, and I'd like to add steps that would add the linux server as a node to Solarwindws. Is this possbile? Or is SWIS only for queries?

Viewing all 2677 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>