在线调节文件系统大小中遇到的问题

房东的猫 提交于 2020-02-26 03:33:13
resize2fs /dev/mapper/P05TRF1vg-vol_controlm
resize2fs 1.43-WIP (20-Jun-2013)
Filesystem at /dev/mapper/P05TRF1vg-vol_controlm is mounted on /controlM; on-line resizing required
old_desc_blocks = 1, new_desc_blocks = 1
resize2fs: Permission denied to resize filesystem

The Solution A file system inconsistency blocked the online resize of the disk, which can be observed in the messages as logged below:

--message-- kernel: EXT4-fs warning (device dm-1): ext4_resize_begin:32: There are errors in the filesystem, so online resizing is not allowed --dmesg-- EXT4-fs (dm-4): warning: mounting fs with errors, running e2fsck is recommended Since the file system is in an inconsistent state, a file system check is required for this affected file system, so online resizing is not possible and the file system has to be unmounted.

  1. Umount the file system.

umount /controlM

  1. Perform a file system check.

e2fsck -y /dev/mapper/P05TRF1vg-vol_controlm

  1. Resize the file system.

resize2fs /dev/mapper/P05TRF1vg-vol_controlm

  1. Remount the file system:

mount /dev/mapper/P05TRF1vg-vol_controlm /controlM

  1. Check if the file system has been resized.

df -h

Note: You can refer “man e2fsck” if you want to know more about this command.

man e2fsck

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!