|
|
You can use either Network Registrar's graphical user interface (GUI), ntwkreg, or command line interface (CLI), nrcmd, to configure and manage your DNS and DHCP servers. This chapter describes how to use the nrcmd program and provides the following information:
You can use the nrcmd program in batch mode by executing scripts that use the commands, or by using the interactive mode in which you enter commands at the nrcmd program prompt. The nrcmd program is located in \Program Files\Network Registrar\bin on NT and in /opt/nwreg2/usrbin on Solaris.
The command syntax is as follows:
nrcmd general-options command specific-options
The general options are:
-C clustername -N username -P password
These general options are not required. If you supply them, you must precede them with -C, -N, or -P. If you do not supply them, Network Registrar gets them from the registry (on NT), or environment variables (on Solaris and NT). If Network Registrar cannot find values for these parameters, it prompts you for them.
The NT registry and Solaris or NT environment variables are AIC_NAME for the name, AIC_PASSWORD for the password, and AIC_CLUSTER for the cluster name. The NT registry path is Software\American Internet\Registrar\2.0 and the registry hive is HKEY_CURRENT_USER.
To execute the command line interface in interactive mode, type:
nrcmd [-C cluster] [-N user] [-P password]
Typing this command displays the interactive prompt nrcmd> to which you type:
nrcmd> command [optional parameters]
To specify a series of items, use commas between the items. Do not add a space after the comma.
To terminate an interactive session, type exit.
To view the online help, type help.
The nrcmd commands specify a class of object that you can create, delete, or list. Each of these objects in turn has properties that you can set or get, and features that you can enable, disable, or test. These objects can also have methods that are specific to the type of object, and that let you perform operations on groups of properties.
When you use the nrcmd commands to configure Network Registrar, you manipulate the following:
When you use the create command and there are required arguments, you must supply them. You can also supply additional arguments. You must supply the required arguments in the specified order; however, you can specify the optional arguments in any order with the syntax prop=value.
For example, the syntax for creating a scope is scope name create addr mask [prop=value], which means that you must supply an IP address and mask when you create a scope, and you can optionally specify other properties of the scope.
The following example creates the scope testScope with the IP address of 128.103.1.1 and a mask of 255.255.255.0.
nrcmd> scope testScope create 128.103.1.1 255.255.255.0
If you want to create a scope and also specify the name of the DNS zone to which a DHCP client's host name should be added, type:
nrcmd> scope testScope create 128.103.1.1 255.255.255.0 dns-zone-name=QuickExample.com
After the create command creates and assigns all specified parameters to the object, it checks that all the required properties have values (either defaults or user-specified). If you neglect to supply the required arguments, Network Registrar reports an error.
You use the set command to set the value of a property. If you want to set a list of things, such as DNS servers, or IP addresses, you can separate them with commas. You can also use the set command to set several properties on a single line---just specify the property and its value followed by a space and the next property and value pair.
To specify the name of the DNS zone to which a DHCP client's host name should be added, type:
nrcmd> scope testScope set dns-zone-name=QuickExample.com
To specify the list of IP addresses that you will allow to perform zone transfers, type:
nrcmd> zone QuickExample.com set
auth-servers=196.68.1.10,196.68.1.20
To set the client's client-class and domain-name, type:
nrcmd> client 1,6,02:02:02:02:02:02 set
client-class-name=internal
domain-name=QuickExample.com
You use the enable command to enable a feature. After you enable a feature you often need to set its associated properties.
To enable incremental transfer processing for the DNS server, type:
nrcmd> dns enable ixfr-enable
Then to change the incremental transfer expiration interval, type:
nrcmd> dns set ixfr-expire-interval=10d
The CLI saves your changes to the database after one of the following events occurs:
This section contains the complete list of nrcmd commands, grouped alphabetically. You can use them on the command line or insert them into scripts.
| Command | Description |
|---|---|
Creates administrators and assigns them passwords | |
Creates clients and assigns them to client-classes | |
Creates client-classes | |
Creates a custom DHCP option | |
Specifies the DHCP server's properties | |
Specifies the IP address of the DHCP server's hardware card | |
Specifies the DNS server's properties | |
Quits the nrcmd program | |
Writes the state of the lease or a zone to a file | |
Integrates user-written DHCP extensions into the Network Registrar DHCP server | |
Obtains an exclusive lock for the nrcmd program session | |
Provides online help | |
Loads configuration information from a file | |
Specifies the LDAP remote server's properties | |
Specifies DHCP leases' properties | |
Notifies you when you run out of available leases in a scope | |
Views and updates license information | |
Reports IP address utilization | |
Specifies the policy information | |
Specifies information about remote DNS servers | |
Creates a summary of the dynamic and static IP address utilization for one or more clusters | |
Saves the current configuration changes | |
Specifies the scopes' properties | |
Creates scope selection tags | |
Affects server behavior | |
Configures session parameters | |
Specifies the DNS zones' properties |
![]()
![]()
![]()
![]()
![]()
![]()
![]()
Posted: Thu Jul 13 11:32:44 PDT 2000
Copyright 1989-2000©Cisco Systems Inc.