Site/SunNet/Domain Manager Administration Guide
  Search only this book
Download this book in PDF

IP Discover

22

This chapter discusses the following topics:
  • Invoking IP Discover
  • IP Discover tool configuration
  • snm_discover command
  • The discover.conf file
The IP Discover Tool has two functions:
  • A discover function, which finds hosts, routers, networks, and Simple Network Management Protocol (SNMP) devices reachable from the Console machine. On finding a network element, the discover function stores a record for that element in the runtime database.
  • A monitor function, in which the tool compares the elements stored in the runtime database with the elements it finds at a specified interval or specified time. If new elements are detected, the monitor function stores the elements in a holding-area view and records these elements in a log file. Through the same log file, the monitor function can also notify you if a previously discovered host is down or was down within a given period.

    When you invoke the HeadStart option at startup, IP Discover searches for a maximum of ten elements on the local subnetwork.

    The hosts found by the monitor function are hosts added to a network since the last running of the discover function and hosts that the discover function did not find.

IP Discover offers a number of configuration options for both the discover and monitor functions. These options allow you to fine-tune the extent and depth of the tool's search and monitoring activities. The configuration options are described later in this chapter.

Note - When IP Discover locates SNMP devices, it cannot determine whether these devices support functionality specific to SNMPv2.

22.1 Invoking IP Discover

You invoke IP Discover using one of the following methods:
  • from the Console window, when you press MENU on Tools >> Discover >> IP Discover and release MENU;
  • from the SunOS command line, if you have the path to the SNM executables in your PATH variable, invoke snm_discover; for example, to run IP Discover and invoke the user interface, enter:

  hostname# snm_discover -T  

The path to snm_discover is:
  • /usr/snm/bin on SunOS 4.x
  • /opt/SUNWconn/snm/bin on Solaris 2.x
After IP Discover is invoked from the Console window or from the command line using the -T option, the window shown in Figure 22-1 is displayed. (You can start IP Discover directly, bypassing this window, if you use the snm_discover command without the -T option.)

Graphic

Figure 22-1

The buttons in the IP Discover base window are described as follows:
Start/Stop Discover This button is a toggle. When IP Discover is first invoked, Start Discover is displayed. If Start Discover is selected, the Discover function is invoked in a mode that is determined by the parameters for IP Discover in the IP Discover Configuration window (see Section 22.2, "Discover Tool Configuration"). This mode of the discover function can be limited or as extended as your time and machine resources allow. Once Start Discover is selected, the button display changes to read "Stop Discover". Selecting Stop Discover will cause discovery operations to cease.
Start/Stop Monitor A toggle for which the initial display is Start Monitor. This button invokes the monitor function, using the parameter values as they are set in the Monitor Properties window, described Section 22.2.3, "Monitor Function Configuration."
Configuration Options Invokes the IP Discover Configuration window, in which you can switch between discover and monitor function properties. These properties are discussed in the following subsections.
Once IP Discover is started, IP Discover searches for network devices in a two-stage process:
  • IP Discover first builds a hierarchical linked-list structure that mirrors the network topology that it uncovers. For each Class A, B, or C network that is discovered, an entry is added to the list. Each of these entries contains a list of subnetworks (or a list of hosts directly connected to this network if the network is non-subnetted) and a list of connected networks.
  • Once the network structure has been uncovered, IP Discover then issues Internet Control Message Procotol (ICMP) echo requests to find hosts on each of the subnetworks in the linked-list structure. By default, IP Discover pings each host address in the range 0 to 2048 on each subnetwork. (The command-line version of IP Discover has a -r option that can be used to pass IP Discover a different range of host addresses to ping. This is discussed in Section 22.4.2, "Discovery on Non-Subnetted Class B Networks.")
