From 26a0a3eff86cf58ff5971d8f137e8e2ea2e5d22c Mon Sep 17 00:00:00 2001 From: tomit4 Date: Fri, 17 Sep 2021 02:18:11 -0700 Subject: [PATCH] updated linux notes --- linux_notes.txt | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/linux_notes.txt b/linux_notes.txt index c577564b..3521b3dc 100644 --- a/linux_notes.txt +++ b/linux_notes.txt @@ -24,6 +24,19 @@ du -c /directory (displays total disk usage) du -h /directory (displays total disk usage by file/subdirectory in human readable format) du -hc /directory (displays total disk usage and usage by file/subdirectory in human readable format) +To compress/archive and encrypt a file: + +tar czf + +gpg -c + +Enter passphrase, and repeat it. + +To decompress said file: +gpg -d + +tar xzf + To Display top five directories that use the most disk space: du -ahx . | sort -rh | head -5