逻辑卷的缩小

 时间:2024-10-18 08:11:11

1、检查文件系统的完整性:[root@linuxprobe ~]# e2fsck -f /dev/storage/voe2fsck 1.42.9 (28-Dec-2013)Pass 1: Checking inodes, blocks, and sizesPass 2: Checking directory structurePass 3: Checking directory connectivityPass 4: Checking reference countsPass 5: Checking group summary information/dev/storage/vo: 11/74000 files (0.0% non-contiguous), 15507/299008 blocks

2、把LV逻辑卷的容量减小到120M:[root@linu垓矗梅吒xprobe ~]# resize2fs /dev/storage/vo 120Mresiz髫潋啜缅e2fs 1.42.9 (28-Dec-2013)Resizing the filesystem on /dev/storage/vo to 122880 (1k) blocks.The filesystem on /dev/storage/vo is now 122880 blocks long.[root@linuxprobe ~]# lvreduce -L 120M /dev/storage/voWARNING: Reducing active logical volume to 120.00 MiBTHIS MAY DESTROY YOUR DATA (filesystem etc.)Do you really want to reduce vo? [y/n]: yReducing logical volume vo to 120.00 MiBLogical volume vo successfully resized

3、把文件系统重新挂载并查看系统状态:[root@linuxprobe ~]# mount -a[root@linuxprobe ~]# df -hFilesystem Size Used Avail Use% Mounted on/dev/mapper/rhel-root 18G 3.0G 15G 17% /devtmpfs 985M 0 985M 0% /devtmpfs 994M 80K 994M 1% /dev/shmtmpfs 994M 8.8M 986M 1% /runtmpfs 994M 0 994M 0% /sys/fs/cgroup/dev/sr0 3.5G 3.5G 0 100% /media/cdrom/dev/sda1 497M 119M 379M 24% /boot/dev/mapper/storage-vo 113M 1.6M 103M 2% /linuxprobe

  • Ubuntu 14.04 怎样安装 Nvidia 私有显卡驱动
  • 从Ubuntu软件商店安装不同版本的snap格式软件
  • IPv6的安装方法
  • 怎样用cmd打开文件
  • visual studio code怎么安装插件
  • 热门搜索
    感恩的心手抄报内容 文明从我做起手抄报 电子版手抄报怎么做 关于环境保护的手抄报 关于春节的语文手抄报 知法守法手抄报 关于电脑的手抄报 说普通话手抄报内容 生活处处有语文手抄报 关于春天的手抄报花边