second commit

This commit is contained in:
pvincent
2024-02-21 23:32:34 +04:00
parent 9a4551ca3a
commit 7cdc45397d
82 changed files with 7172 additions and 6 deletions
+15
View File
@@ -0,0 +1,15 @@
#!/bin/bash
FQDN=$(hostname --fqdn)
IP_ADDRESS=$(hostname -I | cut -d ' ' -f1)
DISTRO=$(lsb_release -d | cut -f2)
KERNEL=$(uname -srm)
UPTIME=$(uptime | awk -F'( |,|:)+' '{if ($7=="min") m=$6; else {if ($7~/^day/) {d=$6;h=$8;m=$9} else {h=$6;m=$7}}} {print d+0,"days"}')
LOAD=$(cat /proc/loadavg)
echo "FQDN : $FQDN"
echo "UPTIME: $UPTIME"
echo "IPADDR: $IP_ADDRESS"
echo "DISTRO: $DISTRO"
echo "KERNEL: $KERNEL"
echo "LOAD : $LOAD"