Closed darkpixel closed 5 years ago
Quick comment on this one (I see the same on Debian Jessie with zfs 0.6.5.6-3, but potentially due to another cause):
The systemd service /lib/systemd/system/zfs-import-scan.service fails importing all zpool, i.e. command /sbin/zpool import -d /dev/disk/by-id -aN
fails with:
The devices below are missing, use '-m' to import the pool anyway:
nvme0n1p1 [log]
cannot import 'boinc': one or more devices is currently unavailable
The culprit here seems to be -d /dev/disk/by-id
which presumably fails as the nvme is not listed in there and thus the zpool was created with the /dev/nvme0n1p1 device.
@darkpixel so the issue here seems to be that your zfs cache file knows about the log device but it wasn't able to locate it at the expected path. As @carsten-AEI mentioned this sort of thing is more likely early on in the boot when all the devices may not yet have had links created.
The probing logic is being improved with the proposed patches in #4523. I'd be very interested to hear if apply those patches to master resolves this issue.
so the issue here seems to be that your zfs cache file knows about the log device but it wasn't able to locate it at the expected path
@behlendorf I have a different case where the slog is absent not because of missing from expected path but really absent, so the proposed patches do not apply.
the pool shows as UNAVAIL on 'zpool import' but does import successfully with 'zpool import poolname -m'.
Can the 'zpool import' message be changed from UNAVAIL to the result of 'zpool import -m poolname' aka can 'zpool import' check that the pool can really be imported with 'zpool import -m' and adjust the message accordingly?
seeing the 'UNAVAIL' result is pretty misleading when in fact everything works just fine by importing without the slog device. when the user sees "The pool cannot be imported" and the url http://zfsonlinux.org/msg/ZFS-8000-6X says the same, it creates a hopeless feeling and discourages user to further attempt to online the pool.
I'm seeing the same issue running 0.6.5.9 on Debian Jessie.
$ sudo zpool import pool
The devices below are missing, use '-m' to import the pool anyway:
mirror-1 [log]
ata-Samsung_SSD_850_EVO_250GB_S21NNXAGA26164Y-part2
ata-SanDisk_SDSSDA120G_170213463203-part2
It imports fine with -m
but shows this message and refuses to import the pool at anytime without -m
so I don't see this problem being related to probing at boot.
This problem exists regardless of whether I use disk id, uuid, or device name and I have tried without the mirror with just one device with the same luck. Something with the log device regardless of its name.
Sorry @behlendorf, I didn't see your reply for some reason. I recently changed jobs and don't have access to ZFS test systems anymore. Someone else with the issue will have to test or we can close the issue. :)
I have the same issue on Centos 7.2, Using ZFS 0.7.3
My slog device (second partition on SSD drive) is present however the zpool import doesn't work without the "-m" flag.
This becomes critical if your SLOG have pending data to commit, because it won 't be possible to apply the SLOG to the main pool disks.
Thanks a lot.
Miguel
same issue here:
root@hcrs002:~# zpool import tier2 The devices below are missing, use '-m' to import the pool anyway: /tier1/tier2_log [log]
cannot import 'tier2': one or more devices is currently unavailable root@hcrs002:~# ls -al /tier1/tier2_log -rw-r--r-- 1 root root 536870912 Jan 13 04:02 /tier1/tier2_log
device/file is present.
Running a
zpool import
shows my log device is 'missing' and suggests I can import the pool by passing the -m flag.When I pass the -m flag, the pool (including the 'missing' log device) is imported and works fine.
This annoyingly breaks puppet automation we have set up for deploying new machines. ;)
I can reproduce on 5/5 machines by rebooting, then trying to import the pool.