Mt Xia
We know AIX forward and backward
- AIX
tm - mt
XIA
Bourne Shell Training
Business Continuity
/
Disaster Recovery
/
High Availability
Data Center Automation
/
Audit Assessment
/
Security Assessment
Home
About
BC
DR
HA
Support
Training
Download
You are here:
Home/
Training/
Unix-Bourne-Shell/
Please
Login
or
Register
Current Location
js
Training
Unix-Bourne-Shell
AIX Admin Methodology
Global Consolidation Project
All AIX admins should join
www.aixexpert.com
Join our LinkedIn Group
AIX Advanced Technical Experts
Contract Opportunities
www.LinkedIn.com
Digg this page
Post to del.icio.us
Slashdot it!
LPAR Leasing
Lease an AIX / i5 LPAR
Reduce your costs
www.mtxia.com
Server Leasing
Lease a Server off-site
Reduce your costs
www.mtxia.com
Data Center Automation
Business Continuity and DR
Virtualization/Consolidation
www.mtxia.com
HMC Service
Hardware Management Console
Manage Remote AIX / i5 LPARs
www.siteox.com
Business Web Site Hosting
$3.99 / month includes Tools,
Shopping Cart, Site Builder
www.siteox.com
Disaster Recovery
Small Business Oriented
Off-Site Facilities
www.mtxia.com
IBM pSeries / iSeries
Reduce your Costs
Off-Site Server Hosting
www.mtxia.com
Table of Contents
Please contact or
Mt Xia
for assistance with all your shell programming needs.
UNIX Bourne Shell Programming
I. INTRODUCTION
A. Audience
B. Course Objectives
C. Course Handout Conventions
1. BOURNESHELL OVERVIEW
1.1 What is the BourneShell?
1.2 Making a Bourne Shell Script Executable
1.3 Tracing Mechanisms
Workshop 1
2. USER, SHELL, AND READ-ONLY SHELL VARIABLES
2.1 User Variables.
2.2 Shell Variables.
2.2.1 HOME
2.2.2 IFS
2.2.3 MAIL
2.2.4 MAILPATH
2.2.5 MAILCHECK
2.2.6 PATH
2.2.7 PS1
2.2.8 PS2
2.3 Read-Only User Variables.
2.4 Read-Only Shell Variables.
2.4.1 Name of the Calling Program
2.4.2 Arguments
2.4.3 Shift
2.4.4 Set
2.4.5 expr
Workshop 2.
3. POSITIONAL PARAMETERS
3.1 Reading Input Into a Shell Variable.
3.2 Command Substitution.
3.3 Comments in BourneShell Scripts.
3.4 BourneShell Environment - Exporting Variables.
Workshop 3.
4. CONTROL CONSTRUCTS:
4.1 Types of Tests Used with Control Constructs:.
4.2 Test on Numeric Values.
4.3 Test on Character Strings.
4.4 Test on File Types.
4.5 if then.
4.6 if then else.
4.7 if then elif.
4.8 for.
4.9 while.
4.10 until.
4.11 case.
Workshop 4..
5. COMPILING PROGRAMS IN UNIX.
5.1 "C": Sample Program with a Main and Two Functions in One
5.2 "C": Compiling a Program.
5.3 "C": Renaming the Executable Module.
5.4 "C": Giving a Name to the Output File.
5.5 "C": Producing an Assembly Listing.
5.6 "C": Main and Two Functions in Three Separate Source Files
5.7 "C": Compiling but Not Producing an Executable Module
5.8 FORTRAN: Sample Program a Main and Two Subroutine.
5.9 FORTRAN: Compiling a Program.
5.10 FORTRAN: Renaming the Executable Module.
5.11 FORTRAN: Giving a Name to the Output File.
5.12 FORTRAN: Producing an Assembly Listing.
5.13 FORTRAN: Main and Two Subroutines in Three Separate Source Files
5.14 FORTRAN: Compiling But Not Producing an Executable Module
5.15 FORTRAN: Compiling Object Files to Produce an Executable Module
5.16 COBOL: Sample Program with a Main and Two Subroutines
5.17 COBOL: Compiling a Program.
5.18 COBOL: Running a Program.
Workshop 5.
6. UNIX TOOLS.
6.1 Processes.
6.2 Executing a Command.
6.3 Process Identification.
6.4 grep: A Pattern Matching Filter.
6.4.1 More on Regular Expressions
6.4.2 Closure
6.4.3 Some Nice grep Options
6.4.4 Summary of Regular Expression Characters
6.5 sed: Edit a File to Standard Output.
6.6 awk: A Pattern Matching Programming Language.
6.7 sort: Sort a File.
6.8 What Other Useful UNIX Tools are Available.
6.9 Archiver and Library Maintainer.
6.9.1 ar: Creating an Archive File with Object Modules
6.9.2 ar: Verifying the Contents of the Archive File
6.9.3 ar: Removing Duplicate Object Files
6.9.4 ar: Compiling Main and Archive Files
Workshop 6
7. VAX DCL TO UNIX SHELL SCRIPT CONVERSION.
7.1 Processes.
7.2 Pipes.
7.3 Input, Output, and Error Redirection.
7.4 Command Structure and File Naming Conventions.
7.5 File Management Commands.
7.6 Metacharacters.
7.7 Wildcards: Are They Really Wild?.
7.8 Summary.
Workshop 7.
8. ADVANCED FEATURES OF FTP.
8.1 Initializing FTP on UMAX.
8.2 Multiple File Transfers.
8.3 Auto Login Feature.
8.4 Macros.
8.5 Filename Translation.
8.6 Aborting Transfers.
8.7 More Remote Computer Commands.
Workshop 8.
9. OPTIONAL CHAPTER - KORNSHELL PROGRAMMING.
9.1 KornShell Variables.
9.2 User Defined Variables.
9.3 Values of Variables Between Child and Parent Processes
9.4 ksh: Aliases.
9.5 ksh: Command Line Editing.
9.6 ksh: Interactive Command Line Editing.
9.7 ksh: Functions.
9.8 ksh: The Select Construct.
9.9 ksh: Tracing and Conditional Execution.
Workshop 9
APPENDIX A - sh
APPENDIX B - test
APPENDIX C - expr
APPENDIX D - ftp
APPENDIX E - cc
APPENDIX F - f77
APPENDIX G - lint
APPENDIX H - cb
APPENDIX I - ar
APPENDIX J - time
APPENDIX K - ksh
INDEX
Table of Contents
Introduction
Table of Contents
Chapter 1
Chapter 2a
Chapter 2b
Chapter 3
Chapter 4a
Chapter 4b
Chapter 5a
Chapter 5b
Chapter 6a
Chapter 6b
Chapter 6c
Chapter 7a
Chapter 7b
Chapter 8
Chapter 9a
Chapter 9b
Manual: ar(1)
Manual: cb(1)
Manual: cc(1)
Manual: expr(1)
Manual: f77(1)
Manual: ftp(1)
Manual: ksh(1)
Manual: lint(1)
Manual: sh(1)
Manual: test(1)
Manual: time(1)
LPAR Leasing
Lease an AIX / i5 LPAR
Reduce your costs
www.mtxia.com
Server Leasing
Lease a Server off-site
Reduce your costs
www.mtxia.com
Data Center Automation
Business Continuity and DR
Virtualization/Consolidation
www.mtxia.com
HMC Service
Hardware Management Console
Manage Remote AIX / i5 LPARs
www.siteox.com
Business Web Site Hosting
$3.99 / month includes Tools,
Shopping Cart, Site Builder
www.siteox.com
FREE Domain Registration
included with Web Site Hosting
Tools, Social Networking, Blog
www.siteox.com
Disaster Recovery
Small Business Oriented
Off-Site Facilities
www.mtxia.com
IBM pSeries / iSeries
Reduce your Costs
Off-Site Server Hosting
www.mtxia.com