Difference between revisions of "Updating IOS On Cisco Switch or Router"

From 24PinTech Wiki
Jump to navigation Jump to search
(Created page with "Updating an IOS on a Cisco Switch/Router using TFTP Install PuTTy or a similar Telnet application to be able to access the Switch/Router (S/R) through an ethernet connection....")
 
(Everything)
Line 1: Line 1:
Updating an IOS on a Cisco Switch/Router using TFTP
Exact command entries written in <code>{This format}</code>
Install PuTTy or a similar Telnet application to be able to access the Switch/Router (S/R) through an ethernet connection.
Install SolarWinds TFTP server or similar TFTP application to be able to send the IOS image to the S/R.
Configure TFTP with the correct IP address (192.168.0.0/24) and change your computer’s ethernet interface adapter the right address range. (Verify the adapter appears in TFTP)
Ensure that the correct IOS images are installed on your computer in the designated TFTP folder. (IOS images will have different names from the one pictured below.)
Use a computer with a serial cable or similar console connection (COM1) in order to connect to the console port on the S/R.
Enter privileged executive mode and verify the Flash: filesystem has enough space for the new image.
Configure the S/R as follows:
Enter configuration terminal mode.
Configure the console and vty lines (0 4) for remote access to the S/R. (Use password Cisco to make things easy.)
Configure the appropriate IP on the VLAN1/Interface (192.168.0.0/24 Network).
Exit back to privileged executive mode.
Clear the Flash: filesystem (This takes several minutes and it might seem frozen at first, it is working, I promise.)
Use a telnet connection over ethernet on your computer to connect to the address configured on the S/R.
Start the TFTP server.
Enter commands to send a TFTP file over the connection. (Using the computer address as the source. The filename of the IOS must also be EXACT.)
After the install has finished verify the file is now on the S/R.
Reload the S/R and do not save the configuration.
Wait for the reboot and verify that the S/R is a blank configuration with the correct IOS installed in Flash:.


Updating an IOS on a Cisco Switch/Router Using HyperTerminal
== '''Updating an IOS on a Cisco Switch/Router using TFTP''' ==
 
# Install [https://www.chiark.greenend.org.uk/~sgtatham/putty/latest.html PuTTy] or a similar Telnet application to be able to access the Switch/Router (S/R) through an ethernet connection.
# Install [https://www.solarwinds.com/free-tools/free-tftp-server SolarWinds TFTP server] or similar TFTP application to be able to send the IOS image to the S/R.
# Configure TFTP with the correct IP address (192.168.0.0/24) and change your computer’s ethernet interface adapter the right address range. (Verify the adapter appears in TFTP)[[File:Step 3a.png|center|thumb|IP configuration for the TFTP server.]][[File:Step 3b.png|center|thumb|IP configuration for the PC interface.]]
# Ensure that the correct IOS images are installed on your computer in the designated TFTP folder. (IOS images will have different names from the one pictured below.)[[File:Step 4.png|center|thumb|Verification of IOS Images (May be ''DIFFERENT'' depending on when you are updating.)]]
# Use a computer with a serial cable or similar console connection (COM1) in order to connect to the console port on the S/R.[[File:Step 5.png|center|thumb|COM1 Connection using Tera Term (Serial).]]
# Enter privileged executive mode and verify the ''Flash:'' filesystem has enough space for the new image. [[File:Step 6.png|center|thumb|Verify ''Flash:'' directory size and current IOS while In privileged executive.]]
# Configure the S/R as follows:
#* Enter configuration terminal mode.
#* Configure the console and vty lines (0 4) for remote access to the S/R. (Use password ''Cisco'' to make things easy.)[[File:Step 7a-b.png|center|thumb|Line console and vty 0 4 configurations.]]
#* Configure the appropriate IP on the VLAN1/Interface (192.168.0.0/24 Network).
#* Exit back to privileged executive mode.[[File:Step 7c-d.png|center|thumb|IP address configuration on a switch (Will be an ''INTERFACE'' on a router).]]
#* Clear the ''Flash:'' filesystem (This takes several minutes and it might seem frozen at first, it is working, I promise.)
#* [[File:Step 7e.png|center|thumb|Erasure of ''Flash:'' filesystem.]]
# Use a telnet connection over ethernet on your computer to connect to the address configured on the S/R.[[File:Step 8.png|center|thumb|IP connection to the S/R using Tera Term (Telnet).]]
# Start the TFTP server.[[File:Step 9.png|center|thumb|A running TFTP server.]]
# Enter commands to send a TFTP file over the connection. (Using the computer address as the source. The filename of the IOS must also be EXACT.)
# After the install has finished verify the file is now on the S/R.
# Reload the S/R and do not save the configuration.
# Wait for the reboot and verify that the S/R is a blank configuration with the correct IOS installed in ''Flash:''.
 
== '''Updating an IOS on a Cisco Switch/Router Using HyperTerminal''' ==
ROMMON COMMANDS ARE DIFFERENT FROM REGULAR CLI FOR S/R. CHECK YOUR SYNTAX.
ROMMON COMMANDS ARE DIFFERENT FROM REGULAR CLI FOR S/R. CHECK YOUR SYNTAX.
So you’re the idiot that reloaded an S/R without an IOS on the flash and it only boots into ROMMON? (i.e. switch: )
 
