Python for Network Administrators

Course Features

Course Details


Python for Network Administrators is designed for network/systems administrators to equip them with the skills and tools to carry out automation in network administrative tasks. During the program, participants will learn about the fundamentals of writing and executing Python scripts, using advanced features like file operations, regular expressions, working with binary data, and exploring the vast functionalities of Python modules, focusing on modules such as Git, SSH, and RESTful services. The course encourages participants to work with Python in a hands-on manner, going beyond a theoretical knowledge of its syntax and grammar. At the end of the program, participants will have developed a strong foundational understanding of Python to explore its various real-world applications across automation and network administration.

In this course, participants will explore concepts and tools such as:

  • Writing executable Python scripts based on effective practices
  • Using python data types optimally
  • Reading and writing files using text as well as binary data
  • Standard library and work-saving modules
  • Using collections such as lists, dictionaries, and sets appropriately
  • Features of Python like comprehensions and iterators
  • Searching and replacing text with regular expressions
  • Leveraging powerful Python data types
  • Building real-world, enterprise-centric Python applications
  • Working with dates, times, and calendars
  • Writing strong code using exception handling.


An Overview of Python

•   What is Python?
•   Overview of Python
•   Python Timeline
•   Advantages/Disadvantages of Python
•   Getting help with pydoc

The Python Environment

•   Starting Python
•   Using the interpreter
•   Running a Python script
•   Python scripts on Unix/Windows
•   Editors and IDEs

Getting Started

•   Using variables
•   Built-in functions
•   Strings
•   Numbers
•   Converting types
•   Writing to the screen
•   Command line parameters

Flow Control

•   About flow control
•   White space
•   Conditional expressions
•   Relational and Boolean operators
•   While loops
•   Alternate loop exits


•   About sequences
•   Lists and list methods
•   Tuples
•   Indexing and slicing
•   Iterating through a sequence
•   Sequence functions, keywords, and operators
•   List comprehensions
•   Generator Expressions
•   Nested sequences

Working with files

•   File overview
•   Opening a text file
•   Reading a text file
•   Writing to a text file
•   Reading and writing raw (binary) data
•   Converting binary data with struct

Dictionaries and Sets

•   About dictionaries
•   Creating dictionaries
•   Iterating through a dictionary
•   About sets
•   Creating sets
•   Working with sets


•   Defining functions
•   Parameters
•   Global and local scope
•   Nested functions
•   Returning values


•   The sorted() function
•   Alternate keys
•   Lambda functions
•   Sorting collections
•   Using operator.itemgetter()
•   Reverse sorting

• The sorted() function • Alternate keys • Lambda functions • Sorting collections • Using operator.itemgetter() • Reverse sorting

•   Syntax errors
•   Exceptions
•   Using try/catch/else/finally
•   Handling multiple exceptions
•   Ignoring exceptions

Modules and Packages

•   The import statement
•   Module search path
•   Creating Modules
•   Using packages
•   Function and Module aliases


•   About o-o programming
•   Defining classes
•   Constructors
•   Methods
•   Instance data
•   Properties
•   Class methods and data

Regular Expressions

•   RE syntax overview
•   RE Objects
•   Searching and matching
•   Compilation flags
•   Groups and special groups
•   Replacing text
•   Splitting strings

The standard library

•   The sys module
•   Launching external programs
•   Math functions
•   Random numbers
•   The string module
•   Reading CSV data

Dates and times

•   Working with dates and times
•   Translating timestamps
•   Parsing dates from text
•   Formatting dates
•   Calendar data

Working with the file system

•   Paths, directories, and filenames
•   Checking for existence
•   Permissions and other file attributes
•   Walking directory trees
•   Creating filters with fileinput
•   Using shutil for file operations

Network services

•   Grabbing web content
•   Sending email

RESTful Services

•   REST Overview
•   Essential RESTful services with Flask
•   Consuming RESTful services
•   Overview of Reactive Programming with RxPY

Programmatic SSH

•   SSH, SCP and SFTP Overview
•   Essential Paramiko
•   Maintaining multiple clients

DevOps and GitPython

•   DevOps Overview
•   Git Overview
•   Programmatic Git with GitPython

This course does not have any sections.

More Courses by this Instructor