Bạn là quản trị hệ thống, để công việc tự động hóa hơn thì cần phải biết kỹ năng viết script cho hệ thống, và script shell có thể sử dụng cho nhiều Linux Distro khác nhau.VNLAMP sẽ hướng dẫn và hổ trợ bạn trong suốt khóa học về các script.
Giới Thiệu
Bạn là quản trị hệ thống, để công việc tự động hóa hơn thì cần phải biết kỹ năng viết script cho hệ thống, và script shell có thể sử dụng cho nhiều Linux Distro khác nhau.VNLAMP sẽ hướng dẫn và hổ trợ bạn trong suốt khóa học về các script.
Mục Tiêu Khóa Học
Nắm chắc kiến thức về Bash Shell để có thể tự động hóa hệ thống
Chứng nhận:
Sau khi kết thúc khóa học, học viên tham gia kỳ thi kiểm tra cuối khóa và được nhận chứng nhận hoàn tất khóa học LAMP của Trung tâm.
Xem lịch khai giảng
Nội Dung Khóa Học
Introduction to BASH Command Line Interface (CLI)
Identify BASH installation & key configuration files on RedHat & Debian GNU/Linux distros
.profile/.bash_profile/.bashrc/.bash_history
Identify & use common built-in BASH commands (pwd,cd,set,unset,export,source,etc.)
BASH Command-line Expansion
Brace Expansion
Tilde Expansion
Parameter & variable Expansion
Command Substitution
BASH Reserved words
BASH History identification & configuration
Aliases (ls,du,df,rm,cp)
Backticks - command expansion & execution
BASH Prompt configuration
Command chaining
Error level/Return code (Command Exit Status) identification
Test return 0
Test return 126 - permissions
Test return 127 - command not found
Conditional execution of subsequent commands
Redirection
Standard Input
Direct input from Standard Input
Redirect input from a file
Standard Output
Direct output to Standard Output
Redirect output to a file
Append Standard Output to an existing file
Standard Error
Input/Output (I/O) Redirection
Pipes
Sequential execution via pipes
Quoting & Escaping
single quotes preserves whitespace, double quotes don't
Full-quoting - single quotes - all enclosed values are literal
Partial quoting - double quotes - all enclosed values are literal except "$, , `"
is the escape character used to treat following strings literally
BASH Scripting
Basic Script definition (hello world), permissions modification & execution
Internal BASH variables
Global Variable definition
Function definition
Local Variable definition - function scope
BASH Arrays
Loops
Menu creation using Select
Job control - Foreground/Background processing
Conditionals - If-Then-Else - Testing
Case - Concise Conditional Branching
Positional Parameters
BASH Script Definition
Create BASH script to move multiple files to new names defined by positional parameters
Create script to monitor directory for file changes and report the differences via E-mail to Administrator
Create script to monitor directory size and report threshold encroachment to Administrator via E-mail
Define script to parse logs for keywords and notify the Administrator via E-mail
Create script to monitor network connectivity between hosts and report outages to Admin via E-mail
Define script to monitor process , restart if fails, and E-mail Administrator at defineable limits
Create script to backup sub-directories using Tar & Gzip, define threshold, and SSH file to remote host
Log the output of BASH scripts to a Syslog-like format