🖥️resize2fs

➡️This is a command-line reference manual for commands and command combinations that you don’t use often enough to remember it. This cheatsheet explains the resize2fs command with important options and switches using examples.

▁ ▂ ▃ ▄ ꧁ 🔴☠ COMMANDLINE-KUNGFU WITH CHEATSHEETS ☠🔴꧂▅ ▃ ▂ ▁

#  ██████╗ ███████╗███████╗██╗███████╗███████╗██████╗ ███████╗███████╗
#  ██╔══██╗██╔════╝██╔════╝██║╚══███╔╝██╔════╝╚════██╗██╔════╝██╔════╝
#  ██████╔╝█████╗  ███████╗██║  ███╔╝ █████╗   █████╔╝█████╗  ███████╗
#  ██╔══██╗██╔══╝  ╚════██║██║ ███╔╝  ██╔══╝  ██╔═══╝ ██╔══╝  ╚════██║
#  ██║  ██║███████╗███████║██║███████╗███████╗███████╗██║     ███████║
#  ╚═╝  ╚═╝╚══════╝╚══════╝╚═╝╚══════╝╚══════╝╚══════╝╚═╝     ╚══════╝

# resize2fs

# ext2/ext3/ext4 file system resizer

# resize filesystem up to the block device size
# make e2fsck /dev/xvdb1 before
# filesystem must be not mounted for ext2
resize2fs /dev/xvdb1

# shrink filesystem (20G is new size)
resize2fs /dev/xvdb1 20G
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░

  █║▌│║█║▌★ KALI ★ PARROT ★ DEBIAN 🔴 PENTESTING ★ HACKING ★ █║▌│║█║▌

              ██╗ ██╗ ██████╗  ██████╗ ██╗  ██╗███████╗██████╗
             ████████╗██╔══██╗██╔═══██╗╚██╗██╔╝██╔════╝██╔══██╗
             ╚██╔═██╔╝██║  ██║██║   ██║ ╚███╔╝ █████╗  ██║  ██║
             ████████╗██║  ██║██║   ██║ ██╔██╗ ██╔══╝  ██║  ██║
             ╚██╔═██╔╝██████╔╝╚██████╔╝██╔╝ ██╗███████╗██████╔╝
              ╚═╝ ╚═╝ ╚═════╝  ╚═════╝ ╚═╝  ╚═╝╚══════╝╚═════╝

               █║▌│║█║▌ WITH COMMANDLINE-KUNGFU POWER █║▌│║█║▌

░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░