<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>IOS - Category - Fryguy's Blog</title><link>https://hugo.fryguy.net/categories/ios/</link><description>IOS - Category - Fryguy's Blog</description><generator>Hugo -- gohugo.io</generator><language>en</language><lastBuildDate>Wed, 06 Mar 2013 23:15:14 +0000</lastBuildDate><atom:link href="https://hugo.fryguy.net/categories/ios/" rel="self" type="application/rss+xml"/><item><title>VTY Session on a Router Won't Clear?</title><link>https://hugo.fryguy.net/2013/03/06/vty-session-on-a-router-wont-clear/</link><pubDate>Wed, 06 Mar 2013 23:15:14 +0000</pubDate><author>Fryguy</author><guid>https://hugo.fryguy.net/2013/03/06/vty-session-on-a-router-wont-clear/</guid><description><![CDATA[<p>[<a href="/wp-content/uploads/2013/03/MyView.jpg" rel=""></a>]<a href="/wp-content/uploads/2013/03/MyView.jpg" rel="">2</a><br>
Had a small problem today that was interesting, but not unique.  I have seen this problem before, but realized that maybe most people might not know how to fix it. I think the normal approach that people take is a reload of the device, not always a good thing to do on a production network in the middle of the day.<br>
So the  depicts is a VTY session that is unclearable via the normal <em>clear</em> command route.  When you do a <em>who</em>, you see that someone is connected to VTY 0 for an extended period of time:</p>
<pre>Switch1#<span style="color: #0000ff;">who</span>
    Line       User       Host(s)              Idle       Location
   1 vty 0                idle                     6w4d HackerHost.virtua.com.br
*  2 vty 1     jfry       idle                 00:00:00 192.168.0.1
  Interface      User        Mode                     Idle     Peer Address
Switch1#</pre>
<p>They are not logged in as there is no User listed, but you can see they have been idle for 6 weeks and 4 days.<br>
So the first think that you would do would be to <em>clear</em> the session and do a <em>who</em> again to make sure they are gone.</p>
<pre>Switch1#<span style="color: #0000ff;">clear line vty 0</span>
[confirm]<span style="color: #0000ff;">y</span> [OK]
Switch1#who
    Line       User       Host(s)              Idle       Location
   1 vty 0                idle                     6w4d HackerHost.virtua.com.br
*  2 vty 1     jfry       idle                 00:00:00 192.168.0.1
  Interface      User        Mode                     Idle     Peer Address
