3-5
Software Configuration Guide—Release 15.0(2)SG
OL-23818-01
Chapter 3 Configuring the Switch for the First Time Configuring DHCP-Based Autoconfiguration
filename (if any) and the following files: network-confg, cisconet.cfg, hostname.confg, or hostname.cfg,
where hostname is the current hostname of the switch and router-confg and ciscortr.cfg. The TFTP
server addresses used include the specified TFTP server address (if any) and the broadcast address
(255.255.255.255).
For the switch to successfully download a configuration file, the TFTP server must contain one or more
configuration files in its base directory. The files can include the following:
The configuration file named in the DHCP reply (the actual switch configuration file).
The network-confg or the cisconet.cfg file (known as the default configuration files).
The router-confg or the ciscortr.cfg file. (These files contain commands common to all switches.
Normally, if the DHCP and TFTP servers are properly configured, these files are not accessed.)
If you specify the TFTP server name in the DHCP server-lease database, you must also configure the
TFTP server name-to-IP-address mapping in the DNS-server database.
If the TFTP server you plan to use is on a different LAN from the switch, or if you plan to access it with
the switch through the broadcast address (which occurs if the DHCP server response does not contain
all the required information described earlier), you must configure a relay to forward the TFTP packets
to the TFTP server. For more information, see the “Configuring the Relay Device” section on page 3-5.
The preferred solution is to configure either the DHCP server or the DHCP server feature running on
your switch with all the required information.
Configuring the DNS Server
The DHCP server, or the DHCP server feature running on your switch, uses the DNS server to resolve
the TFTP server name to an IP address. You must configure the TFTP server name-to-IP address map
on the DNS server. The TFTP server contains the configuration files for the switch.
You can configure the IP addresses of the DNS servers in the lease database of the DHCP server where
the DHCP replies retrieve them. You can enter up to two DNS server IP addresses in the lease database.
The DNS server can be on the same or on a different LAN as the switch. If it is on a different LAN, the
switch must be able to access it through a router.
Configuring the Relay Device
You must configure a relay device to forward received broadcast packets to the destination host
whenever a switch sends broadcast packets to which a host on a different LAN must respond. Examples
of such broadcast packets are DHCP, DNS, and in some cases, TFTP packets.
If the relay device is a Cisco router, enable IP routing (ip routing global configuration command) and
configure helper addresses (ip helper-address interface configuration command). For example, in
Figure 3-2, configure the router interfaces as follows:
On interface 10.0.0.2:
router(config-if)# ip helper-address 20.0.0.2
router(config-if)# ip helper-address 20.0.0.3
router(config-if)# ip helper-address 20.0.0.4
On interface 20.0.0.1:
router(config-if)# ip helper-address 10.0.0.1