天天看點

df -h指令卡死

執行df -h指令無傳回資料

<1>

發現是之前挂載的windows目錄失去連接配接(windows電腦重新開機關機等原因)

//10.1.23.75/123 on /mnt type cifs (rw,relatime,vers=1.0,cache=strict,username=Everyone,.......)
           

[[email protected] ~]# umount -f //10.1.23.75/123 #解除安裝這個網絡挂載

查了百度一下。fuser 指令也是解決辦法。并且fuser可以查詢是哪個網絡連接配接導緻的df -h卡死。但是此處并未用到

<2>

centos7 df -h command卡死無響應

使用starce檢視df -h 執行狀态

[[email protected] ~]# strace df -h
execve("/usr/bin/df", ["df", "-h"], [/* 34 vars */]) = 0
brk(NULL)                               = 0x25cd000
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f59032e0000
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
open("/home/software/oracle/product/11gr2/db_1/lib/tls/x86_64/libc.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/home/software/oracle/product/11gr2/db_1/lib/tls/x86_64", 0x7fff20e019e0) = -1 ENOENT (No such file or directory)
...................
...................
stat("/proc/sys/fs/binfmt_misc", ^C^C^F


"""卡死在了"/proc/sys/fs/binfmt_misc"這個位置"""
[[email protected] python]# systemctl restart proc-sys-fs-binfmt_misc.automount
           

繼續閱讀