To build the hierarchical network topology structure, IP Discover proceeds through the following steps:
  • The local routing table is accessed to find the location of the subnetwork's default router.
  • The router's routing table is then retrieved using SNMP.
  • Routing tables are then retrieved from all next hop gateways.
  • IP Discover then leapfrogs from gateway to gateway as it retrieves the routing table from each "next hop" gateway.
  • IP Discover performs a traceroutes operation to determine the number of hops to each "next hop" gateway. Each router that a packet must traverse to reach that gateway counts as an additional "hop." The traceroutes operations may also reveal gateways that were not uncovered by previous queries.
  • IP Discover continues to retrieve routing tables of "next hop" gateways until the "Maximum Hops" count set in the IP Discover Properties sheet is reached. By default, "Maximum Hops" is set to zero and the discovery process is limited to the local subnetwork.
  • SNMP is used to obtain the routing tables of any additional gateways that were uncovered by tracing the route to gateways previously uncovered.

22.2 Discover Tool Configuration

When you click SELECT on the Configuration Options button in the Discover Tool base window, you receive the Discover Configuration window as shown in Figure 22-2.

Graphic

Figure 22-2

To view the two categories of properties, Discover and Monitor:
  1. Press MENU over the Category button.

  2. Release MENU over the category of your choice.

The parameters for these categories are discussed in the following subsections. When either Discover or Monitor is active, you must stop the function before changing any properties.

22.2.1 IP Discover Function Configuration

The parameters in the IP Discover Properties window are described as follows:
Net Name/Number The name or subnetwork number--as specified in an NIS map, an NIS+ table, or the /etc/networks file--that identifies the subnetwork that will be the starting point for the discover function. By default, the discover uses the network number used by the local machine. When specifying a network number, be sure to enter a value for each byte within the number. For example, specify 129.144.41.0, not 129.144.41.
If you enter a network name or number outside of the local subnetwork, the discover function limits its search to the subnetwork you specify.
Netmask The network mask--as specified in an NIS map, an NIS+ table, or the /etc/netmasks file--used in the network(s) on which the discover function is to operate. By default, the discover function uses the netmask number used on the local subnetwork. Enter the netmask number in hexadecimal (preceded by 0x) or dotted decimal notation (for example, 255.255.255.0).
To limit the number of elements found, IP Discover uses the inverse of the host portion of the subnet mask. For example, a netmask of 0xffffff00 has a host portion of 0x00, which becomes 0xff or decimal 255.
The netmask parameter has two uses: one is for when you want discovery to begin in a subnetwork other than the local subnetwork. The discover function needs to know the netmask used on that subnetwork. The second use is as a limit to the number of hosts the discover function will add to the runtime database. The discover function will ping a maximum of 2048 network elements per subnetwork.
Maximum Hops A measure of how far the discover function will extend its search. For a given route from the machine running the IP Discover Tool (or from the subnetwork specified in the Net Name/Number parameter), this parameter is the maximum number of routers the ICMP packets sent by the discover function will traverse. The default for this parameter is zero hops, which
means searches are restricted to the local subnetwork. By setting Maximum Hops to 1 or greater, IP Discover will extend its search to additional subnets connected to the local subnetwork's router.

Note - If there are multiple routers attached to the local subnetwork, the number of subnets searched may increase exponentially if Maximum Hops is set higher than zero. Depending on the size of your network, setting Maximum Hops to any value above zero can result in very long searches.

