Configuring A Default Gateway - Cisco Catalyst 2000 Configuration Handbook

Catalyst series lan switching
Table of Contents

Advertisement

28 Cisco LAN Switching Configuration Handbook
b. (Not recommended) Automatically obtain an IP address.
Note Service configuration loads a complete configuration for the switch automatically.
It is referred to as autoinstall in the router community. Autoconfig also requires that a con-
figuration file be available on a TFTP server for a full configuration. For more details
on autoconfig, consult the Cisco website at http://www.tinyurl.com/akvdx8.

Configuring a Default Gateway

To access the switch from IP subnets other than the subnet in the management address,
you need to configure a default gateway. This provides the switch with the minimum
information that it needs to provide remote connectivity.
(Optional; recommended) Configure the default gateway:
1.
(global) ip default-gateway gatewayaddress
The gateway address is the IP address of the Layer 3 interface that acts as a router for
traffic generated by the switch. To view your default gateways, use the show ip route
default command.
Setting Up DNS Services or Host Tables
Each Catalyst switch can resolve common names, such as URLs or fully qualified domain
names, into IP addresses if the proper IP service is configured. This service is a Domain
Name System (DNS) server or a local host table. By default, DNS services are enabled on
Catalyst switches, but the server is not specified. To configure the switch for DNS opera-
tion, use the following guidelines.
(Optional) Enable the DNS service on the switch:
1.
(global) ip domain-lookup
This command enables the switch to use DNS for name lookups. The default is for ip
domain-lookup to be enabled.
You can have the switch request an address from a service, such as RARP,
BOOTP, or DHCP. This is not recommended because it is conceivable that the
address could change for DHCP unless the lease is permanent or static (meaning
that the lease never expires or a specific IP address is reserved for the switch
MAC). This also means that a change of hardware could create a problem with
BOOTP and the static DHCP address.
For Layer 2 switches, you can obtain an address via DHCP/BOOTP if you have
configured the device for autoconfig. The command service config enables auto-
config. If automatic configuration is enabled, the switch ignores any manual IP
configuration parameters:
(global) service config
(privileged exec)reload

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents