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.

IPAM: How to clear old Scan Jobs. How to know if scans are running or encounter errors?

I wanted to run this by here before trying to call support just in case it's something obvious.  I feel as if some parts of IPAM are not working (or maybe just a few DHCP/DNS servers and not all)....

Background:
We are on IPAM 4.1 and ran into issues where servers were assigned static IP addresses (for a long time), but IPAM shows them as available.  We also have some DNS servers that we've set to scan...but they won't scan (testing the account shows we have zones and the account works...but then nothing seems to happen when we hit "scan")...in short: IPAM is behaving as if it's not working properly.

- When I go to "IPAM Settings" -> "View Scan Job Status" I see 15 pages of scans in a "queued" state.  (some are set to "next scan ASAP")...some have "Last Discovery" time as today/yesterday, but hundreds of them are set to last year.

- In IPAM "Manage SUbnets and IP Addresses", if I pick a folder (like "Discovered Subnets") a majority of my subnets on the right pane have "Last Discovery" as some time last year.

- I believe everything is set to scan every 4 hours.  I didn't set this system up though (inherited it) so I'm not sure if someone made some low level config change (like manually turning everyhting off at a low level) or turned off a master flag somewhere.

- There are event entries under the "IPAM Summary" that indicate (some...all?) things are working ("xyz fields changed for DHCP client name zzz, etc. Status set to reserved")

Questions:

- Is there a way to clear all the "old" scan jobs?  The only button I have next to each is "edit"...Are these actually queued (as mentioned above) or just junk or something has hung causing things to just queue up?  Some way to force a "full scan on everything"?

- Is there a way to tell if the scans are working properly or at all?  Any logs or places to go to tell if something is even attmepting to do any work?  I've searched for logs in several IPAM folders on the filesystem and all I see are empty logs.  I've run queries against the IPAM areas of the orion/NPM database and I got nothing useful.

If there is a way to "clear" out the job queues, then hit "scan" on something and go to a log/localtion/something and see "scan starting for xyz", and then see "scan completed for xyz"...etc...errors/success that would be enough.

Thanks in advance!

  • I just performed a server OS patch and deleted some old SolarWinds products, which caused all services to be re-installed, and then I rebooted the sever. . Like magic the scans all started running again.  Still looking for a way to monitor/detect this...heading over the the APM template area..if not I may find a way to make one (using SQL/SWIS query or something) and upload it.

    Edit: I found this IPAM_Delayed_Scan_Job.png by bluefunelemental and I "simplified" it for my usage and made it into a Orion web based report that gets sent to me daily instead of installing the SWIS API and making a template, etc. which seemed like overkill for now.

    The query I am using is:

    SELECT DISTINCT s.subnet.friendlyname as [SubnetName], queuetimestamp as [LastScan], tostring(HourDiff(queuetimestamp, getdate())) as [DelayedHours] FROM IPAM.ScanInstance s WHERE HourDiff(queuetimestamp, getdate()) > 4 ORDER BY [DelayedHours] DESC

  • Hi tigger2,

    Is your original issue resolved? Sorry, it's not clear to me from your self-reply if you are satisfied with what you found.

    Thanks,

    Jiri

  • Summary: Yes

    Scan monitoring: It's close enough for me to call it "resolved" in that I have some way to monitor for it, even if it's just once a day.  I didn't want to try build a more advanced solution using a SAM template (or something) as I'm hoping that someone else (hopefully SolarWinds support) will offer do a more thorough monitoring that's built in or a SAM template for IPAM than just this single query I found on this site emoticons_happy.png.  If one never appears and I have free time I may build and upload one to the community....someday.

    Scan job cleanup: There doesn't appear to be a "clean/obvious/supported" way of clearing out old scan jobs  and I'm not going to go into the database and futz around with it for something like this without a support ticket.  I'm guessing this isn't needed anyway as once we booted the system it just started working again, so I guess this would be filed more under "enhancement request" than a problem to fix, but it's not an enhancement I'm really wanting to propose unless I keep having issues with this specific thing.

  • Awesome emoticons_happy.png, thanks!  I haven't upgraded yet to use the web console for alerting, but I'm going to get there very soon.

  • I downloaded and edited the report, change the database name to match ours.  However, when I clicked next, I got an error message that reads

    Condition is not valid. Please fix reported errors to continue.

    I then copied and pasted the query on SQL studio and then tried again.  This time, I got a more descriptive error message:

    Msg 156, Level 15, State 1, Line 1

    Incorrect syntax near the keyword 'INNER'.

    Msg 102, Level 15, State 1, Line 9

    Incorrect syntax near 'c'.

    By the way, I am running NPM v12.0.1 with IPAM v4.3.2.  So, I suspect that this report cannot run in the current IPAM version.  Anyway, does any of you have a clue as to why this query fails?  Thanks in advance.  emoticons_cool.png