Last Update: Feb 25, 2024

Essential practical guide for Linux Bash scripting

  • Free

About Course

In this course you learn how to do Linux bash scripting. Specifically, data manipulation utilities and shell syntax for synthesizing command pipelines are emphasized. Bourne shell, Bash shell and Korn shell programming techniques are introduced so students will be able to read and modify existing shell scripts as well as create their own.

Learning Objectives

You will learn:

  • Communicating over the network
  • Using telnet commands
  • Remote access with password authentication
  • How to write and run shell scripts
  • Using conditional constructs to control script execution
  • Manipulating strings
  • Command-line processing
  • Using regular expressions
  • String processing utilities: sed,grep and awk
  • Writing functions
  • Working with UNIX I/O streams

Topics and Subtopics

The following outline is covered in this course:

1- Basic User Commands

  • Logging In and Logging Out
  • Command Line Editing
  • Navigating the File System
  • Viewing and Copying Files
  • Controlling the Terminal
  • Sending and Receiving Mail

2- Introduction to Shells and Fish Bash Scripting

  • Shell Functions
  • I/O Redirection and Pipes
  • Command Separation and Grouping
  • Background Execution
  • Filename Expansion
  • Shell Variables
  • Command Substitution
  • Quoting and Escaping Metacharacters
  • Fish Shell Features
  • Command Execution
  • Startup Files

3- Shell Programming

  • Shell Script Features and Capabilities
  • Creating and Running a Script
  • Working With Variables
  • Environment Variables
  • Working With Data Types
  • Formatting
  • Base Conversion
  • Setting Special Attributes
  • Input/Output Techniques
  • Conditional Constructs
  • if/then
  • else/elif
  • Looping Constructs
  • for, while, until
  • Math Operators

4- Advanced Shell Features

  • Manipulating Strings
  • Writing and Calling Functions
  • Controlling Process Priorities
  • Interpreting Command Line Arguments
  • Making Scripts Interactive
  • Special Shell Variables
  • Advanced I/O with Streams
  • Improving Performance of Scripts

5- Text Manipulation Utilities

  • Editing a File from a Script
  • Scripting with ed or sed
  • UNIX and Linux Utilities to Manipulate Files
  • Regular Expressions
  • grep and egrep
  • The Stream Editor sed
  • Sorting in Scripts
  • Generating Reports with awk
  • Splitting Large Files
  • Counting Words, Lines, and Characters
  • Transforming File Contents
  • Extracting Text Strings

6- Networking Commands

  • UNIX Network Applications
  • Remote Execution Commands
  • Remote Activity Reporting
  • Communicating with Remote Users
  • Internet Applications
  • ftp, tftp, telnet
  • Remote Access Control Mechanisms
  • Using the Secure Shell(ssh)

Project 1- Bash Scripting with 12 Examples

  1. Using While Loop
  2. Using For Loop
  3. Get User Input
  4. Using if statement
  5. Using if statement with AND logic
  6. Using if statement with OR logic
  7. Using else if statement
  8. Using Case Statement
  9. Create Function
  10. Create function with Parameters
  11. Pass Return Value from Function
  12. Get Parse Current Date

Project 2- Grep Command with 10 Examples

  • Ex 1: Find a Single Charterer in a Text File
  • Ex 2: Find a Single string in a Text File
  • Ex 3: Find a Single Special
  • Charterer in a Text File
  • Ex 4: Matching Lines Beginning with Certain Text
  • Ex 5: Matching Lines Ending with Certain Text
  • Ex 6: Matching Lines of a Certain Length
  • Ex 7: Matching Lines That Contain Any of Some Regexps
  • Ex 8: Matching Lines That Contain All of Some Regexps
  • Ex 9: Matching Lines That Only Contain Certain Characters
  • Ex 10: Finding Phrases
  • Regardless of Spacing

Homework- Bash Scripting Q/A


Good knowledge of Linux commands is required.

Related Courses

Complete Training Bundle

If you are serious about becoming a pro system admin or cloud specialist, you should enroll in our System Admin- Complete Training Bundle. This bundle covers all essential and practical topics related to system administration. For $290 monthly subscription, you can have access to 300+ hours of hands-on project-based training covering all courses related to system administration like Linux, SQL, No-SQL, or Graph database development, bash scripting, Docker, Kubernetes and many more. Click here to learn more.

Private Tutoring Classes

To take skills you learn from this course to the next level, taking the following tutoring classes are highly recommended. It is also a great opportunity to discuss your questions and problems related to this course with an experienced instructor:

Linux Live Classes

Red Hat Certifications

What Is Next?

After finishing this course, you can enroll in any of following classes:

Recommended Free Courses

If you are new to the IT or programming, we suggest the following free courses:

Show More

What Will You Learn?

  • Learn new things
  • Revamp your career
  • Target IT jobs
  • Sharpen your skills
Free access this course


  • A laptop or PC
  • Good Internet
  • Routine Study
  • Regular Join Class