View basic Linux system information
View basic Linux system information
#! /Bin/bash
# The scripts will return the system infomation
# Return hostname and version infomation // return host name and System version Information
Echo-e "\ e [31; 43 m /// hostname infomation ***** \ e [0 m"
Hostname
Uname-r
Cat/proc/version
Echo ""
# File system disk space usage // available space of the File system disk
Echo-e "\ e [31; 43 m ***** File System Disk Space usage INFOMATION ***** \ e [0 m"
Df-h
Echo ""
# Idie time system and use of memory // memory in idle and used system
Echo-e "\ e [31; 43 m ***** Idie system And use of memory infomation ***** \ e [0 m"
Free
Echo ""
# System start time // system start time
Echo-e "\ e [31; 43 m ***** System start time INFOMATION ***** \ e [0 m"
Uptime
Echo ""
# User logged on // Login User
Echo-e "\ e [31; 43 m ****** User logged on INFOMATION ****** \ e [0 m"
Who
Echo ""
# Use memory up to five processes // five processes with the maximum memory usage
Echo-e "\ e [31; 43 m ***** Use memory up to five processes INFOMATION ***** \ e [0 m"
Ps-eo % mem, % cpu, comm -- sort =-% mem | head-n 6
Echo ""
Echo-e "\ e [1; 32mDone. \ e [0 m"
This article permanently updates the link address: