Linux Shell Scripting

The GL375 is designed to provide the skills necessary to automate tasks on a Unix or Linux system. Systems Administrators and Developers alike can avoid errors, save time and money by replacing repetitive work patterns with shell scripts. Care has been taken to present the GL375 in a format that benefits all students, with or without previous programming experience. Guru Labs believes that the best way to learn shell scripting is writing shell scripts. For this reason, lab time is emphasized. Early labs present the scripting process step by step, while later labs are presented in a challenge format. While official solutions to each lab task are provided, students are encouraged to create their own before examining the solution. In this way, more experienced students are challenged without overwhelming the less experienced.

Prerequisites:

Solid understanding of Unix-based systems and proficiency on the Unix or Linux command line.

Supported Distributions:

  • Red Hat Enterprise Linux 7
  • SUSE Linux Enterprise 12
  1. INTRODUCTION TO THE SHELL
    1. Shell Script Strengths and Weaknesses
    2. Shells
    3. Switching User Contexts
    4. Example Shell Script
    5. Shell and Environment Variables
    6. Key Environment Variables
    7. General Quoting Rules
    8. Nesting Commands
    9. Help from Commands and Documentation
    10. Getting Help Within the Graphical Desktop
    11. Getting Help with man & info

    LAB TASKS

    1. Shell Variables
    2. Shell Meta-Characters
    3. Command Substitution
  2. SHELL SCRIPTING BASICS
    1. Positional Parameters
    2. Input & Output
    3. printf
    4. alias
    5. Functions
    6. Colors in Scripts
    7. Custom Bash Prompts

    LAB TASKS

    1. Aliases
    2. Bash Login Scripts
    3. Create “userinfo” and “sysinfo” functions
  3. WORKING WITH FILES
    1. Communication Channels
    2. File Redirection
    3. Piping Commands Together
    4. Doing Math
    5. Filesystem Structures
    6. Determining Disk Usage With df and du
    7. cron
    8. The crontab Command
    9. crontab Format
    10. /etc/cron.*/ Directories
    11. Sending Email with mailx

    LAB TASKS

    1. Disk and Filesystem Usage
    2. Connecting Commands
  4. REGULAR EXPRESSIONS
    1. Searching Inside Files
    2. Regular Expression Overview
    3. Regular Expressions
    4. RE Character Classes
    5. RE Quantifiers
    6. RE Parenthesis
    7. The Streaming Editor

    LAB TASKS

    1. Pattern Matching with Regular Expressions
    2. Extended Regular Expressions
    3. Using Regular Expressions With sed
  5. BRANCHING AND LOOPING
    1. Exit Status
    2. Comparisons with test
    3. Conditional Statements
    4. Flow Control: case
    5. Flow Control: while and until Loops
    6. The for Loop
    7. Flow Control: select

    LAB TASKS

    1. Reporting User Statistics
    2. Monitoring Filesystem Usage
  6. DATA MUNGING
    1. Text Processing with Awk
    2. Text Sorting
    3. Duplicate Removal Utility
    4. Extracting Columns of Text

    LAB TASKS

    1. Create “rmhost” function
    2. Create “showenv” function
    3. Parsing Mail Server Logs
    4. Fixing Incorrect Files
  7. SECURITY, WHITESPACE AND OTHER GOTCHAS
    1. Gotchas: Maximum Command Length
    2. Gotcha: Whitespace in for Loops
    3. Reading Files with while
    4. Gotcha: $IFS
    5. Gotcha: Printing in .bashrc
    6. Gotcha: Aliases

    LAB TASKS

    1. Renaming MP3 Files
    2. Split and Display $PATH
    3. A tar-based Backup
Pradžios data Trukmė, d. Kurso pavadinimas Kaina, € Statusas
2024-04-25 5 Linux Fundamentals € 1,100 Organizuojamas
Užklausti 5 CompTIA Linux+ € 1,100 Organizuojamas
Užklausti 5 Enterprise Linux System Administration € 1,500 Organizuojamas
Užklausti 5 Enterprise Linux Networking Services € 1,500 Organizuojamas
Užklausti 5 Linux Troubleshooting € 1,500 Organizuojamas
Užklausti 5 Enterprise Linux Security Administration € 1,500 Organizuojamas
Užklausti 2 Linux Shell Scripting € 1,100 Organizuojamas
Užklausti 3 Linux Command Line Skills € 1,300 Organizuojamas