Hello,
My ZFS pool tank1 has become unavailable due to missing virtual cache devices. Below are the details of my current situation:
cannot import ‘tank1’: no such pool or dataset Destroy and re-create the pool from a backup source.
TrueNAS version: TrueNAS-13.0-U6.2
pool: tank1
id: 2821495267620698100
state: UNAVAIL
status: One or more devices are missing from the system.
action: The pool cannot be imported. Attach the missing
devices and try again.
see: https://openzfs.github.io/openzfs-docs/msg/ZFS-8000-3C
config:
tank1 UNAVAIL insufficient replicas
raidz1-0 ONLINE
gptid/1f36bbf8-ed6c-11ec-bcdf-000c293d6a54 ONLINE
gptid/1f672568-ed6c-11ec-bcdf-000c293d6a54 ONLINE
gptid/1f6a9da2-ed6c-11ec-bcdf-000c293d6a54 ONLINE
gptid/1f68a515-ed6c-11ec-bcdf-000c293d6a54 ONLINE
gptid/1f6a0d7d-ed6c-11ec-bcdf-000c293d6a54 ONLINE
raidz1-1 UNAVAIL insufficient replicas
gptid/e355dde3-4f0a-11ee-899b-000c296b65a6 UNAVAIL cannot open
gptid/e359dadd-4f0a-11ee-899b-000c296b65a6 UNAVAIL cannot open
gptid/e357f651-4f0a-11ee-899b-000c296b65a6 UNAVAIL cannot open
This problem arose after we exported the pool and try to import it again. Cache drives which are now missing from the system. These cache drives were part of the pool’s RAIDZ1 configuration. When we tried to import the pool back, the missing virtual cache drives caused the pool to be unavailable.
Steps Taken:
Attempted to import the pool using zpool import -f tank1
without success.
Tried to use partial import commands zpool import -F -X tank1
and zpool import -d /dev/gptid -o readonly=on -F -X tank1
, but the pool remains unavailable.
Verified the physical connection of all drives.
Analyzed the pool configuration with zdb -e tank1
, which indicated the missing devices but was unable to proceed further.
Debug Messages:
spa.c:6110:spa_import(): spa_import: importing tank1
spa_misc.c:419:spa_load_note(): spa_load(tank1, config trusted): LOADING
...
spa_misc.c:419:spa_load_note(): spa_load(tank1, config trusted): vdev tree has 1 missing top-level vdevs.
...
spa_misc.c:404:spa_load_failed(): spa_load(tank1, config trusted): FAILED: unable to open vdev tree [error=2]
...
here is zdb -e tank1
Configuration for import:
vdev_children: 2
version: 5000
pool_guid: 2821495267620698100
name: 'tank1'
state: 1
hostid: 1886089997
hostname:
vdev_tree:
type: 'root'
id: 0
guid: 2821495267620698100
children[0]:
type: 'raidz'
id: 0
guid: 16474386183726751154
nparity: 1
metaslab_array: 65
metaslab_shift: 34
ashift: 12
asize: 39997054648320
is_log: 0
create_txg: 4
children[0]:
type: 'disk'
id: 0
guid: 8430242691483147646
DTL: 12595
create_txg: 4
path: '/dev/gptid/1f36bbf8-ed6c-11ec-bcdf-000c293d6a54'
children[1]:
type: 'disk'
id: 1
guid: 8219385248927223757
DTL: 12594
create_txg: 4
path: '/dev/gptid/1f672568-ed6c-11ec-bcdf-000c293d6a54'
children[2]:
type: 'disk'
id: 2
guid: 17813456083485363334
DTL: 12593
create_txg: 4
path: '/dev/gptid/1f6a9da2-ed6c-11ec-bcdf-000c293d6a54'
children[3]:
type: 'disk'
id: 3
guid: 7474179783460172973
DTL: 12592
create_txg: 4
path: '/dev/gptid/1f68a515-ed6c-11ec-bcdf-000c293d6a54'
children[4]:
type: 'disk'
id: 4
guid: 1345862483031176778
DTL: 12591
create_txg: 4
path: '/dev/gptid/1f6a0d7d-ed6c-11ec-bcdf-000c293d6a54'
children[1]:
type: 'missing'
id: 1
guid: 0
load-policy:
load-request-txg: 18446744073709551615
load-rewind-policy: 2
zdb: can't open 'tank1': No such file or directory
ZFS_DBGMSG(zdb) START:
spa.c:6110:spa_import(): spa_import: importing tank1
spa_misc.c:419:spa_load_note(): spa_load(tank1, config trusted): LOADING
vdev.c:161:vdev_dbgmsg(): disk vdev '/dev/gptid/1f36bbf8-ed6c-11ec-bcdf-000c293d6a54': best uberblock found for spa tank1. txg 12988230
spa_misc.c:419:spa_load_note(): spa_load(tank1, config untrusted): using uberblock with txg=12988230
spa_misc.c:419:spa_load_note(): spa_load(tank1, config trusted): vdev tree has 1 missing top-level vdevs.
spa_misc.c:419:spa_load_note(): spa_load(tank1, config trusted): current settings allow for maximum 0 missing top-level vdevs at this stage.
spa_misc.c:404:spa_load_failed(): spa_load(tank1, config trusted): FAILED: unable to open vdev tree [error=2]
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 0: root, guid: 2821495267620698100, path: N/A, can't open
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 0: raidz, guid: 16474386183726751154, path: N/A, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 0: disk, guid: 8430242691483147646, path: /dev/gptid/1f36bbf8-ed6c-11ec-bcdf-000c293d6a54, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 1: disk, guid: 8219385248927223757, path: /dev/gptid/1f672568-ed6c-11ec-bcdf-000c293d6a54, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 2: disk, guid: 17813456083485363334, path: /dev/gptid/1f6a9da2-ed6c-11ec-bcdf-000c293d6a54, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 3: disk, guid: 7474179783460172973, path: /dev/gptid/1f68a515-ed6c-11ec-bcdf-000c293d6a54, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 4: disk, guid: 1345862483031176778, path: /dev/gptid/1f6a0d7d-ed6c-11ec-bcdf-000c293d6a54, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 1: raidz, guid: 6809027625265124393, path: N/A, can't open
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 0: disk, guid: 16789085765231373816, path: /dev/gptid/e355dde3-4f0a-11ee-899b-000c296b65a6, can't open
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 1: disk, guid: 3490384972256348933, path: /dev/gptid/e359dadd-4f0a-11ee-899b-000c296b65a6, can't open
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 2: disk, guid: 11011393509591623693, path: /dev/gptid/e357f651-4f0a-11ee-899b-000c296b65a6, can't open
spa_misc.c:419:spa_load_note(): spa_load(tank1, config trusted): UNLOADING
ZFS_DBGMSG(zdb) END
root@storage[~]#
root@storage[~]# >....
id: 1
guid: 8219385248927223757
DTL: 12594
create_txg: 4
path: '/dev/gptid/1f672568-ed6c-11ec-bcdf-000c293d6a54'
children[2]:
type: 'disk'
id: 2
guid: 17813456083485363334
DTL: 12593
create_txg: 4
path: '/dev/gptid/1f6a9da2-ed6c-11ec-bcdf-000c293d6a54'
children[3]:
type: 'disk'
id: 3
guid: 7474179783460172973
DTL: 12592
create_txg: 4
path: '/dev/gptid/1f68a515-ed6c-11ec-bcdf-000c293d6a54'
children[4]:
type: 'disk'
id: 4
guid: 1345862483031176778
DTL: 12591
create_txg: 4
path: '/dev/gptid/1f6a0d7d-ed6c-11ec-bcdf-000c293d6a54'
children[1]:
type: 'missing'
id: 1
guid: 0
load-policy:
load-request-txg: 18446744073709551615
load-rewind-policy: 2
zdb: can't open 'tank1': No such file or directory
ZFS_DBGMSG(zdb) START:
spa.c:6110:spa_import(): spa_import: importing tank1
spa_misc.c:419:spa_load_note(): spa_load(tank1, config trusted): LOADING
vdev.c:161:vdev_dbgmsg(): disk vdev '/dev/gptid/1f36bbf8-ed6c-11ec-bcdf-000c293d6a54': best uberblock found for spa tank1. txg 12988230
spa_misc.c:419:spa_load_note(): spa_load(tank1, config untrusted): using uberblock with txg=12988230
spa_misc.c:419:spa_load_note(): spa_load(tank1, config trusted): vdev tree has 1 missing top-level vdevs.
spa_misc.c:419:spa_load_note(): spa_load(tank1, config trusted): current settings allow for maximum 0 missing top-level vdevs at this stage.
spa_misc.c:404:spa_load_failed(): spa_load(tank1, config trusted): FAILED: unable to open vdev tree [error=2]
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 0: root, guid: 2821495267620698100, path: N/A, can't open
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 0: raidz, guid: 16474386183726751154, path: N/A, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 0: disk, guid: 8430242691483147646, path: /dev/gptid/1f36bbf8-ed6c-11ec-bcdf-000c293d6a54, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 1: disk, guid: 8219385248927223757, path: /dev/gptid/1f672568-ed6c-11ec-bcdf-000c293d6a54, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 2: disk, guid: 17813456083485363334, path: /dev/gptid/1f6a9da2-ed6c-11ec-bcdf-000c293d6a54, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 3: disk, guid: 7474179783460172973, path: /dev/gptid/1f68a515-ed6c-11ec-bcdf-000c293d6a54, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 4: disk, guid: 1345862483031176778, path: /dev/gptid/1f6a0d7d-ed6c-11ec-bcdf-000c293d6a54, healthy
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 1: raidz, guid: 6809027625265124393, path: N/A, can't open
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 0: disk, guid: 16789085765231373816, path: /dev/gptid/e355dde3-4f0a-11ee-899b-000c296b65a6, can't open
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 1: disk, guid: 3490384972256348933, path: /dev/gptid/e359dadd-4f0a-11ee-899b-000c296b65a6, can't open
vdev.c:216:vdev_dbgmsg_print_tree(): vdev 2: disk, guid: 11011393509591623693, path: /dev/gptid/e357f651-4f0a-11ee-899b-000c296b65a6, can't open
spa_misc.c:419:spa_load_note(): spa_load(tank1, config trusted): UNLOADING
ZFS_DBGMSG(zdb) END
Thank you for your assistance.
Juha