ICMP Retries The discover function uses the Internet Control Message Protocol (ICMP) to find network elements that are not SNMP devices. This parameter determines the number of times the tool will retry "finding" an element using ICMP following an initial non-response. If your network is very busy, you might want to increase this value.
ICMP Timeout Determines how long (in seconds) the discover function waits after sending an ICMP packet that did not receive a response, before sending another ICMP packet. To speed up the discovery process, reduce this value.
SNMP Community The discover function limits its search for SNMP devices to devices that have the community name(s) you specify here. You can specify up to five SNMP community names. Use a colon to delimit multiple names. Note that using multiple community names makes the discover function take a longer time than it would with a single name. This is because the discover function tries each device with each community name until a response is received.
To make the search faster, you can use the following process: If you are aware of the community strings for specific gateways or hosts, you can enter the information in the snmp.hosts file in the database directory using the format provided in the header of the snmp.hosts file. When you specify the community string for known gateways or hosts in this file, IP Discover only uses the read community string entered for that host. The result is a faster search because the correct string is used rather than requiring the search process to search each string entered in the SNMP community field (or in the -c option in the command line). If the community strings you entered are valid for only specific gateways or hosts, it is very important to use this process in order to avoid a search of each device, using each community name, until a response is received.
SNMP Retries For SNMP devices, the discover function uses SNMP for discovery purposes. This parameter determines the number of times the tool will retry contacting an element using SNMP following an initial response. This parameter comes into play primarily when querying routers. ARP and routing tables are often large and sometimes require multiple retries to obtain complete tables.
SNMP Timeout Determines how long (in seconds) the discover function waits for a response to an SNMP packet before giving up or, for routers, sending another SNMP packet.
Search Method Starting with version 2.3, there are three choices for search methods: Default, ARP and Ping.
Default: the default method is a combination of Address Resolution Protocol (ARP) and Ping. IP Discover first uses the ARP tables of the gateways to update the database topology, therefore allowing you to see nodes on respective segment views. Next, ICMP echo packets are sent to locate potential devices for the missing IP addresses not found in the gateway ARP tables.
ARP: ARP search method uses ARP tables of the gateways and hosts in the network/subnet to update the database topology. An ARP table is a mapping of IP addresses to physical addresses. This search method finds hosts/routers that have recently generated traffic. Frequent discovers are, therefore, recommended.
Ping: The Ping search method sends ICMP echo requests, serially, to all possible addresses. Of the three search methods, this is the most time consuming. Command line options you can use starting with version 2.3 include the following:
-N <num>: the maximum number of outstanding simultaneous pings per interval specified by the -N option. The default is 1.
-F<num>: Fast Ping retries - the number of times IP Discover tries to contact a device. The default value is 1. -F is valid only when -N is greater than 1.
-f<seconds>: Fast Ping timeout - the frequency between transmissions of the batch of ICMP echo requests (in seconds). The default is 3 seconds. -f is valid only when -N is greater than 1.
If you select the -N option, you can set the ICMP response timeout and retry values using the -F and -f options.
Gateway File You can specify the gateways to be used for the query phase. The command line format is -G<gateway_filename>. This is a text file containing the name of the list of gateways, one gateway name per line. In addition, you can specify the ONLY flag as #ONLY with the '#' sign in the first column in the beginning of the gateway file. There is no default gateway file. If a gateway file is not specified, this option is not enabled.
Specifying the ONLY flag will discover the default local subnet and all the networks known to the gateways listed in the gateway file, irrespective of the user-specified hop count.
If you do not specify the ONLY flag, the networks discovered are the local subnet, all the networks known to the listed gateways (even if the hop count does not match), and all the networks within the user specified hop count. Following is sample gateway file

  #ONLY  
  mpk16router  
  mpk17router  

Verbose Mode A yes/no switch for which the default is no. Click SELECT on Yes to have the discover function report detailed progress in the IP Discover Console Output window in the IP Discover base window. A no selection means that the discover function reports only intermittent progress.
We recommend a yes setting for this parameter, particularly for long searches.
Viewname Name of the view to which the discover function will add discovered network elements. If Add To All Views (see below) is set to no, the discover function preserves a separate view hierarchy under this name. If the name you specify here is not in the runtime database, the discover function creates a new view and adds discovered elements to it. The name specified here will be appended to all subviews in this view hierarchy.
The SNM database does not permit duplicate names of views (or other elements). By default, IP Discover uses network and subnetwork names in building the database representation of the network topology. If you want to have different views into the same subnetwork or network -- such as a view of subnetwork A that shows all hosts and a view of subnetwork A that shows only routers -- then the names specified for these views must be distinct. By appending Viewname to the names of the subviews in a view hierarchy, the separateness of the subviews in that view hierarchy is preserved. IP Discover will append Viewname to the names of subviews only if Add To All Views is set to "No."
Add To All Views A yes/no switch for which the default is yes. If you accept the default of Yes, the discover function adds discovered elements to all views in the runtime database, including the view specified in Viewname, if one is present. If you click SELECT on No, the discover function appends the name specified in the Viewname field to all views (that is, elements of category view) within the specified view. For an element that is in multiple, high-level views, this feature allows you to distinguish that element as it exists in different views, such as a router that is in a routers-only view of a subnetwork but also in a view that shows all devices on that subnetwork. Since the SNM database does not allow views (or other elements) with duplicate names, you can only have multiple views into the same
subnetwork if you assign separate names to maintain the uniqueness of each view. The use of this parameter to create separate view hierarchies is illustrated in Section 22.2.2, "Example: Creating a Routers-only View."
Add Object Connections A yes/no switch for which the default is no. Click SELECT on Yes to have the discover function create manageable connections between discovered elements and to add the connection information to the linkmap file. However, the discover function only adds connection information to the linkmap file if Maximum Hops has been set to 2 or more. Refer to the linkmap (5) manual page for information about the format of the linkmap file and its usage. A No selection means that the discover function does not make connections.
Add Object Coordinates A yes/no switch for which the default is yes. By default, the discover function performs minimal layout of elements within a view. For example, in a subview representing an Ethernet subnetwork, glyphs representing hosts are distributed on both sides of the bus glyph. If you select no,
elements are created with no layout of elements taking place. A sample subview created without coordinates is shown in Figure 22-3.