Switch1#</pre>
<p>Odd, they are still there.  Well, maybe its <em>VTY 1</em> and not __, lets clear that one instead:</p>]]></description></item><item><title>Junos – Lab Topology and Hardware Specs</title><link>https://hugo.fryguy.net/2012/10/29/junos-lab-topology-and-hardware-specs/</link><pubDate>Mon, 29 Oct 2012 12:29:08 +0000</pubDate><author>Fryguy</author><guid>https://hugo.fryguy.net/2012/10/29/junos-lab-topology-and-hardware-specs/</guid><description><![CDATA[<p><a href="/wp-content/uploads/2012/08/junos_sw_logo.jpg" rel=""></a><br>
Well, the time has come to start posting some of the Junos stuff that I have been working on.  What I have decided to do with this post is post the Hardware Information that I used for the lab.  I will then reference this post in the posts to come so that anyone can see what was used.  Below is a picture of the lab topology:<br>
<a href="/wp-content/uploads/2012/10/Master-Lab-Topology.jpg" rel=""></a></p>]]></description></item><item><title>IOS XR – iBGP and eBGP</title><link>https://hugo.fryguy.net/2012/09/24/ios-xr-ibgp-and-ebgp/</link><pubDate>Mon, 24 Sep 2012 12:25:02 +0000</pubDate><author>Fryguy</author><guid>https://hugo.fryguy.net/2012/09/24/ios-xr-ibgp-and-ebgp/</guid><description><![CDATA[<p><a href="/wp-content/uploads/2012/09/iosxrfryguy-8.jpg" rel=""></a><br>
BGP, this is where it starts to get different with IOS XR.<br>
First up, configuring an iBGP peering with R2’s 150.1.12.2 in AS1 and advertise our loopback interface.<br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config)#</span><br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config)#<span style="color: #ff0000;">router bgp 1</span></span><br>
Let’s define the network we want to advertise, under the address family:<br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config-bgp)#<span style="color: #ff0000;">address-family ipv4 unicast </span></span><br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config-bgp-af)#<span style="color: #ff0000;">net 1.1.1.1/32</span></span><br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config-bgp-af)#<span style="color: #ff0000;">exit</span></span><br>
Now, we can configure the neighbor.  Notice all the commands for the neighbor are under the neighbor now – not next to the neighbor.<br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config-bgp)#<span style="color: #ff0000;">nei 150.1.12.2</span></span><br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config-bgp-nbr)#<span style="color: #ff0000;">remote-as 1</span></span><br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config-bgp-nbr)#<span style="color: #ff0000;">address-family ipv4 unicast </span></span><br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config-bgp-nbr-af)#<span style="color: #ff0000;">exit</span></span><br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config-bgp-nbr)#<span style="color: #ff0000;">comm</span></span><br>
<span style="color: #0000ff;">Thu Mar 29 22:47:05.147 UTC</span><br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config-bgp)#<span style="color: #ff0000;">exit</span></span><br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1(config)#<span style="color: #ff0000;">exit</span></span><br>
Now, time to see if we have a neighbor established:<br>
<span style="color: #0000ff;">RP/0/7/CPU0:R1#<span style="color: #ff0000;">sh bgp nei 150.1.12.2</span></span><br>
<span style="color: #0000ff;">Thu Mar 29 22:48:13.338 UTC</span></p>]]></description></item><item><title>IOS XR – ISIS</title><link>https://hugo.fryguy.net/2012/09/21/ios-xr-isis/</link><pubDate>Fri, 21 Sep 2012 12:37:49 +0000</pubDate><author>Fryguy</author><guid>https://hugo.fryguy.net/2012/09/21/ios-xr-isis/</guid><description><![CDATA[<p align="center">
  
</p>
<p>Time for some IS-IS routing! Between IS-IS and OSPF, those are the two most coming SP core routing protocols.<br>
<span style="color: blue;">RP/0/7/CPU0:R1#<span style="color: red;">conf t<br /> </span>Thu Mar 29 22:09:12.786 UTC</span><br>
First we need to name our process<br>
<span style="color: blue;">RP/0/7/CPU0:R1(config)#</span><span style="color: red;">router isis LAB</span><br>
Then configure our Network Entity ( Area )<br>
<span style="color: blue;">RP/0/7/CPU0:R1(config-isis)#</span><span style="color: red;">net 49.0000.0000.0001.00</span><br>
Then we assign the interfaces to the process, as well as the address family.<br>
<span style="color: blue;">RP/0/7/CPU0:R1(config-isis)#<span style="color: red;">int l0</span><br /> RP/0/7/CPU0:R1(config-isis-if)#<span style="color: red;">address-family ipv4<br /> </span>RP/0/7/CPU0:R1(config-isis-if-af)#<span style="color: red;">exit</span><br /> RP/0/7/CPU0:R1(config-isis-if)#<span style="color: red;">address-family ipv6</span><br /> RP/0/7/CPU0:R1(config-isis-if-af)# <span style="color: red;">exit</span><br /> RP/0/7/CPU0:R1(config-isis-if)#<span style="color: red;">int g0/3/0/2<br /> </span>RP/0/7/CPU0:R1(config-isis-if)#<span style="color: black;">address-family ipv4</span><br /> RP/0/7/CPU0:R1(config-isis-if-af)# <span style="color: red;">exit</span><br /> RP/0/7/CPU0:R1(config-isis-if)#<span style="color: red;">address-family ipv6<br /> </span>RP/0/7/CPU0:R1(config-isis-if-af)# <span style="color: red;">exit</span><br /> RP/0/7/CPU0:R1(config-isis-if)#</span> <span style="color: red;">exit</span><br>
Notice I did not specify an IS-IS Level when I started, but we can set this to Level-2<br>
<span style="color: blue;">RP/0/7/CPU0:R1(config-isis)#</span><span style="color: red;">is-type level-2-only</span><br>
Now, when we show the config, you will notice Level-2 is set to the top of the config when applied, not in the order I entered it. This is the beauty of a staging config, you can enter some things in the wrong order but they will be applied in the correct order.</p>]]></description></item><item><title>IOS XR – RIP</title><link>https://hugo.fryguy.net/2012/09/19/ios-xr-rip/</link><pubDate>Wed, 19 Sep 2012 12:28:06 +0000</pubDate><author>Fryguy</author><guid>https://hugo.fryguy.net/2012/09/19/ios-xr-rip/</guid><description><![CDATA[<p align="center">
  
