This repository contains a collection of useful bash scripts for system administration and diagnostics.
A system diagnostic tool that checks the status of critical services and logs the results.
Features:
- Checks status of essential system services (ssh, cron)
- Colorized output for easy identification of issues
- Logs all diagnostics to timestamped log files
Usage:
./system_health_check.sh
Output:
- Console output with color-coded status indicators
- Log file created at
log/system_diagnostic/YYYYMMDD_HHMM_health_check.txt
A utility script that downloads the Linux kernel README file and provides viewing options.
Features:
- Downloads the Linux kernel README from GitHub
- Checks if the file already exists before downloading
- Allows viewing specific portions of the file (beginning or end)
Usage:
./linux_readme_downloader.sh
Interactive prompts:
- Asks if you want to update an existing file
- Asks if you want to view the file after download
- Allows you to specify how many lines to view (positive number for beginning, negative for end)
-
Clone this repository:
git clone https://github.com/yourusername/bash-scripts.git cd bash-scripts
-
Make the scripts executable:
chmod +x system_health_check.sh linux_readme_downloader.sh
-
Run any script:
./system_health_check.sh # or ./linux_readme_downloader.sh
- Log files and downloaded text files are excluded from git using
.gitignore
- The scripts use ANSI color codes for improved readability