5.2 ADDITIONAL DISCOVERY METHODSYou may be interested additional discovery techniques for a couple of reasons: Perhaps your network has limited SNMP devices, or maybe you missed a few devices in your seed file, or new devices have been added to the network that you would like to include in your management domain. Here are two additional ways to discover devices: you can use loadhosts, which is similar to using a seed file in that you must create an input file. You can also add devices via the NNM GUI, which can be labor-intensive if you plan to add more than a few devices. Neither of these two methods requires restarting background processes, which is required when using a seed file. 5.2.1 Discovery using loadhostsAfter the network has been discovered, you can use the loadhosts command to add additional devices to the NNM database. Although the use of a seed file accomplishes the same end result, loadhosts is useful in the following situations:
If you have a list of devices with an arp cache and the SNMP community names are public (or you know the community names), either a seed file or loadhosts will work for you. If the devices don't have an arp cache or the community names are unknown, you will need to build a list of all devices (not just the ones that would be listed in the seed file) that you would like NNM to discover.The input file for loadhosts is an ASCII file in the format of the /etc/hosts file. To use the loadhosts command, issue the following commands:
Each system in the file will be discovered by NNM and placed into NNM's databases and displayed on a submap and in Dynamic Views. NNM will perform the status and configuration queries on the device.A sample loadhosts file is available for download from the server http://www.phptr.com/title/0130352098for both UNIX and Windows systems. Obtain the Readme file this chapter for a description of the files available and install procedures. 5.2.2 Discovery via the NNM GUIManual discovery of network devices can be done from within the NNM GUI by adding devices to the appropriate submap. Why might you want to manually add a device instead of discovering it with a seed file or using loadhosts ? You might be doing third-party monitoring and need to add a critical device that does not reside on any of the currently discovered networks and was not previously added in the seed file. The distinct advantage that the seed file provides is that you can put hundreds of entries in it and netmon will take care of the discovery of these devices. It may take hours to add hundreds of devices manually. The seed file requires stopping the background processes; manually adding devices does not. You probably wouldn't want to use the GUI to manually discover more than a couple of devices. Although, if you are adding a device such as a router, you may find that a great many more devices (located "behind" the router) are discovered. The seed file is also reproducible. If you ever need to delete the database, the seed file automates the discovery of specific nodes. If you've added nodes manually, you will either want to create a seed file or re-add them after network re-discovery.To manually add a gateway or router, select from the Internet submap Edit Figure 5-1. To add a router or gateway, select the Symbol Class Connector and drag the Symbol Subclass Gateway to the IP Internet submap.[View full size image] ![]() Figure 5-2. To populate the router information, select the IP Map attribute and click the[Set Object Attributes…] button.![]() Figure 5-3. Set the IP address and Subnet Mask fields of the device and click[Verfiy] . At this point, NNM will send a series of SNMPGETs to the specified device. If the device responds, the remaining fields (Selection Name, Label, and Physical address) will be populated.Chapter 6, "Customizing NNM from the GUI." |