Chapter 15. Linux Shells and Scripting

Terms you’ll need to understand:

Alias

Environment

Exporting

Loop

Options

Quoting

Variable

Techniques you’ll need to master:

Declaring a variable

Exporting a variable

Writing and customizing scripts

Setting and removing shell options

Creating and listing functions

Manipulating SUID rights

Writing Scripts

Thankfully, you don’t have to be much of a programmer or script-writer to fulfill the objectives of the LPIC Level 1, and the author is a prime example of that subset of quite competent sysadmins who are not programmers, nor does he feel that you have to be one. The questions you’ll be answering on the exam will be about simple scripting—little tasks that make life easier.

Writing a Simple Script

The easiest way ...

Get LPIC I Exam Cram™ 2: Linux Professional Institute Certification Exams 101 and 102 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.