version 2
Enables RIPv2 on the router, which supports classless routing, VLSM, and authentication, replacing the older RIPv1.
Definition: version 2 is a Cisco IOS router config command. Enables RIPv2 on the router, which supports classless routing, VLSM, and authentication, replacing the older RIPv1.
Overview
The 'version 2' command under router configuration mode for RIP (Routing Information Protocol) is used to enable RIPv2 on a Cisco router. RIPv2 is a classless, distance-vector routing protocol that supports Variable Length Subnet Masking (VLSM), classless inter-domain routing (CIDR), and authentication, making it a significant improvement over its predecessor RIPv1. This command is essential for network engineers who need to implement a simple, widely supported interior gateway protocol (IGP) in environments where classless routing is required.
Unlike RIPv1, which only advertises classful routes and does not support subnet masks, RIPv2 includes subnet mask information in its updates, allowing for more efficient IP address utilization and supporting modern network designs. The command is typically used in small to medium-sized networks where simplicity and ease of configuration are prioritized over convergence speed and scalability. Alternatives include OSPF (Open Shortest Path First) and EIGRP (Enhanced Interior Gateway Routing Protocol), which offer faster convergence and better scalability but require more complex configuration.
The 'version 2' command is often one of the first steps in configuring RIP on a router, followed by network statements to advertise interfaces. In terms of IOS behavior, entering this command modifies the running configuration immediately, and the change is saved to the startup configuration only if the 'copy running-config startup-config' command is executed. The command requires privileged EXEC mode (enable) and then global configuration mode.
There is no buffered output associated with this command; it simply sets the RIP version. The impact on the running config is that the 'version 2' line appears under the 'router rip' configuration block. This command is available in most IOS versions, including 12.x, 15.x, and 16.x, and is also supported in IOS-XE.
In NX-OS, the equivalent command is 'router rip' followed by 'version 2' under the RIP configuration mode. Understanding this command is fundamental for CCNA and CCNP candidates as it forms the basis for configuring RIP in a classless network environment.
version 2When to Use This Command
- Migrating from RIPv1 to RIPv2 to support VLSM in a network with subnetted IP addresses.
- Configuring RIPv2 in a multi-vendor environment where classless routing is required.
- Enabling RIPv2 to use authentication for secure route updates between neighbors.
- Setting up RIPv2 in a lab or production network to test or implement classless routing.
Command Examples
Basic RIPv2 Configuration
router rip
version 2
network 192.168.1.0
network 10.0.0.0Router(config)# router rip
Router(config-router)# version 2
Router(config-router)# network 192.168.1.0
Router(config-router)# network 10.0.0.0
Router(config-router)# end
Router# show ip protocols
Routing Protocol is "rip"
Outgoing update filter list for all interfaces is not set
Incoming update filter list for all interfaces is not set
Sending updates every 30 seconds, next due in 16 seconds
Invalid after 180 seconds, hold down 180, flushed after 240
Redistributing: rip
Default version control: send version 2, receive version 2
Interface Send Recv Triggered RIP Key-chain
GigabitEthernet0/0 2 2
GigabitEthernet0/1 2 2
Automatic network summarization is in effect
Maximum path: 4
Routing for Networks:
10.0.0.0
192.168.1.0
Routing Information Sources:
Gateway Distance Last Update
192.168.1.2 120 00:00:18
Distance: (default is 120)The 'router rip' command enters RIP configuration mode. 'version 2' sets RIP to version 2. 'network' commands advertise the specified networks. 'show ip protocols' confirms RIP is running version 2 on interfaces, with send/receive set to 2, and shows routing sources.
RIPv2 with Authentication
router rip
version 2
network 192.168.1.0
network 10.0.0.0
interface GigabitEthernet0/0
ip rip authentication key-chain RIPKEY
ip rip authentication mode md5Router(config)# router rip
Router(config-router)# version 2
Router(config-router)# network 192.168.1.0
Router(config-router)# network 10.0.0.0
Router(config-router)# exit
Router(config)# interface GigabitEthernet0/0
Router(config-if)# ip rip authentication key-chain RIPKEY
Router(config-if)# ip rip authentication mode md5
Router(config-if)# end
Router# show ip rip database
10.0.0.0/8 auto-summary
10.0.0.0/24 directly connected, GigabitEthernet0/1
192.168.1.0/24 directly connected, GigabitEthernet0/0
[1] via 192.168.1.2, 00:00:05, GigabitEthernet0/0
Router# show key chain RIPKEY
Key-chain RIPKEY:
key 1 -- text "cisco123"
accept lifetime (always valid) - (always valid) [valid now]
send lifetime (always valid) - (always valid) [valid now]After enabling RIPv2, authentication is configured on the interface. 'ip rip authentication key-chain' references a key chain with a password. 'ip rip authentication mode md5' sets MD5 authentication. 'show ip rip database' displays routes learned via RIP. 'show key chain' verifies the key chain details.
Understanding the Output
The 'show ip protocols' output confirms RIP version 2 is active. Key fields: 'Default version control' shows send/receive version (should be 2 for both). 'Interface' table lists each interface with Send/Recv version (2 for RIPv2).
'Routing for Networks' lists advertised networks. 'Routing Information Sources' shows RIP neighbors with last update time. Good values: version 2 on all interfaces, recent last update times (<30 seconds).
Bad values: version 1 or mixed versions, missing networks, stale updates. 'show ip rip database' shows routes with metric and next hop. Watch for 'auto-summary' if summarization is enabled (default on).
Configuration Scenarios
Enable RIPv2 on a single router with two directly connected networks
A network engineer needs to configure RIPv2 on a router that connects two subnets: 192.168.1.0/24 and 10.0.0.0/8. The goal is to enable dynamic routing between these networks using RIPv2.
Topology
R1(Gi0/0)---192.168.1.0/24---PC1
R1(Gi0/1)---10.0.0.0/8---PC2Steps
- 1.Step 1: Enter privileged EXEC mode: Router> enable
- 2.Step 2: Enter global configuration mode: Router# configure terminal
- 3.Step 3: Enter router configuration mode for RIP: Router(config)# router rip
- 4.Step 4: Enable RIPv2: Router(config-router)# version 2
- 5.Step 5: Advertise the directly connected networks: Router(config-router)# network 192.168.1.0
- 6.Step 6: Advertise the second network: Router(config-router)# network 10.0.0.0
- 7.Step 7: Exit configuration mode: Router(config-router)# end
! Router(config)# router rip Router(config-router)# version 2 Router(config-router)# network 192.168.1.0 Router(config-router)# network 10.0.0.0 Router(config-router)# end
Verify: Use 'show ip protocols' to verify that RIP is running and version 2 is enabled. Expected output includes 'Routing Protocol is "rip"' and 'Default version control: send version 2, receive version 2'.
Watch out: A common mistake is forgetting to specify the network statements. Without them, RIP will not advertise any routes, and the routing table will remain empty for RIP-learned routes.
Configure RIPv2 between two routers with authentication
Two branch routers, R1 and R2, are connected via a serial link (10.0.12.0/30). The network requires RIPv2 with MD5 authentication to secure routing updates between the routers.
Topology
R1(Se0/0/0)---10.0.12.0/30---(Se0/0/0)R2Steps
- 1.Step 1: On R1, enter global configuration mode: R1> enable; R1# configure terminal
- 2.Step 2: Create a key chain for authentication: R1(config)# key chain RIP_KEY
- 3.Step 3: Define a key with an ID and key string: R1(config-keychain)# key 1; R1(config-keychain-key)# key-string cisco123
- 4.Step 4: Enter router configuration mode for RIP: R1(config)# router rip
- 5.Step 5: Enable RIPv2: R1(config-router)# version 2
- 6.Step 6: Advertise the serial network: R1(config-router)# network 10.0.12.0
- 7.Step 7: Enable authentication on the serial interface: R1(config-router)# exit; R1(config)# interface serial0/0/0; R1(config-if)# ip rip authentication key-chain RIP_KEY; R1(config-if)# ip rip authentication mode md5
- 8.Step 8: Repeat similar steps on R2 with the same key string and key chain name.
- 9.Step 9: Exit configuration mode: R1(config-if)# end
! R1(config)# key chain RIP_KEY R1(config-keychain)# key 1 R1(config-keychain-key)# key-string cisco123 R1(config-keychain-key)# exit R1(config)# router rip R1(config-router)# version 2 R1(config-router)# network 10.0.12.0 R1(config-router)# exit R1(config)# interface serial0/0/0 R1(config-if)# ip rip authentication key-chain RIP_KEY R1(config-if)# ip rip authentication mode md5 R1(config-if)# end
Verify: Use 'show ip rip database' to see RIP routes. Use 'debug ip rip' to verify that updates are authenticated. Expected output shows 'RIP: sending v2 update to 224.0.0.9 via Serial0/0/0' and 'RIP: received v2 update from 10.0.12.2 via Serial0/0/0' with authentication.
Watch out: A common mistake is mismatched key strings or key chain names between routers, causing authentication failures. Also, ensure that the key chain is applied to the correct interface and that both routers use the same authentication mode (MD5).
Troubleshooting with This Command
When troubleshooting RIPv2 configuration, the 'version 2' command itself is straightforward, but issues often arise from missing or incorrect network statements, interface misconfigurations, or authentication problems. Healthy output from 'show ip protocols' should indicate that RIP is running, version 2 is enabled for both sending and receiving, and that the correct networks are being advertised. If the output shows 'Default version control: send version 1, receive version 1', then RIPv2 is not enabled.
Another key command is 'show ip route rip', which displays RIP-learned routes. If no RIP routes appear, check that network statements cover all interfaces that should participate in RIP. Use 'debug ip rip' to see real-time updates; healthy output shows periodic updates being sent and received.
If updates are not received, check for ACLs blocking multicast address 224.0.0.9, or authentication mismatches. For authentication issues, 'debug ip rip' will show 'RIP: bad authentication' messages. Also, verify that the key chain is correctly configured and applied to the interface.
Another common symptom is that routes are learned but not installed in the routing table; this could be due to administrative distance (RIP default is 120) or route filtering. Use 'show ip rip database' to see all RIP routes known, including those not installed. If routes are missing, check for passive interfaces (which should not send updates but can receive) or distribute-lists.
Correlate 'show ip protocols' with 'show running-config | section router rip' to ensure configuration is as intended. In summary, a systematic approach: verify version, verify network statements, verify interface participation, check for authentication, and then examine route propagation.
CCNA Exam Tips
CCNA exam tip: RIPv2 is classless and supports VLSM; RIPv1 is classful and does not. The 'version 2' command is required to enable RIPv2; without it, the router runs RIPv1 by default.
CCNA exam tip: RIPv2 uses multicast 224.0.0.9 for updates, while RIPv1 uses broadcast 255.255.255.255. This is a common exam comparison.
CCNA exam tip: Automatic summarization is enabled by default in RIPv2; use 'no auto-summary' to disable it for discontiguous networks.
CCNA exam tip: RIPv2 supports authentication (plaintext or MD5) using key chains; this is a configuration topic in the exam.
Common Mistakes
Mistake 1: Forgetting to issue 'version 2' after 'router rip', leaving the router running RIPv1, which does not support VLSM and causes routing issues with subnets.
Mistake 2: Not disabling auto-summary with 'no auto-summary' when using discontiguous subnets, leading to incorrect route summarization.
Mistake 3: Misconfiguring authentication by not creating a key chain or mismatching key names/strings between neighbors, causing RIP updates to be rejected.
version 2 vs router rip
These two commands are often paired but serve different purposes: 'router rip' initiates the RIP routing process and enters configuration mode, while 'version 2' is a subcommand used within that mode to enable RIPv2. Confusion arises because both are required to configure RIPv2, but they operate at different levels of the configuration hierarchy.
| Aspect | version 2 | router rip |
|---|---|---|
| Scope | Per-process, sets RIP version | Enables RIP routing process globally |
| Configuration mode | Router config (RIP subcommand) | Global config |
| Effect on RIP version | Explicitly sets version to 2 | Defaults to RIPv1 if no version specified |
| Dependence | Requires router rip first | Does not require version 2 to exist |
| Typical use | Enable VLSM, classless routing, authentication | Start RIP configuration and enter RIP mode |
Use version 2 when you need to enable RIPv2 features such as VLSM, classless routing, or authentication within an existing RIP configuration.
Use router rip when you are starting RIP configuration and need to enter the RIP router configuration mode.
Platform Notes
In IOS-XE, the 'version 2' command syntax is identical to classic IOS. The command is available in IOS-XE versions 16.x and later. In NX-OS, the equivalent command is 'router rip' followed by 'version 2' under the RIP configuration mode, but note that NX-OS uses a different configuration hierarchy; for example, 'feature rip' must be enabled first.
The command is not available in ASA or IOS-XR; ASA uses EIGRP or OSPF for dynamic routing, and IOS-XR does not support RIP. In terms of IOS version differences, the 'version 2' command has been available since IOS 12.0 and remains unchanged in later versions. However, in older IOS versions (pre-12.0), only RIPv1 was supported.
There are no significant output format differences between IOS versions for 'show ip protocols' regarding the version field. When migrating from IOS to IOS-XE, the configuration is directly transferable. For NX-OS, the RIP configuration is similar but requires enabling the feature first: 'feature rip' then 'router rip' then 'version 2'.
Always verify with 'show ip rip' or 'show ip protocols' on the respective platform.
Related Commands
router rip
Enters RIP router configuration mode to enable and configure the Routing Information Protocol (RIP) on a Cisco router.
show ip protocols
Displays the current state of all IP routing protocols running on the router, including timers, filters, and network advertisements.
show ip route
Displays the IP routing table showing all known routes, their source protocols, administrative distances, metrics, next-hops, and outgoing interfaces.
Practice for the CCNA 200-301
Test your knowledge with practice questions covering all CCNA 200-301 exam domains.
Practice CCNA 200-301 Questions