{"id":205,"date":"2020-09-26T13:27:42","date_gmt":"2020-09-26T13:27:42","guid":{"rendered":"https:\/\/dft.wiki\/?p=205"},"modified":"2021-02-07T20:40:51","modified_gmt":"2021-02-07T20:40:51","slug":"ripv2-on-cisco-routers","status":"publish","type":"post","link":"https:\/\/dft.wiki\/?p=205","title":{"rendered":"RIPv2 on Cisco Routers"},"content":{"rendered":"<p>RIP is a protocol that routers use to communicate and share information about what networks they are connected to. Every 30 seconds all the routers inform their neighbors the full list of networks they have, even if nothing has been changed since the last time.<\/p>\n<p>This protocol counts the number of hops is necessary to get to the destination and after 15 hops the networks are considered unreachable. The version v1 (default) is obsolete, so always use v2.<\/p>\n<p>Given the scenario below, PC1 needs to reach PC2:<\/p>\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img decoding=\"async\" class=\"wp-image-413\" src=\"https:\/\/dft.wiki\/wp-content\/uploads\/sites\/15\/2020\/09\/image-72.png\" alt=\"\" \/><\/figure>\n<\/div>\n<p>In the example above v1 would not work, because it is classful (does not accept sub-networks) and the auto summarization of networks would also make it fail (while trying to merge the network IPs).<\/p>\n<div class=\"wp-block-columns\">\n<div class=\"wp-block-column\">\n<p>Router1<\/p>\n<pre>enable <br \/>configure terminal <br \/>hostname Router1<br \/>no ip domain lookup<br \/>line con 0<br \/>logging synchronous<br \/><br \/>interface g0\/0<br \/>ip address 192.168.3.1 255.255.255.252<br \/>no shutdown<br \/>interface g0\/1<br \/>ip address 192.168.1.1 255.255.255.252<br \/>no shutdown<br \/><br \/>router rip<br \/>version 2<br \/>no auto-summary<br \/>network 192.168.3.0<br \/>network 192.168.1.0<br \/>passive-interface g0\/1<\/pre>\n<\/div>\n<div class=\"wp-block-column\">\n<p>Router2<\/p>\n<pre>enable <br \/>configure terminal <br \/>hostname Router2<br \/>no ip domain lookup<br \/>line con 0<br \/>logging synchronous<br \/><br \/>interface g0\/0<br \/>ip address 192.168.3.2 255.255.255.252<br \/>no shutdown<br \/>interface g0\/1<br \/>ip address 192.168.2.1 255.255.255.252<br \/>no shutdown<br \/><br \/>router rip<br \/>version 2<br \/>no auto-summary<br \/>network 192.168.3.0<br \/>network 192.168.2.0<br \/>passive-interface g0\/1<\/pre>\n<\/div>\n<\/div>\n<p>The router gateway to outside the network has to have this parameter set in the &#8216;<strong>router rip<\/strong>&#8216; config:<\/p>\n<pre>default-information originate<\/pre>\n<p>This will inform all the other routers who of them is the &#8216;<strong>gateway of last resort<\/strong>&#8216; when one network is unknown.<\/p>\n<p>Also, use the command below to make all the interfaces passive by default and only activate the ones that you need:<\/p>\n<pre>passive-interface default<br \/>no passive-interface Serial0\/0\/0<br \/>no passive-interface Serial0\/0\/1<\/pre>\n<p>To check the configuration in each Router issue the commands:<\/p>\n<pre>show ip protocols<br \/>debug ip rip<br \/>show ip rip database<br \/>show ip rip neighbors<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>RIP is a protocol that routers use to communicate and share information about what networks [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-205","post","type-post","status-publish","format-standard","hentry","category-ccna"],"_links":{"self":[{"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/posts\/205","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dft.wiki\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=205"}],"version-history":[{"count":6,"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/posts\/205\/revisions"}],"predecessor-version":[{"id":1041,"href":"https:\/\/dft.wiki\/index.php?rest_route=\/wp\/v2\/posts\/205\/revisions\/1041"}],"wp:attachment":[{"href":"https:\/\/dft.wiki\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=205"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dft.wiki\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=205"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dft.wiki\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=205"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}