bash-3.2$ cat echoscript.sh
#!/bin/sh
# This script will print useful information about the current machine.
# It will print the machine name, model type, specific processor
# information, and the current number of processes running.
echo
echo “The name of the machine is c”
uname -n # uname -n gives the hostname
echo
echo “The machine platform type is c”
uname -i # uname -i gives the hardware platform
echo
echo “Specific processor information for this machine is:”
psrinfo -v
echo
echo “Currently the total number of processes ”
echo ” running on this machine is c”
ps -ef | tail +2 | wc -l # wc -l gives number of lines
bash-3.2$ ./echoscript.sh
The name of the machine is solaris23
The machine platform type is i86pc
Specific processor information for this machine is:
./echoscript.sh: psrinfo: not found
Currently the total number of processes
running on this machine is 64 From: http://sitestree.com/?p=12223
Categories:Root
Tags:
Post Data:2018-05-03 23:45:10
Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada