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.

Bulk Importing Routers and Switches and ONLY Selected Interfaces

We are preparing a new installation of NPM- we have about 500 routers/switches that we need to import. we don't need to monitor every Interface but only selected Interfaces on each decice. Is there a way to bulk import the devices and only the selected interfaces? Network Discovery is an all or nothing propsition as far as importing Interfaces after the discovery completes and we don't need every Initerrrface from every device.

Going thru each device individually and selecting the correct Resources after the import is not practical. I have a CSV with the IP and Interfaces we need montiored available.

Has anybody else tried to do something like this?

  • Hey Mike,

    I could be remiss, but I'm pretty sure that there isn't a way to selectively import nodes and interfaces like you've described into NPM. The link below has a somewhat related situation for someone who wanted to add just one interface to an existing set of 1,100 routers, so you might be able to apply it. I do know that when you add a node, you have the ability to do a select-all/select-none at the top, so perhaps you could add them without any interfaces and then later return and add just the ones you wanted.

    http://thwack.solarwinds.com/message/130643#130643

    I'll leave the final word to a PM or other user who has been in this situation, but that's what I have :/.

    --Chris

  • FormerMember
    0 FormerMember

    Mike,

         We just went through the process of importing around 3000 devices. What worked for us was to add the devices in manageable batches of similar device types using Network Discovery. We would add ALL interfaces found on these devices (Up, Down, and Administratively Down) then query the Interfaces table in SQL for the InterfaceID's that did not match our criteria. For example:

    SELECT interfaceid

    FROM Interfaces i

    INNER JOIN Nodes n

    ON i.NodeID = n.NodeID

    WHERE n.DataCenter is Null   --Nodes I have just added do not yet have a DataCenter (Custom Property) assigned

    And i.InterfaceName not in (

    'GigabitEthernet0/46',              -- These are the interfaces I want to KEEP

    'GigabitEthernet0/47',

    'GigabitEthernet0/48',

    'GigabitEthernet0/22',

    'GigabitEthernet0/23',

    'GigabitEthernet0/24',

    'FastEthernet0/22',

    'FastEthernet0/23',

    'FastEthernet0/24'

    )

    AND i.FullName not like '%cross%'     -- Also KEEPany interfaces with "cross" or "uplink" in the description

    AND i.FullName not like '%uplink%'

    This will return a list of the InterfaceID's that you will be REMOVING. You can then format that list into a list of SQL EXEC commands to call the Stored Procedure swsp_DeleteInterface - example:

    EXEC swsp_DeleteInterface '1234'

    EXEC swsp_DeleteInterface '1235'

    EXEC swsp_DeleteInterface '1236'

    From what I can tell, swsp_DeleteInterface is what happens behind the scenes when you check the box of an interface on the web page and click the Delete button. It worked quite well for us - although almost certainly not a method endorsed or supported by SolarWinds...

    Good luck!

    Chris

  • I like this method and will be adopting it myself. It's great for datacenters and environments because it will already have the interface setup in monitoring so you don't have to keep running discovery jobs.

    I did take this a step further though. I found that even though an interface is shutdown it is still polled on the same interval and data is logged as well. Therefore it keeps a load on your polling engines and increases your database size. To address this I'm doing 2 things.

    Item 1. Change the polling cycle on admin down interfaces to reduce the poller load. This means it will take longer to determine an interface is up and start collecting data, but generally the server is still being built at this point. This requires 2 steps.

    Step 1. First we need to increasing the polling time on shutdown interfaces. To do this I'm querying the "Interface" table for all records with "AdminStatus=4" and the "PollInterval" is set to the default value (found in the "Settings" table in the "SettingID" Field look for the entry: SWNetPerfMon-Settings-Default Interface Stat Poll Interval). Then change the polling interval to something higher and unique so you can find it later such as 3601 (hour and 1 second).

    Step 2. Second we need to restore the default polling time for any up interfaces. To do this you query the "Interface" table to all records with "AdminStatus=1" and the "PollInterval" is set to the unique value determined in step 1, in this case 3601. Then change to the default value in the settings table.

    Item 2. Clean up the blank data in the tables.You need to cross reference all shutdown interfaces into the data tables so you can delete the data.

    Where InterfaceID = (From list from Interfaces table)

    & Where In_Discards = 0 (then ensures you only delete an empty record and not historical information)

    dbo.InterfaceTraffic_Daily

    dbo.InterfaceTraffic_Detail

    dbo.InterfaceTraffic_Hourly

    Where InterfaceID = (From list from Interfaces table)

    & Where In_Averagebgp = 0 (then ensures you only delete an empty record and not historical information)

    dbo.InterfaceErrors_Daily

    dbo.InterfaceErrors_Detail

    dbo.InterfaceErrors_Hourly

    It's not pretty, but it's quite easy and can help you scale your instance a little higher.

    -Ben