This discussion has been locked. The information referenced herein may be inaccurate due to age, software updates, or external references.
You can no longer post new replies to this discussion. If you have a similar question you can start a new discussion in this forum.

Schedule Orion Discovery through API

Hello all!

I am trying to setup a lambda function to automatically add nodes to Solarwinds and discover volumes and devices using the discovery tool. Now I can do this with SNMPv2 no problem, but I run into an issue with WMI for our Windows nodes as when they're created they are not yet on the domain and can't authenticate correctly using the discovery tool.

Is there a way through the API to schedule a discovery to take place so as to delay the process to allow our node to build, join the domain, and reboot? 

I am currently using this for all of the nodes that get added

swis.invoke('Orion.Discovery''StartDiscovery'discoveryProfile)
I was wondeering if there's a way to instead of 'StartDiscovery' do a 'ScheduleDiscovery' after half an hour or an hour.
Thanks!
Parents
  • It is not possible to create/update a discovery schedule using the API. It is possible to update the DiscoveryProfiles table directly in the database. 

    There are 2 types of scheduled discovery.

    1. The Basic schedule, Hourly or Daily. These get a default value in the CronSchedule Field.

    <?xml version="1.0"?>

    <ReportSchedule xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xsi:nil="true" />

    1. The Advanced – These will have a more comprehensive structure in the CronScheudle Field.

    <?xml version="1.0"?>

    <ReportSchedule xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

      <FrequencyId>0</FrequencyId>

      <StartTime>2021-05-20T09:27:00Z</StartTime>

      <EndTime xsi:nil="true" />

      <DisplayName>Test</DisplayName>

      <CronExpressionTimeZoneInfoId>GMT Standard Time</CronExpressionTimeZoneInfoId>

    </ReportSchedule>

     

    Scheduled Run Frequency is used for the basic Hourly schedules only and is the number of minutes for the defined interval.

  • This is helpful, but help me understand.

    Does this mean I can create a discovery profile using the API, and then make a call to the database and update that discoveryprofile to run at a scheduled time? Am I understanding that correctly?

Reply Children