Today I found my NAS stop working.
Here are some feature of the problems:
1. ZFS module not loaded since Jul 1 07:00:33
$ less /var/log/syslog|grep 'The ZFS modules are not loaded'
Jul 1 07:00:33 openmediavault zpool[505]: The ZFS modules are not loaded.
Jul 1 07:00:33 openmediavault zfs[507]: The ZFS modules are not loaded.
Jul 1 07:00:33 openmediavault zvol_wait[508]: The ZFS modules are not loaded.
...
It must be the problem about reboot, because I set a routine reboot (in /etc/crontab) at 7:00 am in first day of every month. It never showed error till today.
It seems that ZFS module collapsed as I reboot (Maybe ZFS is working then. I had set an auto snapshot at 3:00 am and destory at 5:00 am every day)
Other informations were also support the ZFS-collapse hypothesis. For example, there are some error imformation in web GUI:
Failed to execute command 'export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin; export LANG=C.UTF-8; zfs list -H -t snapshot -o name,used,refer 2>&1' with exit code '1': The ZFS modules are not loaded. Try running '/sbin/modprobe zfs' as root to load them.
When try /sbin/modprobe zfs
$ /sbin/modprobe zfs
modprobe: FATAL: Module zfs not found in directory /lib/modules/5.5.0-0.bpo.2-amd64
At the same time, S.M.A.R.T was also stopped, but I'm not sure the relationship between them:
Failed to execute command 'export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin; export LANG=C.UTF-8; smartctl -x '/dev/sda' 2>&1' with exit code '1': smartctl 7.1 2019-12-30 r5022 [x86_64-linux-5.5.0-0.bpo.2-amd64] (local build) Copyright (C) 2002-19, Bruce Allen, Christian Franke, www.smartmontools.org /var/lib/smartmontools/drivedb/drivedb.h(5775): Syntax error, '"' expected
2. Disks are not damaged.
Considering reboot sometimes may damage disks, I try fdisk -l:
$ fdisk -l
Disk /dev/sda: 14.9 GiB, 16013942784 bytes, 31277232 sectors
Disk model: faspeed K5M-16G
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x5978c26a
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 23111679 23109632 11G 83 Linux
/dev/sda2 23113726 31277055 8163330 3.9G 5 Extended
/dev/sda5 23113728 31277055 8163328 3.9G 82 Linux swap / Solaris
Disk /dev/sdd: 3.7 TiB, 4000787030016 bytes, 7814037168 sectors
Disk model: WDC WD40EFRX-68N
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 01789BDB-17E3-6443-AEC1-C1E58485189F
Device Start End Sectors Size Type
/dev/sdd1 2048 7814019071 7814017024 3.7T Solaris /usr & Apple ZFS
/dev/sdd9 7814019072 7814035455 16384 8M Solaris reserved 1
...
Alles anzeigen
They were all be identified by system, so I think the disk is OK.
3. system information of my NAS:
Linux openmediavault.local 5.5.0-0.bpo.2-amd64 #1 SMP Debian 5.5.17-1~bpo10+1 (2020-04-23) x86_64 GNU/Linux
Conclusion:
ZFS is not working now, causing all files not available for visit. It's mostly likely to be the loss of ZFS module.
How to fix it?