</p>
<p>Ok, time for the next routing protocol – RIP. Why would you use IOS XR for RIP? Well, if you have a CE device that only has a few networks, RIP is a perfect protocol. Keep in mind that IOS XR is code built for a Service Provider network, so PE-CE relationships are what these routers are about. Another quick note on these labs, I do not show the configuraiton of the other device (R2) as it is just a mirrored config.<br>
Plus – it is just good to know different options.<br>
<span style="color: blue;">RP/0/7/CPU0:R1#<span style="color: red;">conf t<br /> </span>Thu Mar 29 20:37:44.801 UTC<br /> RP/0/7/CPU0:R1(config)#<span style="color: red;">router rip</span><br /> RP/0/7/CPU0:R1(config-rip)#<span style="color: red;">int l0<br /> </span>RP/0/7/CPU0:R1(config-rip-if)#<span style="color: red;">int g0/3/0/2<br /> </span>RP/0/7/CPU0:R1(config-rip-if)#<span style="color: red;">^Z</span><br /> Uncommitted changes found, commit them before exiting(yes/no/cancel)? [cancel]:<span style="color: red;">yes</span><br /> </span><br>
Notice I did not do a COMMIT, but since the router knows I was making changes it asked me.<br>
Let’s check our IP protocols:<br>
<span style="color: blue;">RP/0/7/CPU0:R1#<span style="color: red;">sh ip proto</span><br /> Thu Mar 29 20:39:20.919 UTC</span><br>
<span style="color: blue;">Routing Protocol RIP<br /> 1 VRFs (including default) configured, 1 active<br /> 6 routes, 3 paths have been allocated<br /> Current OOM state is “Normal”<br /> UDP socket descriptor is 42<br /> VRF Active If-config If-active Routes Paths Updates<br /> default Active 2 2 6 3 30s<br /></p>]]></description></item><item><title>IOS XR – EIGRP</title><link>https://hugo.fryguy.net/2012/09/17/ios-xr-eigrp/</link><pubDate>Mon, 17 Sep 2012 13:01:25 +0000</pubDate><author>Fryguy</author><guid>https://hugo.fryguy.net/2012/09/17/ios-xr-eigrp/</guid><description><![CDATA[<p align="center">
  
