You didn’t post what command you are referring to.
Adding link to other post
You might have to use ‘sudo’ before the command on TrueNAS Scale (Linux).
Either of the following should allow you to match up the info from the GUI to a drive serial number. LSBLK may need ‘sudo’ before it
lsblk -bo NAME,LABEL,MAJ:MIN,TRAN,ROTA,ZONED,VENDOR,MODEL,SERIAL,PARTUUID,START,SIZE,PARTTYPENAME
sudo ZPOOL_SCRIPTS_AS_ROOT=1 zpool status -vLtsc lsblk,serial,smartx,smar