Graphic

Figure 22-3

Default Proxy When the discover function finds an element that has SNM proxy agents, it specifies the host you enter here as the proxy host. If you leave this item blank, the proxy host is specified as localhost.
Objects to Discover By default, the All Objects item is selected. If you click SELECT on the All Objects checkbox to deselect it, the following dimmed items display normally:
snm hosts
Systems running SunNet Manager agents.
SNMP devices
Systems or other devices running SNMP. Note that the discover function cannot discover whether the SNMP device supports the added functionality of SNMPv2.
Routers
Systems that have multiple network interfaces to different IP networks. When the discover function finds a router, it fills in IP addresses for the first two interfaces and uses the alias feature to give a name to each interface (if, indeed, each interface has a unique name), including those beyond the first two. You can then specify any of these aliases when sending a data or event request.
Networks/Subnets
Collections of subnetworks or individual subnetworks. If you select this item, the discover function finds only networks and subnetworks, plus manageable connections and routers if the Add Object Connections item is selected.
Accept the default of All Objects or click SELECT on the checkbox(es) for object(s) of your choice.

22.2.2 Example: Creating a Routers-only View

You might want to use IP Discover to create a separate view hierarchy -- named "Routers" -- that contains only routers in addition to another view hierarchy that contains all objects. To create a routers-only view hierarchy, you would need to make the following entries (as shown in Figure 22-4) in the IP Discover Configuration window:
  • Specify "Routers" in the Viewname field
  • Set Add To All Views to No
  • Select Routers only in the Objects To IP Discover field.

Graphic

Figure 22-4

A glyph named "Routers" will be added to the Home view. If there are multiple subviews under "Routers" that represent subnetworks, the names of these views will have "-Routers" appended to them, as shown in Figure 22-5.

Graphic

Figure 22-5

22.2.3 Monitor Function Configuration

The window for monitor function configuration is the window you receive when you press MENU in the Category button in the IP Discover Configuration window and release MENU over Monitor. The window shown in Figure 22-6 is displayed.

Graphic

Figure 22-6

