Discover command

The discover command starts or stops a discovery run.

Command syntax

api.sh|api.bat-u|--useruser-p|--passwordpassword [-H|--hosthost] [-P|--portport] [-T|--truststorefile] discoverstart [--namerun-name] [--profileprofile-name] [--locationTaglocation-tag] [-a|-addressSpaceaddressSpace] scope-element1|scope-set1|scope-group1scope-element2|scope-set2|scope-group2...scope-elementn|scope-setn|scope-groupn
api.sh|api.bat-u|--useruser-p|--passwordpassword [-H|--hosthost] [-P|--portport] [-T|--truststorefile] discoverabort|status

Parameters

discover
Runs the discover command.
start scope-element1 scope-element2 ... scope-elementn
Starts a discovery with the specified scope elements. The scope element can be an existing Scope name, or:
  • Specific IP address: 192.168.1.71
  • Exclude of a specific IP address: 192.168.1.71(exclude), or (192.168.1.71), or 192.168.1.71(exc)
  • Range or Range Exclude: 10.10.10.1-10.10.10.20, or (10.10.10.1-10.10.10.20)
  • Network (Subnet) or Network Exclude: 10.10.20.0/255.255.255.0, or (10.10.20.0/255.255.255.0)
start scope-set1 scope-set2 ... scope-setn
Starts a discovery with the specified scope sets.
start scope-group1 scope-group2 ... scope-groupn
Starts a discovery with the specified scope group.
--name run-name
Is the name of the discovery run.
--profile profile-name
Uses the profile that is specified by profile name for the discovery.
--locationTag location-tag
Specifies location tag that is used for this discovery.
Fix Pack
3 -a | -addressSpace addressSpace
Specifies the address space name for all IpAddress or IpNetwork objects that are created during the discovery started with api.sh or api.bat.
abort|stop
Stops a running discovery on the specified host.
status

Returns the discovery status on the specified host, from among the following values:

  • Running
  • Idle

Examples

  • This command discovers subnet 10.10.10.0/24 using a Level 1 discovery profile. Enter the command on one line:
    api.sh -u user -p password -H host discover start
     --profile “Level 1 Discovery” “10.10.10.0/255.255.255.0”
  • This command discovers the scope set named MyScope using a Level 2 discovery profile. Enter the command on one line:
    api.sh -u user -p password -H host
     discover start --profile "Level 2 Discovery" "MyScope"
  • This command discovers the scope set named MyScope using a Level 3 discovery profile with a 1.2.3.4 host excluded and 2.3.4.5-2.3.4.7 range included. Enter the command on one line:
    api.sh -u user -p password -H host discover start 
    --profile "Level 3 Discovery" "MyScope" "(1.2.3.4)" "2.3.4.5-2.3.4.7"
  • This command discovers the scope set named MyScopeSet using a Level 1 discovery profile. Enter the command on one line:
    api.sh -u user -p password discover start
     --profile “Level 1 Discovery” "MyScopeSet"
  • This command discovers the scope group named MyScopeGroup using a Level 1 discovery profile. Enter the command on one line:
    api.sh -u user -p password discover start
     --profile “Level 1 Discovery” "MyScopeGroup"