lvreduce 不接受 lv 路径参数

lvreduce 不接受 lv 路径参数

我正在运行 Ubuntu 22.04.1 LTS。卸载逻辑卷并成功运行 e2fsck 后,lvreduce 失败并出现错误

$ sudo lvdisplay /dev/ubuntu-vg/lv-0
  --- Logical volume ---
  LV Path                /dev/ubuntu-vg/lv-0
  LV Name                lv-0
  VG Name                ubuntu-vg
  LV UUID                9rMOP1-SuC6-geGc-k1fR-rTn9-PE2O-Q58g0n
  LV Write Access        read/write
  LV Creation host, time ubuntu-server, 2022-11-27 14:36:00 -0500
  LV Status              available
  # open                 0
  LV Size                <828.46 GiB
  Current LE             212085
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:1
$ sudo umount /dev/ubuntu-vg/lv-0
$ sudo e2fsck -f /dev/ubuntu-vg/lv-0
$ sudo lvreduce -r -L 512 GB /dev/ubuntu-vg//lv-0 
Command does not accept argument: /dev/ubuntu-vg//lv-0.

答案1

删除“512 GB”中的空间后不再出现此错误

$ sudo lvreduce -r -L 512GB /dev/ubuntu-vg/lv-0

相关内容