The parameters in the window above determine the operation of the monitor function only; they have no effect on the discover function. (However, the ICMP and SNMP-related discover parameters do apply to the monitor function.)
By default, the monitor function works silently. Set the Verbose Mode option (described below) to Yes to have the function display messages in the IP Discover Tool Console Output window. Also by default, the monitor function runs daily; you can set it to run weekly instead, by setting the Run Weekly and Day of Week parameters, described below.
To protect the integrity of already-discovered views, the monitor function adds hosts to a "holding area" view you define in the property sheet (see Holding Area Viewname, below).
The monitor parameters in the IP Discover Properties window are described as follows:
Holding Area Viewname The name of the view to which the monitor function adds the hosts it finds.
Non-response Timeout Determines how long (in minutes) the monitor function will continue to try to contact an unresponsive host before marking the host as down in the file specified in the Log Filename item (described below).
Time Between Cycles Within the span specified by Start Time and Stop Time (see below), this parameter determines how long (in minutes) the monitor function will wait between monitor cycles. A monitor cycle is one complete pass of the monitor function through the network elements in a runtime database. A value of 0 means that the monitor function runs continuously until the Stop Time is reached.
ICMP Timeout Determines how long (in seconds) the monitor function waits after sending an ICMP packet before sending another ICMP packet.
Log History An on/off switch the default for which is on. Determines whether the monitor function keeps a record of its operation. You must set this parameter to On to have data sent to a log file and to have to the log file sent to an electronic mail address.
Log Filename Full path name of the file in which the monitor function stores a record of its operation. Note that you must specify a valid path name for this parameter to obtain a record of monitor output.
Mail Logfile To: An electronic mail address to which the monitor function sends a record of its operation upon completion of a cycle. The software performs no error checking on the address you enter.
Ignore-Host File Name Full path name of the file listing names of hosts and views that you want the monitor function to ignore. The requirements for the file are that it be an ASCII file with one hostname or view per line, no blank lines, with host names beginning in column 1. The monitor function does not look inside a view listed in this file.
You might find the ignore-views feature useful if you have object-type-specific views. For example, if you have a router-only view, the monitor function, left unchecked, adds all of the hosts it finds on the routers' subnetworks to this view. If you insert the name of this view in the file you specify for the Ignore-Host File Name, the monitor function will not look inside this view.
Use the ignore-hosts feature if the monitor function frequently finds new or down hosts that are of no interest to you.
Verbose Mode A yes/no switch for which the default is no. Click SELECT on Yes to have the monitor function report progress in the IP Discover Console Output window in the IP Discover base window. A no selection means that the monitor function works silently. A no selection for this parameter does not affect the logging-related parameters.
Start Time A time at or after which the monitor function begins operation within the specified start and stop dates. The initial display is the current time. The start time takes effect for daily or for weekly use of the monitor function.
Stop Time A time at which the monitor function ceases operation within the specified start and stop dates. The stop time takes effect for daily or for weekly use of the monitor function.
Start Date A date on or after which the monitor function begins operation. The initial display is the current date. The start date takes effect for daily or for weekly use of the monitor function.
Stop Date A date on which the monitor function ceases operation. The stop date takes effect for daily or for weekly use of the monitor function.
Run Weekly A yes/no switch for which the default is no. A no selection means that the monitor function works on a daily rather than a weekly basis. When this item is set to no, the following item (Day of Week) is greyed-out. Click SELECT on Yes to have the monitor function run on a weekly rather than a daily basis.
Day of Week If the previous item is set to yes, this item displays normally. The initial selection is the current day of the week. Press MENU in the abbreviated menu button to obtain a day-of-the-week menu and release MENU over the day on which you want to monitor function to run.

22.3 Updating the Management Database

Use IP Discover's Monitor function to schedule periodic searches for new additions to the network or nodes not uncovered previously. Use this tool to also build a hierarchy of views representing your network topology.
Rather than burden the network with frequent IP Discover searches, Monitor might be scheduled to run once a week. To access the Monitor Configuration window do the following:
  1. Press MENU on the Tools button on the Console control panel to pull down the Tools menu.

  2. Select Discover.

  3. Select IP Discover.

  4. When the IP Discover window appears, click SELECT on the Configuration Options button.

  5. Press MENU on the Configuration Category button and select Monitor.

When Monitor discovers new devices, it adds them to a holding area view. In Figure 22-7, this view is named "New_Devices." In this example Monitor is configured to run weekly. You can select the day of the week and the time period in which Monitor will run.
Refer to information on configuring Monitor in the "IP Discover" chapter in "Part 2: Reference."

Graphic

Figure 22-7

22.4 snm_discover Command

You can invoke the IP Discover Tool from the SunOS command line using the snm_discover command. Many of the options that you can use with this command correspond to fields in the IP Discover or Monitor menus of the IP Discover Configuration popup window. If you have installed the Solaris 1.1 version of the current product, you enter:

  hostname% /usr/snm/bin/snm_discover <options>  

