diff --git a/.monitoring.sh.swp b/.monitoring.sh.swp index 4ecc7c5..911ddef 100644 Binary files a/.monitoring.sh.swp and b/.monitoring.sh.swp differ diff --git a/monitoring.sh b/monitoring.sh index 1b9fae5..169bdf0 100755 --- a/monitoring.sh +++ b/monitoring.sh @@ -6,7 +6,7 @@ # By: gbaconni@student.42lausanne.ch +#+ +:+ +#+ # # +#+#+#+#+#+ +#+ # # Created: 2021/11/04 12:36:53 by gbaconni #+# #+# # -# Updated: 2021/11/04 16:24:26 by gbaconni ### lausanne.ch # +# Updated: 2021/11/04 16:32:24 by gbaconni ### lausanne.ch # # # # **************************************************************************** # @@ -41,7 +41,12 @@ ft_load () ft_lastboot () { - echo "#Last boot: "$(who -a | grep -o '....-..-.. ..:..') + echo "#Last boot: "$(who -b | grep -o '....-..-.. ..:..') +} + +ft_lvmused () +{ + echo "#LVM use: "$(if vgdisplay | grep -q '[1-9]'; then echo "yes"; else echo "no"; fi) } ft_update () @@ -69,6 +74,7 @@ main () ft_disk ft_load ft_lastboot + ft_lvmused ft_update return 0 }