How to resize encrypted LVM


I have encrypted TW installed on 1TB SSD.

nvme0n1                                                259:0    0 931.5G  0 disk  
├─nvme0n1p1                                            259:1    0   512M  0 part  /boot/efi
└─nvme0n1p2                                            259:2    0   931G  0 part  
  └─cr_nvme-eui.e8238fa6bf530001001b448b4bf7cf83-part2 254:0    0   931G  0 crypt 
    ├─system-swap                                      254:1    0     2G  0 lvm   [SWAP]
    └─system-root                                      254:2    0   929G  0 lvm   /var
/dev/mapper/system-root: UUID="1ac05f60-24d3-4df4-a60d-5d5f90f1a5f2" UUID_SUB="4507c579-7535-40bc-9311-cb3a2d4c924b" BLOCK_SIZE="4096" TYPE="btrfs"

I want to shrink system-root to 200GB. I cant find GUI app that can do that.
I have found some cmd tutorials but nothing with btrfs that I trust.

cryptsetup luksOpen /dev/nvme0n1p2 cryptdisk
vgscan --mknodes
vgchange -ay

I have booted live gparted, decrypted disk and activated LVM.
What to do next from cmd or is there app with GUI that can do that?

Resize filesystem below 200GB to have some safety margin; resize LV to the desired size; resize filesystem to fill new size. All that happens online. Something like

btrfs filesytem resize -250G /
lvresize -L -200G system/root
btrfs filesystem resize max /

There is no need for it, everything works online on running system. You can only resize mounted btrfs, so you need to mount and adjust commands for your mountpoint.

I have to be sure I will not mess up, I don’t have backup of OS…
Please can you double check am I doing it correctly.

system-root is Used 90GB of 838GB Available.

df -h
Filesystem               Size  Used Avail Use% Mounted on
devtmpfs                 4.0M  8.0K  4.0M   1% /dev
tmpfs                    7.5G  1.4M  7.5G   1% /dev/shm
tmpfs                    3.0G  2.7M  3.0G   1% /run
/dev/mapper/system-root  930G   90G  838G  10% /
tmpfs                    7.5G   40K  7.5G   1% /tmp
/dev/mapper/system-root  930G   90G  838G  10% /.snapshots
/dev/mapper/system-root  930G   90G  838G  10% /boot/grub2/i386-pc
/dev/mapper/system-root  930G   90G  838G  10% /boot/grub2/x86_64-efi
/dev/mapper/system-root  930G   90G  838G  10% /opt
/dev/mapper/system-root  930G   90G  838G  10% /home
/dev/mapper/system-root  930G   90G  838G  10% /root
/dev/mapper/system-root  930G   90G  838G  10% /srv
/dev/mapper/system-root  930G   90G  838G  10% /usr/local
/dev/mapper/system-root  930G   90G  838G  10% /var
/dev/nvme0n1p1           511M  5.3M  506M   2% /boot/efi

I want to shrink filesystem to 180GB

btrfs filesystem resize -658G /

Shrinking LVM2 so it will be size 235GB

lvresize -L -603G /dev/mapper/system-root

Expanding btrfs to fill new LVM

btrfs filesystem resize max /

When the plus + or minus - prefix is used, the value is not an absolute size, but is relative and added or subtracted from the current size. So what you are doing is setting system-root to 729GB.