Skip to content

Instantly share code, notes, and snippets.

@mohammedaljubouri
mohammedaljubouri / upgrade_cisco.py
Created November 30, 2019 21:42 — forked from kubsoo/upgrade_cisco.py
Python script to upgrade ios on cisco devices. Script checks md5 checksum, upload ios, insert boot system command, backup run config and reloads switch.
#!/usr/bin/python
import netmiko
from netmiko import SCPConn
import os,sys,commands,re
def check_md5(filename):
command = 'md5sum '+filename
o = commands.getoutput(command)