I'm not assuming this is cosmetic and I'd rather be told I'm wrong now than find out later.
Setup
TrueNAS CORE 13.0-U6.7 (FreeBSD 13.1-RELEASE-p9)
Single pool DeadPool, one raidz2 vdev, 12 × 4TB SAS drives
Pool created years ago via the GUI
Two drives replaced over time, both via zpool replace from the shell
upgrading to Truenas core gives me deep anxiety, and certanly not going to happen until i know the pools are stable and exportable/importable.
Symptom 1, pool members named inconsistently
Running zpool status -P DeadPool:
NAME STATE READ WRITE CKSUM
DeadPool DEGRADED 0 0 0
raidz2-0 DEGRADED 0 0 0
/dev/gptid/6c4694e2-1978-11ee-ac31-ecf4bbc49a4c ONLINE 0 0 0
/dev/gptid/6c25531c-1978-11ee-ac31-ecf4bbc49a4c ONLINE 0 0 0
replacing-2 DEGRADED 0 0 0
/dev/gptid/6b9dc861-1978-11ee-ac31-ecf4bbc49a4c FAULTED 148 0 0 too many errors
/dev/da2 ONLINE 0 0 0 (resilvering)
/dev/gptid/6c3127e7-1978-11ee-ac31-ecf4bbc49a4c ONLINE 0 0 0
/dev/da4p2 ONLINE 0 0 0
...
/dev/da9 ONLINE 0 0 0
/dev/gptid/6beb7a7f-1978-11ee-ac31-ecf4bbc49a4c ONLINE 0 0 0
/dev/gptid/6c1c515e-1978-11ee-ac31-ecf4bbc49a4c ONLINE 0 0 0
Ten members are /dev/gptid/<uuid>. Two are /dev/da2 and /dev/da9, raw device paths, and one of them (da4p2) is a partition path.
Symptom 2, Storage → Disks shows pool as N/A
In the GUI, Storage → Disks, the Pool column shows N/A for the two replaced drives. Selecting the row and opening Details → Disk Info returns "Disk is unavailable."
This makes it look like the drives aren't in the pool.
Symptom 3, middleware has no zfs_guid for those drives
midclt call disk.query '[["name","=","da9"]]'
returns "zfs_guid": None, "pool": None, while every other drive returns a real zfs_guid.
Root cause (I think..)
TrueNAS's middleware resolves pool membership by matching what zpool status reports against its own disk table. In middlewared/plugins/disk_/sync.py, ident_to_dev() handles the lookup:
if _type == 'uuid':
found = next(part_xml.iterfind(f'.//config[rawuuid="{_value}"]/../../name'), None)
if found is not None and not found.text.startswith('label'):
return found.text
That branch matches a GPTID against the partition's rawuuid. It works correctly, verified: gpart list da8p2 returns rawuuid: 6bf5a6d7-1978-11ee-ac31-ecf4bbc49a4c, which is exactly the pool's member path for da8, and da8 resolves fine in the GUI.
The failure is that zpool replace run from the shell recorded the new member as /dev/da9 (a literal device path) instead of a GPTID. The middleware only knows how to resolve GPTIDs, labels, serials and serial_lunid. It has no branch for a bare /dev/daN member path. So the lookup returns nothing, zfs_guid stays NULL, and the Disks screen shows N/A.
This is the part I want challenged.
My reading is that this is a display/middleware bug only, and that the pool itself is intact. My reasoning:
zdb -l /dev/da9 returns the full pool label from the disk:
name: 'DeadPool'
pool_guid: 2997173517431984424
...
children[9]:
type: 'disk'
id: 9
guid: 12550181049595215785
path: '/dev/da9'
whole_disk: 1
DTL: 114657
da9 is children[9] of a raidz vdev with nparity: 2, and its pool_guid matches zpool get guid DeadPool. zpool status -v reports errors: No known data errors, and every member reads 0/0/0.
But I want to be told if I'm wrong about the risk. Specific concerns I don't have good answers to:
Boot-time device ordering. If the member is pinned to /dev/da9 and that name moves (HBA reorder, drive added/removed, controller in a different slot), does the pool fail to import, or does it correctly find the member by GUID? My understanding is ZFS matches by vdev GUID and the path is informational, but I'd like confirmation from someone who has lived through it.
Replacement behaviour going forward. If a member is a raw device path rather than a GPTID, does the next zpool replace behave correctly? Does the UI Replace wizard still work on those members, or does the missing zfs_guid break it?
Multipath / mixed naming. Is there any case where mixed member naming causes ZFS to treat something as two different devices?
The da4p2 member. One member is recorded as a partition (/dev/da4p2) rather than a whole disk, unlike the others which are whole_disk: 1. Is that meaningful or just how that drive got added?
Also note: the correct screen for pool health is Storage → Pools → (pool) → gear icon → Status, not Storage → Disks. The Status screen renders the vdev tree from zpool status and shows all twelve members correctly. Storage → Disks is a hardware inventory and shows N/A for the two members in question.
The fix I am considering, but not confident enough to run yet
Goal: rewrite pool member paths from /dev/daN to /dev/gptid/<uuid> so every member resolves the same way.
I will not do this during a resilver or a scrub. Waiting for the pool to be idle before i even attempt.
Note the current state for comparison:
zpool status -P DeadPool > /root/pool-before.txt
Confirm all GPTIDs exist and map to the expected partitions:
glabel status
You want one gptid/<uuid> line per member showing the correct daNp2 component.
Export:
zpool export DeadPool
Re-import forcing GPTID resolution:
zpool import -d /dev/gptid DeadPool
Verify:
zpool status -P DeadPool midclt call disk.query '[["name","=","da9"]]'
Questions about the fix itself, which is why I have not run it:
Is zpool import -d /dev/gptid sufficient, or does it need -d /dev/gptid -d /dev so the scan can also see the two device-path members?
Does export/import actually rewrite the stored member path in the label, or does ZFS preserve the original path? If it preserves it, is zpool replace onto the GPTID path the only way to change it?
Is there a middleware-side or config-database fix that avoids cycling the pool at all?
Has anyone done this on a pool with mixed member naming and had it come back clean?
Rollback if the import doesn't come back cleanly
Export/import changes how members are addressed, not the data. If the import fails:
zpool import # lists importable pools and available devices
zpool import -d /dev # import resolving by raw device path (the old way)
That returns you to the previous state.
Notes / gotchas
midclt call disk.sync_all does not fix this. It re-scans hardware but doesn't rewrite pool member paths.
Do replacements through the GUI (Storage → Pools → status → ⋯ → Replace) in future. The GUI writes a GPTID member, so the middleware keeps resolving correctly.
My instinct is to leave it alone until someone confirms the risk, because I would rather have a wrong column than a resident pool. But if anyone here says the device-path naming is genuinely dangerous, I want to know that now.
On TrueNAS SCALE the equivalent bug is well documented (see: "Migration of CORE to SCALE – pool disks screwed up in UI only"). Same mechanism, same middleware assumption.
TL;DR: TrueNAS middleware resolves pool members by GPTID and has no code path for members recorded as bare /dev/daN. Running zpool replace from the shell creates exactly that. zpool status -P shows the difference instantly; Storage → Disks then shows N/A and Disk Info reports unavailable. My read is that the pool is intact by vdev GUID and the display is the only casualty, but I want that conclusion stress-tested before I touch anything. If the device-path naming is a real import-time hazard, say so. Fix candidates are zpool export + zpool import -d /dev/gptid while the pool is idle, run on a day I have time to recover. Pool health should be read from Pools → Status, not Storage → Disks.
edit1:
Storage → Pools → DeadPool → ⋯ → Add Vdevs to Pool lists both da2 and da9 under "Available Disks," alongside genuinely unused disks.
That follows directly from zfs_guid being NULL. If the middleware cannot attribute a disk to a pool, it treats it as unassigned and eligible to be pooled.
So the question is not only "is this cosmetic." It is: can an administrator add a vdev built from disks that are already members? If ZFS rejects it, this is a dangerous UI trap that misleads operators into a destructive attempt. If ZFS accepts anything, worse.
I have not tested this and I am not going to test it on a live 27 TB pool. If anyone knows what happens, I would like to know before I do something dumb.