我最近购买了联想的旧 ix4-300d NAS(过时型号)。它在显示文件系统错误一段时间后开始。
在通过 SSH 使用 putty 连接到设备后,我尝试运行 fsck,这在空运行时确实确定了一个可纠正的问题。但是,尽管卸载了驱动器和共享,fsck 仍会以错误提示终止驱动器仍在使用中。fuser 不显示任何正在使用该驱动器的内容。我还通过 Web 界面禁用了协议。我无法从 Web 界面使用文件系统扫描仪的原因是它不起作用。我也无法在根 FS 上触摸 forcefsck,因为根 FS 是只读的,并且触摸的文件在重新启动时就会消失。
任何帮助将不胜感激。非常感谢。
root@AdanetCloud:/# vgs
VG #PV #LV #SN Attr VSize VFree
7d2470b7_vg 1 1 0 wz--n- 14.48t 0
md0_vg 1 2 0 wz--n- 19.98g 0
root@AdanetCloud:/# lvs
LV VG Attr LSize Pool Origin Data% Move Log Copy% Convert
lv9953e62 7d2470b7_vg -wi-ao-- 14.48t
BFDlv md0_vg -wi-ao-- 4.00g
vol1 md0_vg -wi-ao-- 15.98g
root@AdanetCloud:/# df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/7d2470b7_vg-lv9953e62 15T 2.6T 12T 18% /mnt/pools/A/A0 ... (truncated)
fsck -yf /dev/mapper/7d2470b7_vg-lv9953e62
root@AdanetCloud:/# fuser -uvm /mnt/pools/A/A0
USER PID ACCESS COMMAND
/mnt/pools/A/A0: root kernel mount (root)/mnt/pools/A/A0
root 3512 F.... (root)mt-daapd
[fuser -uvm /mnt/pools/A/A0 after unmounting /mnt/pools/A/A0]
root@AdanetCloud:/# fuser -uvm /mnt/pools/A/A0
USER PID ACCESS COMMAND
/mnt/pools/A/A0: root kernel mount (root)/
root 1 .rce. (root)init
root 2 .rc.. (root)kthreadd
root 3 .rc.. (root)ksoftirqd/0
root 6 .rc.. (root)migration/0
root 7 .rc.. (root)migration/1
root 9 .rc.. (root)ksoftirqd/1
root 10 .rc.. (root)khelper
root 11 .rc.. (root)netns
root 183 .rc.. (root)sync_supers
root 185 .rc.. (root)bdi-default
root 187 .rc.. (root)kblockd
root 193 .rc.. (root)ata_sff
root 204 .rc.. (root)khubd
root 210 .rc.. (root)md
root 228 .rc.. (root)rpciod
root 251 .rc.. (root)khungtaskd
root 256 .rc.. (root)kswapd0
root 257 .rc.. (root)fsnotify_mark
root 258 .rc.. (root)unionfs_siod
root 259 .rc.. (root)nfsiod
root 260 .rc.. (root)xfs_mru_cache
root 261 .rc.. (root)xfslogd
root 262 .rc.. (root)xfsdatad
root 263 .rc.. (root)xfsconvertd
root 264 .rc.. (root)crypto
root 345 .rc.. (root)iscsi_eh
root 348 Frc.m (root)httpd
root 361 .rc.. (root)scsi_eh_0
root 364 .rc.. (root)scsi_eh_1
root 367 .rc.. (root)scsi_eh_2
root 370 .rc.. (root)scsi_eh_3
root 384 .rc.. (root)scsi_eh_4
root 387 .rc.. (root)scsi_eh_5
root 393 .rc.. (root)target_completi
root 394 .rc.. (root)LIO_rd_mcp
root 403 .rc.. (root)mtdblock0
root 408 .rc.. (root)mtdblock1
root 413 .rc.. (root)mtdblock2
root 418 .rc.. (root)mtdblock3
root 423 .rc.. (root)mtdblock4
root 428 .rc.. (root)mtdblock5
root 433 .rc.. (root)mtdblock6
root 538 .rc.. (root)scsi_eh_6
root 539 .rc.. (root)usb-storage
root 558 .rc.. (root)kworker/u:1
root 633 .rc.. (root)ubi_bgt0d
root 694 .rc.. (root)kworker/0:0
root 713 .rc.. (root)ubifs_bgt0_0
root 718 .rc.. (root)md0_raid1
root 726 .rc.. (root)kdmflush
root 735 .rc.. (root)kjournald
root 750 .rc.. (root)loop0
root 754 .rc.. (root)loop1
root 776 .rc.. (root)loop2
root 839 .rc.. (root)krfcommd
root 920 .rc.. (root)flush-7:1
root 1049 Frc.m (root)udevd
root 2172 Frc.m (root)logsave
root 2484 Frc.m (root)rsyslogd
root 2554 .rc.. (root)bond0
root 2705 .rc.. (root)kworker/0:1
root 2795 Frc.m (root)dhclient
nobody 2934 Frc.m (nobody)mdnsd
root 2936 .rc.m (root)hostnamed
root 2949 Fr..m (root)appmd
root 2960 Frc.m (root)getty
root 2973 Fr..m (root)dbus-daemon
root 2975 Fr..m (root)eventd
nobody 3007 Frc.m (nobody)mdnsd
root 3009 .rc.m (root)hostnamed
root 3010 Fr..m (root)pkgd
root 3026 Fr..m (root)upnpdiscovery
nobody 3029 Fr..m (nobody)mdnsd
root 3031 Frc.m (root)sshd
root 3033 Fr..m (root)svcd
root 3037 Fr..m (root)acpid
root 3043 Fr..m (root)imgd
root 3057 Frc.m (root)lld2d
root 3058 Fr..m (root)sh
root 3060 Fr..m (root)sh
root 3077 Frc.m (root)httpd
root 3102 Fr..m (root)pcloudd
root 3105 Fr..m (root)activefolder
root 3243 Fr..m (root)sleep
root 3320 Frc.m (root)cron
root 3371 Frc.m (root)netplugd
root 3463 Frc.m (root)sshd
root 3478 .rc.m (root)sh
root 3556 .rc.. (root)flush-ubifs_0_0
root 3601 Fr..m (root)sleep
root 3678 Fr..m (root)sleep
root 3900 Frc.m (root)udevd
root 3902 Frc.m (root)udevd
root 4042 .rc.. (root)kdmflush
root 4087 .rc.. (root)kdmflush
root 4099 .rc.. (root)jbd2/dm-1-8
root 4100 .rc.. (root)ext4-dio-unwrit
root 4105 .rc.. (root)jbd2/dm-2-8
root 4106 .rc.. (root)ext4-dio-unwrit
root 4110 .rc.. (root)flush-253:1
root 4149 .rc.. (root)ufsd_sdd1
root 4316 Fr..m (root)displayd
root 4340 Fr..m (root)quiktransfer
root 4343 Fr..m (root)logrotation
root 4384 Fr..m (root)datamover
root 4459 Fr..m (root)connectd
root 4483 Fr..m (root)amazon
root 4548 Fr..m (root)Transmission
root 4550 Fr..m (root)transmission-da
root 4607 Fr..m (root)smbd
root 4611 Fr..m (root)winbindd
root 4616 Fr..m (root)mysqlserver
root 4683 Fr..m (root)winbindd
root 4839 Fr..m (root)smbd-notifyd
root 4840 Fr..m (root)cleanupd
root 4850 Fr..m (root)winbindd
root 4856 Fr..m (root)winbindd
root 4887 Fr..m (root)lpqd
root 4952 Fr..m (root)nmbd
root 4974 Fr..m (root)mysqld_safe
root 5202 Fr..m (root)rsync
root 5439 Fr..m (root)twonkystart.sh
root 5447 Fr..m (root)su
root 5451 Frc.m (root)isnsd
nobody 5459 Fr..m (nobody)twonkyserver
mysql 5837 Fr..m (mysql)mysqld
root 5985 .rc.. (root)scst_release_ac
root 5991 .rc.. (root)scst_uid
root 5995 .rc.. (root)scstd0
root 5998 .rc.. (root)scstd1
root 5999 .rc.. (root)scst_initd
root 6000 .rc.. (root)scsi_tm
root 6001 .rc.. (root)scst_mgmtd
root 6044 .rc.. (root)iscsird0_0
root 6045 .rc.. (root)iscsird0_1
root 6046 .rc.. (root)iscsird0_2
root 6049 .rc.. (root)iscsird0_3
root 6051 .rc.. (root)iscsiwr0_0
root 6052 .rc.. (root)iscsiwr0_1
root 6053 .rc.. (root)iscsiwr0_2
root 6055 .rc.. (root)iscsiwr0_3
root 6066 Frc.m (root)iscsi-scstd
root 6247 .rc.. (root)kworker/u:0
root 15522 Frc.m (root)httpd
root 16215 .rc.. (root)kworker/1:1
root 23662 Frc.m (root)httpd
root 26558 .rc.. (root)flush-253:2
root 32367 .rc.. (root)kworker/1:2
[After trying to run fsck on unmounted drive]
root@AdanetCloud:/# fsck /dev/mapper/7d2470b7_vg-lv9953e62
fsck 1.42.5 (29-Jul-2012)
e2fsck 1.42.5 (29-Jul-2012)
/dev/mapper/7d2470b7_vg-lv9953e62 is in use.
e2fsck: Cannot continue, aborting.
我能够解决这个问题。
启用 SSH(支持模式)并登录到单元 [UN: root; PW: soho+password] 使用 SSH 客户端(例如 Windows 上的 Putty 或 Android 上的 JuiceSSH)。
通过 Web GUI 关闭所有可以访问驱动器、NFS、Windows 共享、媒体服务器的“协议”[我之前没有禁用媒体服务器,因此使用了 raid 驱动器]。
卸载所有 NFS 共享文件夹并安装池 [使用 df -h 查看哪些文件夹已安装到您的驱动器(我是 /dev/mapper/7d2470b7_vg-lv9953e62)并使用 umount。
卸载所有内容后,在 RAID 驱动器上运行 fsck,运行 fsck -yfVC /dev/mapper/7d2470b7_vg-lv9953e62。
然后让它运行并纠正发现的任何错误。您可以单独运行 2 次以确保修复所有错误。
如果有大量碎片 (>1%),则在挂载文件系统后重新启动后运行 e4defrag /dev/mapper/7d2470b7_vg-lv9953e62(与 fsck 相反,它不会在已挂载的文件系统上运行)
运行 iostat -x 并检查每个驱动器的 %b。与其他的相比,表现不佳(或即将失败)的等待时间较长,通常 %b 将接近 100%。该驱动器需要更换。
重新启动(立即运行重新启动或关机)
感谢大家。