Duration: 3 days | Price: $1495 | Dates: Choose a City View All Cities -or- AL - Huntsville
AR - Little Rock
AZ - Phoenix
AZ - Tucson
CA - Bakersfield
CA - Fresno
CA - Irvine
CA - Los Angeles
CA - Modesto
CA - Oakland
CA - Riverside
CA - Sacramento
CA - San Diego
CA - San Francisco
CA - San Jose
CA - Santa Clarita
CA - Santa Monica
CA - Temecula
CO - Denver
CT - Hartford
CT - New Haven
CT - Stamford
DC - Washington
FL - Fort Lauderdale
FL - Jacksonville
FL - Miami
FL - Orlando
FL - Pensacola
FL - Sarasota
FL - Tampa
FL - West Palm Beach
GA - Atlanta
GA - Savannah
IA - Cedar Rapids
IA - Des Moines
ID - Boise
IL - Chicago
IL - Schaumburg
IL - Springfield
IN - Indianapolis
KY - Louisville
LA - Shreveport
MA - Boston
MA - Chelmsford
MA - Quincy
MA - Springfield
MA - Waltham
MA - Woburn
MA - Worcester
MD - Baltimore
MD - Columbia
MI - Detroit
MI - Lansing
MN - Minneapolis
MO - Kansas City
MO - Springfield
MO - St. Charles
NC - Charlotte
NC - Raleigh-Durham
NC - Winston-Salem
NE - Omaha
NH - Manchester
NH - Nashua
NJ - Jersey City
NJ - Newark
NJ - Princeton
NM - Albuquerque
NM - Las Cruces
NV - Las Vegas
NY - Albany
NY - Binghamton
NY - Buffalo
NY - Ithaca
NY - Manhattan
NY - Rochester
NY - Syracuse
NY - Watertown
OH - Cincinnati
OH - Cleveland
OH - Columbus
OH - Dayton
OK - Oklahoma City
OK - Tulsa
OR - Portland
PA - Harrisburg
PA - Philadelphia
PA - Pittsburgh
RI - Providence
SC - Charleston
TN - Memphis
TN - Nashville
TX - Austin
TX - Corpus Christi
TX - Dallas
TX - El Paso
TX - Fort Worth
TX - Houston
TX - San Antonio
UT - Salt Lake City
VA - Alexandria
VA - Fairfax
VA - Norfolk
VA - Richmond
VA - Williamsburg
WA - Seattle
WA - Spokane
WI - Milwaukee
Description: This hands on Korn Shell scripting course provides a comprehensive introduction to writing Korn shell scripts. Besides covering fundamental syntax for program flow control, variable assignment and substitution, I/O control, and mathematical expressions, it emphasizes the powerful features that are unique to this shell, including built-in string operators, variable typesetting/conversion, functions, and coprocess communication and control. The creative use of standard UNIX utilities within scripts to solve problems is stressed throughout. The course is designed for the administrators and programmers who are developing, testing, or integrating software on UNIX, as well as for advanced UNIX users.
Prerequisites: Familiarity with UNIX file system and commands
Overview of Topics Covered:
Introduction
Shells: Bourne, Korn, C, bash
Korn Shell Environment
Startup Scripts (.profile, .kshrc)
Using ENV for automatic environment tailoring
Korn Shell Command Syntax
Commands
Options
Manipulating Input and Output
Aliases (alias, unalias)
How the Shell Finds Commands
Command History and Editing
Variables
Assigning Values to Variables
set and Special Variables
unset
Built-in Variables Known to Login Shell
The Environment- Exporting Variables
The Korn Shell as a Programming
Language
Data Types (typeset)
Formatting
Base Conversion
Read Only and Other Special Attributes
Input/Output
Conditional Logic and Loops
Functions
Tests
Input/Output
Basic I/O Features
String and Field Processing
Streams and pipes (exec)
Terminal Information (COLUMNS, LINES, TERM)
stty
Shell Scripts
Creating Scripts
Executing Scripts
Passing Arguments to Scripts
Built-in Variables Known to Scripts
Setting Variables with read
Special Characters
Exiting with exit
Debugging
String Manipulation
String Comparison
String Relations
Concatenation
Substring Manipulations
Wildcards and Pattern Matching
Conditional Branching
If/Then
else/elif
Statement blocks
case Statement
Loops (for, while, until)
Simple Menus (select)
Math Operators and Functions
Dealing with Floating Point Numbers
Arrays
Declaring Arrays
Setting and Retrieving Values
Command Line Arguments
Positional Parameters
Manipulating Positional Parameters (set, sort, shift)
Analyzing Switches with getopts
Options Reserved Variables (OPTARG, OPTIND, IFS)
Manipulating Files within
Scripts
File Operations
Testing Files and Directories
Changing Protections
Overview of File Manipulation
Utilities
Input/Output Redirection
Editing a File from a Script
Scripting with ed or vi
UNIX Utilities to Manipulate Files
Regular Expressions
grep and egrep
The Stream Editor sed
sort
awk
Other Text File Utilities
Functions
Advantages of Functions
Writing Functions
Calling Functions
Functions Arguments
Returning Values
Local and Global Variables
Predefined Functions
Exporting Functions
Autoloading Functions
Returning a Value from a Function
Scope of Functions
Examples of Useful Functions
Session Control
Keyboard Suspend Function
Foreground and Background Jobs (bg, fg, %, jobs, wait, nohup, nice)
Signals (kill, trap)
Coprocesses and Pipes
Error Processing (ERRNO, $?)
Reserved Variables
Example Uses of Scripts
Prototyping
Daily Backup
File Selection
Installation Scripts
Add a User
Change all File Extensions
Prompt for Input
Accounting
Combining Shell Scripts
and Compiled Languages
Advantages and Disadvantages of the Korn Shell
Function Libraries
Scheduling Execution
sleep
date
cron and crontab
Using UNIX Utilities to
Talk to Other Users
who, mail, reply, talk, lpr
UNIX Utilities to Report
System Status