If you have installed the current product on a Solaris 2.x machine, you enter:

  hostname% /opt/SUNWconn/snm/bin/snm_discover <options>  

22.4.1 IP Discover Command-Line Options

-A

specifies that the search method is ARP only. Refer to Section 22.2.1, "IP Discover Function Configuration," on page 22-6 for information on the ARP search method.
-c <community> <community> specifies the SNMP community string to use. Equivalent to the "SNMP Community" field in the Configuration window. Refer to Section 22.2.1, "IP Discover Function Configuration," on page 22-6 for information on the SNMP community.
-d <objects> By default, IP Discover searches for all objects. The -d option limits the discovery to types of objects specified in a list. Possible entries: routers, snmp, snm, or network. Entries in the list are separated by colons. Equivalent to the "Objects to Discover" field in the Configuration window.
-F<num>
  Fast Ping retries - the number of times IP Discover tries to contact a device.
  The default value is 1. -F is valid only when -N is greater than 1 and the -P
  option is selected.

-f<seconds> Fast Ping timeout - the frequency between transmissions of the batch of ICMP echo requests (in seconds). The default is 3 seconds. -f is valid only when -N is greater than 1 and the -P option is selected.
-h <hops> <hops> measures how far IP Discover will search. By default this value is 0; in that case, IP Discover limits its search to the local subnet. For a given route to a possible target, <hops> measures the number of routers that will be traversed by packets sent by IP Discover. This is equivalent to the "Maximum Hops" field in the Configuration window.
-G<gateway filename> Use this option to specify the gateway. Refer to Section 22.2.1, "IP Discover Function Configuration," on page 22-6 for information on the gateway filename.
-H

Use this option to display IP Discover command line options.
-l

Manageable connections are created between discovered elements and connection information is added to the linkmap file. Equivalent to the "Add Object Connections" field in the Configuration window.
-m <netmask> <netmask> specifies the netmask used in IP Discover. This can be in hexadecimal or dotted decimal notation. Equivalent to "Netmask" field in Configuration window.
-M
  Starts Monitor.

-N<num> the maximum number of outstanding simultaneous pings per interval specified by the -N option. The default is 1.
-n <network> <network> specifies the name or subnetwork number--as specified in an NIS map, an NIS+ table, or the /etc/networks file--that identifies the subnetwork that will be the starting point for the discover function. By default, the discover uses the network number used by the local machine. Equivalent to the "Net Name/Number" field in the Configuration window.
-o

When a <viewname> is specified with the -V option, and the -o option is also specified, IP Discover adds elements only under the view specified in <viewname>. Subviews created under this view have <viewname> appended. This is equivalent to entering "No" for the "Add to All Views" field in the Configuration window. An example illustrating the use of this option is discussed in Section 22.2.2, "Example: Creating a Routers-only View."
-P
Use this option to specify that the Ping search method should be used. Refer to Refer to Section 22.2.1, "IP Discover Function Configuration," on page 22-6 for information on the Ping search method.
-p <num> <num> specifies the number of times IP Discover will reissue an ICMP echo request to a host address after an initial non-response. Equivalent to "ICMP Retries" field in Configuraion window.
-q

This invokes a quick IP Discover, which limits discovery to a maximum of ten devices on the local subnet.
-r <IPaddress1>:<IPaddress2> By default, IP Discover only pings host addresses in the range 0 to 2048 on each subnet that it finds. The -r option passes a range of IP addresses to use as targets for ICMP echo requests in searching for hosts. The use of this option is discussed in the next section.
-s <seconds> <seconds> specifies the number of seconds to wait for a response to an SNMP packet before sending another SNMP packet. Equivalent to the "SNMP Timeout" field in the Configuration window.
-S <num> The number of SNMP retries when sending requests to routers. Equivalent to the "SNMP Retries" field in the Configuration window.
-t <seconds> Determines how many seconds IP Discover waits before sending another ICMP request after non-response to a prior request. Equivalent to "ICMP Timeout" field in Configuration window.
-T
  Invokes the IP Discover Tool window interface.

-v