</p>
<p>Up next is IOS XR and EIGRP<br>
<span style="color: blue;">RP/0/7/CPU0:R1#<span style="color: red;">conf t</span><br /> Thu Mar 29 20:07:53.797 UTC<br /> RP/0/7/CPU0:R1(config)#<span style="color: red;">no router ospf LAB<br /> </span>RP/0/7/CPU0:R1(config)#</span><span style="color: red;">commit</span><br>
Once that is deleted, we can now continue with EIGRP configuration.<br>
Just like IOS, we need to give it a process ID<br>
<span style="color: blue;">RP/0/7/CPU0:R1(config)#<br /> RP/0/7/CPU0:R1(config)#</span><span style="color: red;">router eigrp 1</span><br>
Here is where the difference starts, we need to select the Address family first<br>
<span style="color: blue;">RP/0/7/CPU0:R1(config-eigrp)#<span style="color: red;">address-family ipv4</span></span><br>
Enter no auto-summary ( this is habitual to be honest )<br>
<span style="color: blue;">RP/0/7/CPU0:R1(config-eigrp-af)#</span><span style="color: red;">no auto-summary</span><br>
Then assign the interfaces you want in EIGRP<br>
<span style="color: blue;">RP/0/7/CPU0:R1(config-eigrp-af)#<span style="color: red;">int</span> l0<br /> RP/0/7/CPU0:R1(config-eigrp-af-if)#<span style="color: red;">int g0/3/0/2<br /> </span>RP/0/7/CPU0:R1(config-eigrp-af-if)#<span style="color: red;">exit</span><br /> RP/0/7/CPU0:R1(config-eigrp-af)#<span style="color: red;">exit</span><br /> RP/0/7/CPU0:R1(config-eigrp)#<span style="color: red;">exit</span><br /> RP/0/7/CPU0:R1(config)#<span style="color: red;">commit</span><br /> Thu Mar 29 20:08:59.108 UTC<br /> RP/0/7/CPU0:R1(config)#exit</span></p>]]></description></item><item><title>IOS XR – OSPF Configuration</title><link>https://hugo.fryguy.net/2012/09/14/ios-xr-ospf-configuration/</link><pubDate>Fri, 14 Sep 2012 13:22:03 +0000</pubDate><author>Fryguy</author><guid>https://hugo.fryguy.net/2012/09/14/ios-xr-ospf-configuration/</guid><description><![CDATA[<p align="center">
  
</p>
<p> </p>
<p class="MsoNoSpacing">
  <span style="font-family: 'Courier New';"><br style="font-family: 'Courier New';" /></span>
</p>
<p class="MsoNoSpacing">
  <span style="font-family: 'Courier New';">Time for some OSPF configs, these will build off the previous configs we just did.<span style="mso-spacerun: yes;">  </span>For this lab, the other router, R2, was<br /> preconfigured to support the connections.<span style="mso-spacerun: yes;"><br /> </span></span>
</p>
<p class="MsoNoSpacing">
  <span style="font-family: 'Courier New';">We will place our loopback and out g0/3/0/2 interface into OSPF process LAB and area 0.0.0.0</span>
</p>
<p class="MsoNoSpacing">
  <span style="font-family: 'Courier New'; color: #0070c0;">RP/0/7/CPU0:R1#<br /> RP/0/7/CPU0:R1#</span><span style="font-family: 'Courier New'; color: red;">conf t</span><span style="font-family: 'Courier New'; color: #002060;"><br /> Thu Mar 29 19:37:52.671 UTC<br style="mso-special-character: line-break;" /><br /> <br style="mso-special-character: line-break;" />Defineour OSPF process name</span><span style="font-family: 'Courier New'; color: #0070c0;"><br /> RP/0/7/CPU0:R1(config)#</span><span style="font-family: 'Courier New'; color: red;">router ospf LAB</span>
</p>
<p><span style="font-family: 'Courier New'; color: #002060;">Now to define our area first</span><span style="font-family: 'Courier New'; color: #0070c0;"><br /> RP/0/7/CPU0:R1(config-ospf)#</span><span style="font-family: 'Courier New'; color: red;">area 0.0.0.0</span></p>
<p class="MsoNoSpacing">
  <span style="font-family: 'Courier New'; color: #002060;">Now we can place the interfaces into the area, no need to entering subnets</span><span style="font-family: 'Courier New'; color: #0070c0;"><br /> RP/0/7/CPU0:R1(config-ospf-ar)#</span><span style="font-family: 'Courier New'; color: red;">inter loo0</span><span style="font-family: 'Courier New'; color: #0070c0;"><br /> RP/0/7/CPU0:R1(config-ospf-ar-if)#</span><span style="font-family: 'Courier New'; color: red;">inter g0/3/0/2</span><span style="font-family: 'Courier New'; color: #0070c0;"><br /> RP/0/7/CPU0:R1(config-ospf-ar-if)#</span><span style="font-family: 'Courier New'; color: red;">exit</span><span style="font-family: 'Courier New'; color: #0070c0;"><br /> RP/0/7/CPU0:R1(config-ospf-ar)#</span><span style="font-family: 'Courier New'; color: red;">exit</span><span style="font-family: 'Courier New'; color: #0070c0;"><br /> RP/0/7/CPU0:R1(config-ospf)#</span><span style="font-family: 'Courier New'; color: red;">exit</span><span style="font-family: 'Courier New'; color: #0070c0;"><br /> RP/0/7/CPU0:R1(config)#</span><span style="font-family: 'Courier New'; color: red;">commit</span>