Install HyperTerminal using a Windows XP disc. (Find instructions on how here.)
# So you’re the [https://www.merriam-webster.com/dictionary/idiot idiot] that reloaded an S/R without an IOS on the flash and it only boots into ROMMON? (i.e. switch: )
Connect to the S/R using a console connection over COM1 (Run the .exe file to access HyperTerminal (HT). It may ask for a phone number, you do not need one.) (BAUD rate may also be an issue. The usual default is 9600 bits/sec. If the connection is not working try matching the default BAUD rate of the S/R.)
# Install HyperTerminal using a Windows XP disc. (Find instructions on how [https://www.instructables.com/Port-Hyperterminal-to-Windows-7/ here].)
Check the Flash: filesystem to verify it can fit the new IOS.
# Connect to the S/R using a console connection over COM1 (Run the .exe file to access HyperTerminal (HT). It may ask for a phone number, you do not need one.) (BAUD rate may also be an issue. The usual default is 9600 bits/sec. If the connection is not working try matching the default BAUD rate of the S/R and then use [https://www.cisco.com/c/en/us/support/docs/routers/10000-series-routers/50421-config-register-use.html CONFREG] command to change the rate (Higher rates may run into problems).)
Use copy xmodem command to copy the IOS from the computer.
# Check the ''Flash:'' filesystem to verify it can fit the new IOS.
Click the transfer button and then send file while the previous command is still running to send the file (Use xmodem or xmodem-1K)
# Use copy xmodem: flash:FILENAME command to copy the IOS from the computer.
Once the install has finished verify the IOS has been installed to the Flash: filesystem.
# Click the transfer button and then send file while the previous command is still running to send the file (Use xmodem or xmodem-1K)
Reset the switch and then verify the correct IOS is installed once more.
# Once the install has finished verify the IOS has been installed to the ''Flash:'' filesystem.
# Reset the switch and then verify the correct IOS is installed once more.

Revision as of 16:16, 23 February 2021

Exact command entries written in {This format}

Updating an IOS on a Cisco Switch/Router using TFTP

  1. Install PuTTy or a similar Telnet application to be able to access the Switch/Router (S/R) through an ethernet connection.
  2. Install SolarWinds TFTP server or similar TFTP application to be able to send the IOS image to the S/R.
  3. Configure TFTP with the correct IP address (192.168.0.0/24) and change your computer’s ethernet interface adapter the right address range. (Verify the adapter appears in TFTP)
    IP configuration for the TFTP server.
    IP configuration for the PC interface.
  4. Ensure that the correct IOS images are installed on your computer in the designated TFTP folder. (IOS images will have different names from the one pictured below.)
    Verification of IOS Images (May be DIFFERENT depending on when you are updating.)
  5. Use a computer with a serial cable or similar console connection (COM1) in order to connect to the console port on the S/R.
    COM1 Connection using Tera Term (Serial).
  6. Enter privileged executive mode and verify the Flash: filesystem has enough space for the new image.
    Verify Flash: directory size and current IOS while In privileged executive.
  7. Configure the S/R as follows:
    • Enter configuration terminal mode.
    • Configure the console and vty lines (0 4) for remote access to the S/R. (Use password Cisco to make things easy.)
      Line console and vty 0 4 configurations.
    • Configure the appropriate IP on the VLAN1/Interface (192.168.0.0/24 Network).
    • Exit back to privileged executive mode.
      IP address configuration on a switch (Will be an INTERFACE on a router).
    • Clear the Flash: filesystem (This takes several minutes and it might seem frozen at first, it is working, I promise.)
    • Erasure of Flash: filesystem.
  8. Use a telnet connection over ethernet on your computer to connect to the address configured on the S/R.
    IP connection to the S/R using Tera Term (Telnet).
  9. Start the TFTP server.
    A running TFTP server.
  10. Enter commands to send a TFTP file over the connection. (Using the computer address as the source. The filename of the IOS must also be EXACT.)
  11. After the install has finished verify the file is now on the S/R.
  12. Reload the S/R and do not save the configuration.
  13. Wait for the reboot and verify that the S/R is a blank configuration with the correct IOS installed in Flash:.

Updating an IOS on a Cisco Switch/Router Using HyperTerminal

ROMMON COMMANDS ARE DIFFERENT FROM REGULAR CLI FOR S/R. CHECK YOUR SYNTAX.

  1. So you’re the idiot that reloaded an S/R without an IOS on the flash and it only boots into ROMMON? (i.e. switch: )
  2. Install HyperTerminal using a Windows XP disc. (Find instructions on how here.)
  3. Connect to the S/R using a console connection over COM1 (Run the .exe file to access HyperTerminal (HT). It may ask for a phone number, you do not need one.) (BAUD rate may also be an issue. The usual default is 9600 bits/sec. If the connection is not working try matching the default BAUD rate of the S/R and then use CONFREG command to change the rate (Higher rates may run into problems).)
  4. Check the Flash: filesystem to verify it can fit the new IOS.
  5. Use copy xmodem: flash:FILENAME command to copy the IOS from the computer.
  6. Click the transfer button and then send file while the previous command is still running to send the file (Use xmodem or xmodem-1K)
  7. Once the install has finished verify the IOS has been installed to the Flash: filesystem.
  8. Reset the switch and then verify the correct IOS is installed once more.