Turns on verbose mode. Equivalent to setting "Verbose Mode" field to "Yes" in Configuration window.
-V <viewname> Puts all discovered devices into <viewname>. By default, <viewname> is "Home." Equivalent to the "Viewname" field in the Configuration window.
-x

By default, IP Discover does some minimal layout of elements in views. If this option is used, elements are created without screen coordinates and no layout of elements takes place.

22.4.2 Discovery on Non-Subnetted Class B Networks

When IP Discover attempts to find elements on a network, ICMP echo requests will be sent to a maximum of 2048 host addresses on each subnetwork. By default, these host addresses will be those in the range 0 to 2048. However, non-subnetted Class B networks may have host addresses higher than 2048.
In a Class B IP network address, two octets (16 bits) of the four-octet (32-bit) IP address are available as host addresses. In a subnetted Class B network, a portion (typically one octet) of this 16-bit host address is used for subnet addresses.
On a non-subnetted Class B network, the entire 16-bit host portion of the IP address is available for host addresses, thus allowing host addresses higher than 2048. (Host addresses higher than 2048 can also occur on subnetted Class B networks if 4 or fewer bits of the host portion of the IP address are used for subnet addresses. In general, any subnetted Class A or Class B network that has 12 or more bits available for the host address can have host numbers higher than 2048.)
Although an individual IP Discover session will only ping 2048 devices on each network, the possible range of host addresses is not limited to the default 0-2048. The IP Discover -r option can be used to modify the range of addresses to locate devices with host addresses higher than 2048 on non-subnetted networks. This is done by invoking IP Discover with the -r option at the SunOS command line:

  hostname# <snm_path>/snm_discover -r <IPaddress1>:<IPaddress2>  

By default, <snm_path> is /usr/snm/bin for SunOS 4.x installations or /opt/SUNWconn/snm/bin for Solaris 2.x installations.
Progressively higher blocks of host addresses can be passed to IP Discover in subsequent sessions to exhaustively search the range of possible host addresses on large non-subnetted networks.

22.5 The discover.conf File

The material in this section is for those users who:
  • Want to modify the shape or the color of the glyphs that represent the elements found by the IP Discover Tool;
  • Want to use system descriptions returned by SNMP agents to specify which type of element to create
  • Have created customized views that you want to monitor
  • want to use the IP Discover Tool to find agents in addition to the agents shipped with SNM.
  • Associate agent schemas with components
The discover.conf file is an ASCII file stored in the following directory
  • /var/adm/snm on Solaris 1.x machines
  • /var/opt/SUNWconn/snm on Solaris 2.x machines
The file contains individual sets of configurable fields, each set identified by the following uppercase keywords:
  • OID
  • COLORS
  • COMPONENTS
  • DEFAULTS
  • MAPPINGS
  • MONITOR COMPONENTS
  • AGENTS
  • AGENT SCHEMA MAPPING
In the discover.conf file, each of these keywords must be preceded by a hash mark (#). Except when preceding a keyword, a hash mark indicates a comment.
Within discover.conf, the order of fields is significant.

22.5.1 OID Section

The OID section maps object identifiers (OIDs) to element types. An element type determines the glyph used for a given element. An entry has the form <oid> <element_type>, where <element_type> is in a schema file that has been loaded into the Console. For example:

  #OID  
  #  
  Sun Microsystems.2.1.1  component.ss10  
  HP.2.3.2.5      component.hpsnake  

When a device is reachable through SNMP, the discover function tries to retrieve the OID for that device. If successful, the discover function maps the OID to a specific SNM element type. In the example above, any device returning the OID for Sun (which can be in either the textual form of the example or the numeric 1.3.6.1.4.1.42.2.1.1.1) is created as the SNM element type component.ss10. Using the same example, if the device returns HP.2.3.2.5 the element type is component.hpsnake.

22.5.2 COLORS Section

The COLORS section of discover.conf allows you to create your own color names for the two sections, COMPONENTS and DEFAULTS, that follow COLORS. As shipped with SNM, the COLORS section is as follows:

  #COLORS  
  #  
  RED             255 0 0  
  BLUE            0 0 255  
  ORANGE          255 0 255  
  YELLOW          255 255 75  

See the bottom area of an element's property sheet for slider bars that show values for different colors.

22.5.3 COMPONENTS Section

The COMPONENTS section of discover.conf associates element types with the colors defined in the COLORS section. For example:

  #COMPONENTS  
  #  
  component.ss1           ORANGE  
  component.server        LIGHT_BLUE  
  bus.ethernet            RED  
  view.subnet             BROWN  
  view.network            DARK_GREEN  
  component.link          BLACK  

22.5.4 DEFAULTS Section

The DEFAULTS section of discover.conf allows you to assign a specific color for all SNMP devices. For example:

  #DEFAULTS  
  #  
  snmp_color              GREEN  

With the entry above, glyphs for all SNMP devices will be colored green.

22.5.5 MAPPINGS Section

The MAPPINGS section allows you to map a keyword returned from the SNMP system description to an SNM element type. If a keyword has white space, it must be enclosed in quotes. The IP Discover Tool has the Sun machine types listed in Table 22-1 as defaults.
Table 22-1 Sun Machine Types

  "sparcstation 10"       component.ss10  
  "sparcstation 1"        component.ss1  
  "sparcstation 2"        component.ss2  
  "sparcstation 330"      component.ss330  
  "sparcstation 370"      component.ss370  
  sun386          component.sun386  
  sun3            component.sun3  
  sun4            component.sun3  
  sun470          component.sun3  
  sc2000          component.sc2000  
  sc1000          component.sc2000  
  ipc             component.ipc  
  ipx             component.ipx  
  lx              component.lx  

The mappings in the discover.conf file are consulted before the defaults shown above. For example, if the system description returned by the remote SNMP agent is:

  SNMP agent ibm pc  

...and you have the following entries in your discover.conf file:

  #MAPPINGS  
  "ibm pc"        component.pc  
  bridge  component.bridge  

...the type for the element created by the IP Discover Tool will be component.pc. Note that the keyword can appear anywhere in the system description returned by the SNMP agent. Using the preceding example, if a system description is "better to build a bridge," the IP Discover Tool will create a component of the type component.bridge.

22.5.6 MONITOR COMPONENTS Section

The MONITOR COMPONENTS section enables the monitor function to monitor views of types other than networks and subnets. An entry in this section has the following form:

  <view type>  

...where <view type> identifies the type of view that you want to the monitor function to monitor. The view type and view instance must be successfully loaded in the Console. The view type must have a netmask field; for the view instance, the netmask field must have a non-null value.
The view types shipped with SNM (to see the list, invoke Edit >> Create in the Console's control area, then click SELECT on the View category in the Create Object window) do not qualify for monitoring because they do not have a netmask field.

22.5.7 AGENTS Section

The AGENTS section enables the IP Discover Tool to search for agents in addition to those shipped with SNM. An entry has the following form:

  <RPC number>       <agent_name>   [proxy]  

The entries in this file are described as follows:
<RPC number>
The RPC number of the agent as it is specified in the /etc/services file or a directory service map or table.
<agent_name>
The agent name as it appears in the properties sheet for an element. Note that this is not na.<name>, but simply <name>. <agent_name> must identify an agent that is in a schema file that is loaded in the Console.
proxy If the agent is a proxy agent, use the word proxy to indicate its proxy status.

22.5.8 AGENT SCHEMA MAPPING Section

The agent schema for a specific device is configurable. You can associate specific agent schemas with specific component types listed in this Section. The IP Discover application will automatically activate the agent schemas for all the device types listed in this Section along with the existing defaults. The following format must be used while using this Section:

  #  
  #AGENT SCHEMA MAPPING  
  #  
  <snm element type 1>  
  {  
      <agent schema 1>  
      <agent schema 2>  
        .  
        .  
        .  
      ,agent schema n>  
  }  
  <snm element type 2>  
  {  
  <agent schema 1>  
  <agent schema 2>  
  }  

...where <snm element type> are the component names such as component.ss1, component.ipc specified in the #MAPPINGS Section of this file and <agent schema> are the agent schemas such as cpustat, diskinfo, and so forth.