</p>
<p class="MsoNoSpacing">
  <span style="font-family: 'Courier New'; color: #0070c0;">Thu Mar 29 19:38:15.182 UTC<br /> RP/0/7/CPU0:R1(config)#</span>
</p>
<p class="MsoNoSpacing">
  <span style="font-family: 'Courier New';">Now to look at our IP Protocols running:</span><span style="font-family: 'Courier New'; color: #0070c0;"><br /> RP/0/7/CPU0:R1#</span><span style="font-family: 'Courier New'; color: red;">sh ip proto</span><span style="font-family: 'Courier New'; color: #0070c0;"><br /> Thu Mar 29 19:38:24.113 UTC<br /> Routing Protocol OSPF LAB<span style="mso-spacerun: yes;"><br /> </span>Router Id: 1.1.1.1<span style="mso-spacerun: yes;"><br /> </span>Distance: 110<span style="mso-spacerun: yes;"><br /> </span>Non-Stop Forwarding: Disabled<span style="mso-spacerun: yes;"><br /> </span>Redistribution:<span style="mso-spacerun: yes;"><br /> </span>None<span style="mso-spacerun: yes;"><br /> </span>Area 0.0.0.0<span style="mso-spacerun: yes;"><br /> </span>Loopback0<span style="mso-spacerun: yes;"><br /> </span>GigabitEthernet0/3/0/2<br /> RP/0/7/CPU0:R1#</span>
</p>
<p class="MsoNoSpacing">]]></description></item><item><title>IOS XR – Remote Access Services – Telnet and SSH</title><link>https://hugo.fryguy.net/2012/09/12/ios-xr-remote-access-services-telnet-and-ssh/</link><pubDate>Wed, 12 Sep 2012 13:04:55 +0000</pubDate><author>Fryguy</author><guid>https://hugo.fryguy.net/2012/09/12/ios-xr-remote-access-services-telnet-and-ssh/</guid><description><![CDATA[<p align="center">
  
