399
15.4.2.2.5 default redistribute type
Command: default redistribute type { 1 | 2 }
no default redistribute type
Function: Set the default route type(s) for exterior routes introduction; the “no default
redistribute type” command restores the default setting.
Parameter: 1 and 2 stand for type1 and type2 exterior routes, respectively.
Default: The system assumes to introduce Type2 exterior routes by default.
Command Mode: OSPF protocol configuration mode
Usage Guide: OSPF protocol divides exterior route information into 2 categories by cost
selection method: type1 exterior route and type2 exterior route. The cost of type1 exterior
route = advertised cost of exterior route + cost from a layer3 switch to the advertising
layer3 switch (AS exterior layer3 switch). Cost of type2 exterior route = advertised cost of
exterior route. If both type1 and type2 exterior routes present, type1 routes take
precedence.
Example: Set the default exterior route type for OSPF to introduce to type1.
Switch(Config-Router-Ospf)#default redistribute type 1
15.4.2.2.6 ip ospf authentication
Command: ip ospf authentication { simple <auth_key>| md5 <auth_key> <key_id>}
no ip ospf authentication
Function: Configure authentication method for the interface to accept OSPF packets; the
“no ip ospf authentication” command cancels the authentication.
Parameter: simple stands for simple authentication; md5 for MD5 encrypted
authentication; <auth_key> for authentication key, which should be a string with no blank
characters, up to 8 bytes in simple authentication and 16 bytes in MD5 authentication are
allowed; <key_id> is the checksum word for MD5 authentication, range from 1 to 255.
Default: Authentication is not required by default for the interface to accept OSPF
packets.
Command mode: Interface Mode
Usage Guide: The value of key will be written into the OSPF packets to ensure proper
OSPF packet sending/receiving between the layer3 switch and neighbor layer3 switches.
The partner end must have the same “key” parameters set.
Example: Configure MD5 authentication for OSPF interface vlan1 with an authentication
password of “123abc”.
Switch(Config-If-Vlan1)#ip ospf authentication md5 123abc 1
15.4.2.2.7 ip ospf cost
Command: ip ospf cost <cost>
no ip ospf cost