Assigning IP Address and Domain Name Server
This chapter describes how to create the initial router configuration (for example, assigning the IP address and default gateway information) for the Cisco 910 Industrial Routers ( hereafter referred to as the router) by using a variety of automatic and manual methods.
This chapter consists of these sections:
■
Understanding the Boot Process
■
Assigning Router Information
■
Checking and Saving the Running Configuration
■
Reload of the Software Image
Information in this chapter about configuring IP addresses and DHCP is specific to IP Version 4 (IPv4). If you plan to enable IP Version 6 (IPv6) forwarding on your router, see Configuring IPv6 for information specific to IPv6 address format and configuration.
Understanding the Boot Process
To start your router, you need to follow the procedures in the Quick Start Guide or the hardware installation guide for installing and powering on the router and for setting up the initial router configuration (IP address, subnet mask, secret and Telnet passwords, and so forth).
The normal boot process involves the operation of the boot loader software, which performs these activities:
■
Performs low-level CPU initialization. It initializes the CPU registers, which control where physical memory is mapped, its quantity, its speed, and so forth.
■
Performs power-on self-test (POST) for the CPU subsystem. It tests the CPU DRAM and the portion of the flash device that makes up the flash file system.
■
Initializes the compact flash file system on the system board.
■
Loads a default operating system software image into memory and boots up the router.
The boot loader provides access to the flash file system before the operating system is loaded. Normally, the boot loader is used only to load, uncompress, and launch the operating system. After the boot loader gives the operating system control of the CPU, the boot loader is not active until the next system reset or power-on.
Before you can assign router information, make sure you have connected a PC or terminal to the console port, and configured the PC or terminal-emulation software baud rate and character format to match these of the router console port:
■
Baud rate default is 115200.
■
Data bits default is 8.
Note: If the data bits option is set to 8, set the parity option to none.
■
Stop bits default is 1.
■
Parity settings default is none.
Assigning Router Information
You can assign IP information through a DHCP server or manually.
Use a DHCP server for centralized control and automatic assignment of IP information after the server is configured.
These sections contain this configuration information:
■
Understanding DHCP
■
Manually Assigning IP Information
Understanding DHCP
DHCP provides configuration information to Internet hosts and internetworking devices. This protocol consists of two components: one for delivering configuration parameters from a DHCP server to a device and a mechanism for allocating network addresses to devices. DHCP is built on a client-server model, in which designated DHCP servers allocate network addresses and deliver configuration parameters to dynamically configured devices.
DHCP client support is enabled on a per interface basis on the router for automatic IPv4 address assignment.
The DHCP server, which supplies the IP addresses to the router interfaces, does not need to be on the same subnet as the router. However, when the DHCP server and the router are on different subnets, DHCP relay must be active in the network. Generally, DHCP relay is configured on a router in the path between the router and the DHCP server.
Enabling DHCP on Interfaces
To assign IP address by negotiation via DHCP, use the ip address dhcp privileged EXEC command.
Beginning in privileged EXEC mode, follow these steps to enable DHCP on interfaces:
|
|
|
1. |
configure terminal |
Enter global configuration mode. |
2. |
interface interface_type interface_number |
Enter interface configuration mode. |
3. |
ip address dhcp |
Enable DHCP client on the interface to allow automatic assignment of IP addresses to the specified interface. |
4. |
exit |
Return to global configuration mode. |
5. |
show interfaces interface_type interface_number |
Verify the configuration. |
6. |
copy running-config startup-config |
(Optional) Save your entries in the configuration file. |
DNS Client
When your network devices require connectivity with devices in networks for which you do not control the name assignment, you can assign device names that uniquely identify your devices within the entire internetwork using the domain name server (DNS). DNS uses a hierarchical scheme for establishing host names for network nodes, which allows local control of the segments of the network through a client-server scheme. The DNS system can locate a network device by translating the hostname of the device into its associated IP address.
On the Internet, a domain is a portion of the naming hierarchy tree that refers to general groupings of networks based on the organization type or geography. Domain names are pieced together with periods (.) as the delimiting characters. For example, Cisco is a commercial organization that the Internet identifies by a com domain, so its domain name is cisco.com. A specific hostname in this domain, the File Transfer Protocol (FTP) system, for example, is identified as ftp.cisco.com.
Name Servers
Name servers keep track of domain names and know the parts of the domain tree for which they have complete information. A name server might also store information about other parts of the domain tree. To map domain names to IP addresses on the router, you must identify the hostnames, specify a name server, and enable the DNS service.
You can configure the router to use one or more domain name servers to find an IP address for a host name.
DNS Operation
A name server handles client-issued queries to the DNS server for locally defined hosts within a particular zone as follows:
An authoritative name server responds to DNS user queries for a domain name that is under its zone of authority by using the permanent and cached entries in its own host table. When the query is for a domain name that is under its zone of authority but for which it does not have any configuration information, the authoritative name server replies that no such information exists.
A name server that is not configured as the authoritative name server responds to DNS user queries by using information that it has cached from previously received query responses.
Manually Assigning IP Information
Beginning in privileged EXEC mode, follow these steps to manually assign IP information to multiple interfaces:
|
|
|
1. |
configure terminal |
Enter global configuration mode. |
2. |
interface vlan vlan-id |
Enter interface configuration mode, and enter the VLAN to which the IP information is assigned. The VLAN range is 1 to 4094. |
3. |
ip address ip-address subnet-mask |
Enter the IP address and subnet mask. |
4. |
exit |
Return to global configuration mode. |
5. |
show interfaces vlan vlan-id |
Verify the configured IP address. |
6. |
copy running-config startup-config |
(Optional) Save your entries in the configuration file. |
To remove the router IP address, use the no ip address interface configuration command. If you are removing the address through a Telnet session, your connection to the router will be lost.
For information on setting the router system name, protecting access to privileged EXEC commands, and setting time and calendar services, see Administering the Router
Checking and Saving the Running Configuration
You can check the configuration settings that you entered or changes that you made by entering this privileged EXEC command:
Router# show running-config
To store the configuration or changes you have made to your startup configuration in flash memory, enter this privileged EXEC command:
Router# copy running-config startup-config
This command saves the configuration settings that you made. If you fail to do this, your configuration will be lost the next time you reload the system. To display information stored in the NVRAM section of flash memory, use the show startup-config privileged EXEC command.
Reload of the Software Image
The reload command halts the system. If the system is not set to manually boot up, it reboots itself. Use the reload command after you save the router configuration information to the startup configuration (copy running-config startup-config).
If your router is configured for manual booting, do not reload it from a virtual terminal. This restriction prevents the router from entering the boot loader mode and thereby taking it from the remote user’s control.
If you modify your configuration file, the router prompts you to save the configuration before reloading. During the save operation, the system requests whether you want to proceed with the save if the CONFIG_FILE environment variable points to a startup configuration file that no longer exists. If you proceed in this situation, the system enters setup mode upon reload.