</p>
<p>We need to have a way to remote access this device, and by default SSH and TELNET are not enabled.<br>
First up, the easy one – telnet.<br>
<span style="color: blue;">RP/0/RSP0/CPU0:R1(config)#</span><span style="color: red;">telnet ipv4 server max-servers 10</span><br>
And like that, we can telnet.<br>
Ok, onto SSH – but before setting up SSH, we need to generate an RSA key. This is a bit different as you do not do this from config mode.<br>
First up, add your domain-name if you do not have one:<br>
<span style="color: blue;">RP/0/RSP0/CPU0:R1(config)#<span style="color: red;">domain name fryguy.net<br /> </span>RP/0/RSP0/CPU0:R1(config)#<span style="color: red;">commit</span><br /> RP/0/RSP0/CPU0:R1#crypto key generate rsa<br /> Sat Apr 21 00:36:07.790 UTC<br /> The name for the keys will be: the_default<br /> Choose the size of the key modulus in the range of 512 to 2048 for your General Purpose Keypair. Choosing a key modulus greater than 512 may take a few minutes.</span><br>
<span style="color: blue;">How many bits in the modulus [1024]: 2048<br /> Generating RSA keys …<br /> Done w/ crypto generate keypair<br /> [OK]</span><br>
<span style="color: blue;">RP/0/RSP0/CPU0:R1#<br /></p>]]></description></item><item><title>IOS XR – Processes</title><link>https://hugo.fryguy.net/2012/09/10/ios-xr-processes/</link><pubDate>Mon, 10 Sep 2012 12:27:58 +0000</pubDate><author>Fryguy</author><guid>https://hugo.fryguy.net/2012/09/10/ios-xr-processes/</guid><description><![CDATA[<p><a href="/wp-content/uploads/2012/05/iosxrfryguy-21.jpg" rel=""></a><br>
So, since IOS XR is based on QNX, the SHOW PROCESSES command is a bit different then you would see in IOS. In IOS XR, you can actually query processes and see what is going on.<br>
Here is a way to see what BGP is doing :<br>
<span style="color: blue;">RP/0/RSP0/CPU0:R2#<span style="color: red;">sh processes bgp</span><br /> Tue Apr 24 01:23:06.343 UTC<br /> Job Id: 1039<br /> PID: 2941214<br /> Executable path: /disk0/iosxr-routing-4.1.2/bin/bgp<br /> Instance #: 1<br /> Version ID: 00.00.0000<br /> Respawn: ON<br /> Respawn count: 4<br /> Max. spawns per minute: 12<br /> Last started: Tue Apr 10 05:31:26 2012<br /> Process state: Run<br /> Package state: Normal<br /> Started on config: ipc/gl/ip-bgp/meta/speaker/default<br /> core: MAINMEM<br /> Max. core: 0<br /> Placement: Placeable<br /> startup_path: /pkg/startup/bgp.startup<br /> Ready: 0.338s<br /> Available: 25.582s<br /> Process cpu time: 63.719 user, 1.074 kernel, 64.793 total<br /> JID TID CPU Stack pri state TimeInState HR:MM:SS:MSEC NAME<br /> 1039 1 1 312K 10 Receive 0:01:01:0795 0:00:00:0249 bgp<br /> 1039 2 1 312K 10 Receive 331:51:39:0224 0:00:00:0000 bgp<br /> 1039 3 0 312K 10 Receive 331:51:39:0223 0:00:00:0001 bgp<br /> 1039 4 1 312K 10 Sigwaitinfo 331:51:39:0129 0:00:00:0000 bgp<br /> 1039 5 0 312K 10 Receive 0:00:01:0764 0:00:00:0005 bgp<br /> 1039 6 1 312K 10 Receive 0:00:01:0760 0:00:00:0016 bgp<br /> 1039 7 0 312K 10 Receive 0:00:23:0239 0:00:02:0242 bgp<br /> 1039 8 0 312K 10 Receive 0:00:03:0321 0:00:02:0280 bgp</span><br>
<span style="color: blue;"></p>]]></description></item><item><title>IOS XR – Wildcard Masks</title><link>https://hugo.fryguy.net/2012/09/07/ios-xr-wildcard-masks-2/</link><pubDate>Sat, 08 Sep 2012 01:24:21 +0000</pubDate><author>Fryguy</author><guid>https://hugo.fryguy.net/2012/09/07/ios-xr-wildcard-masks-2/</guid><description><![CDATA[<p><a href="/wp-content/uploads/2012/05/iosxrfryguy-21.jpg" rel=""></a><br>
Sorry for the lapse in posting. I am working on something that I think is pretty cool. Should be ready for publication soon!<br>
But back to IOS XR for a quick post!<br>
A really cool thing with IOS XR is interface wildcards.<br>
If you want to only see the Loopback interfaces, all of them. Normally you would do something like Show int br | in Loop, but with XR you can use a wildcard (<em>)<br>
<span style="color: blue;">RP/0/7/CPU0:R1#<span style="color: red;">sh int l</em> br<br /> </span>Mon Apr 16 17:21:08.088 UTC<br /> Intf Intf LineP Encap MTU BW<br /> Name State State Type (byte) (Kbps)<br /> ———————————————————————-<br /> Lo0 up up Loopback 1500 0<br /> Lo100 up up Loopback 1500 0<br /> Lo666 up up Loopback 1500 0<br /> Lo667 up up Loopback 1500 0<br /> Lo1000 up up Loopback 1500 0</span><br>
<span style="color: blue;">RP/0/7/CPU0:R1#</span></p>]]></description></item></channel></rss>