From 77896c08b446e8ddb6b5a0c389267d50b8d0b57a Mon Sep 17 00:00:00 2001 From: zeus Date: Wed, 2 Dec 2020 14:00:42 +0100 Subject: [PATCH] biggest entries without other mounts --- oneliners.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/oneliners.sh b/oneliners.sh index 418dec9..b6f84e9 100644 --- a/oneliners.sh +++ b/oneliners.sh @@ -14,3 +14,6 @@ echo $PATH | sed s/\:/\\n/g # check for open ports on target for i in 80 443; do echo -e '\x1dclose\x0d' | telnet google.com $i >/dev/null; echo "$i : $?"; done + +# find biggest directories in a given path without leaving the current filesystem +dir="/var/opt/gitlab"; for i in $(ls $dir); do mountpoint -q $dir/$i || du -shx $dir/$i ; done | sort -rh | head