Korn Shell Scripting

Korn Shell Scripting


The intended audience for this class includes experienced programmers and support staff, who have some experience of UNIX based systems, and who will be implementing further applications and systems.

The course is suitable for delegates using all versions of UNIX (e.g., AIX, Solaris, HPUX, Irix, Linux etc...).


Delegates should have a good basic understanding of UNIX, which can be gained through our UNIX & Linux Essentials course, and at least three months practical experience.

Knowledge of a standard UNIX editor will be required.


3 days. Hands on.

This course is available on site only. Please call for details.

Course Objectives

The course is highly interactive and consists of theory with plenty of hands on practical content.

This course will provide programmers and UNIX Support Staff with the skills necessary to construct extensive korn shell scripts. By the end of the course, delegates will be confident in creating and maintaining complex korn shell scripts.

Course Content

Review of Unix Concepts and Commands
Major Components of UNIX
The filesystem
Listing Directories
Creating Files
Displaying Files
Moving Around Directories
Escaping Shell Processing
Searching for a Pattern
Finding Files
User Security
Other Useful Commands

The Shell Environment
Shell Environment
System Variables
Shell Variables
Assigning Variables
Displaying Variable Values
Exporting variables
Shell Interpretation
Using Quotes in the Shell
The Back Quote
The Single Quote
The Double Quotes
The Backslash
Special Escape Characters

Executing Applications
Simple Shell Scripts
Shell Scripts
Executing Shell Scripts
Passing Arguments To A Program
Positional Parameters
Special Shell Parameters
The Shift Command
Read Command
Expr Command

Miscellaneous Utilities
Cut and Paste
Comparing Files
Head and tail
Touching files
Grouping Commands
Here Documents
Shell Functions

Controlling Program Flow
Conditional Processing
Logical Constructs
Basic Structured Conditionals
Nesting Structured Condition
ELIF Statement
Test String Operators
Test Integer Operators
Test File Operators
Test Logical Operators
Multi-Way Branching (Case)
The For Command
For Statement Without Word List
The While Command
The Until Command
The True Command
The False Command
The Break Command
The Continue Command

Additional Programming Topics
Shell Script Comments
The Exit Command
The Sleep Command
The Wait Command
The Set Command
The Unset Command
Special Variable Constructs
The Null Command
Signals used by Shell Procedures
Interrupt handling
Execution Trace
Verbose Trace
Combining Execution and Verbose Traces
Timing Command
Programming Hints
Creating Efficient Shell Procedures

The Stream Editor
The Stream Editor
Searching and Replacing Text
Deleting lines
Printing Lines
Edit Files

The Awk Utility
The awk utility
Arithmetic operators
Program Control
Print Formatting

Practical Application of Shell Scripts
Program Maintenance
System Monitoring

Virtual Courses

ALL of our courses can be delivered virtually. And our Bath public schedule of courses are now available as live virtual sessions, using the popular Zoom Virtual Classroom and remote labs. Delegates can test their access at: www.zoom.us/test

On-Site Courses

Can't attend one of our public classes? Booking for multiple people?

All our courses are available on your site! Delivered for your staff, at your premises.

Contact us to find out more...