首页 > 代码库 > xfs_check和xfs_repair
xfs_check和xfs_repair
[root@atyu30 ~]# mount /dev/sdc1 /data/data029
mount: 结构需要清理
[root@atyu30
~]# df -h
文件系统 容量 已用 可用 已用% 挂载点
/dev/sdd3 48G
6.2G 39G 14% /
/dev/sdd2 216G 201M 204G 1%
/opt
/dev/sdd1 92M 12M 75M 14%
/boot
tmpfs 2.0G 0 2.0G 0%
/dev/shm
/dev/sdb1 1.9T 66G 1.8T 4%
/data/data028
用xfs_check检查xfs文件系统
[root@atyu30 ~]# xfs_check
/dev/sda1
ERROR: The filesystem has valuable metadata changes in a log which
needs to
be replayed. Mount the filesystem to replay the log, and unmount it
before
re-running xfs_check. If you are unable to mount the filesystem, then
use
the xfs_repair -L option to destroy the log and attempt a repair.
Note
that destroying the log may cause corruption -- please attempt a mount
of the
filesystem before doing this.
清除xfs文件中日志
[root@atyu30 ~]# xfs_repair -L /dev/sda1
[root@atyu30 ~]# mount /dev/sda1 /data/data027