Project

General

Profile

Bug #14161

Updated by Toomas Soome 8 months ago

Getting errors from sudo and no debug messages are logged: 
 <pre> 
     10:55:30.24 NOTE: Performing test-fail callback (/opt/zfs-tests/callbacks/zfs_dbgmsg) 
     10:55:30.25 ================================================================= 
     10:55:30.25    Tailing last 200 lines of zfs_dbgmsg log 
     10:55:30.25 ================================================================= 
     10:55:30.26 sudo: PAM account management error: Permission denied 
     10:55:30.26 sudo: a password is required 
     10:55:30.26 ================================================================= 
     10:55:30.26    End of zfs_dbgmsg log 
     10:55:30.26 ================================================================= 
 </pre> 

 So we only should use sudo when run as non-root. Tested by running this script manually as non-root and as root. Also did full zfstest run and inspected the log for failed tests and confirmed we do get zfs debug messages. 

 With fix: 
 <pre> 
     00:22:41.16 NOTE: Performing test-fail callback (/opt/zfs-tests/callbacks/zfs_dbgmsg) 
     00:22:41.17 ================================================================= 
     00:22:41.17    Tailing last 200 lines of zfs_dbgmsg log 
     00:22:41.17 ================================================================= 
     00:22:42.30 spa_open_common: opening rpool 
     00:22:42.30 spa_load(rpool, config trusted): LOADING 
     00:22:42.30 disk vdev '/dev/dsk/c3t0d0s1': best uberblock found for spa rpool. txg 297238 
     00:22:42.30 spa_load(rpool, config untrusted): using uberblock with txg=297238 
     00:22:42.30 spa_load(rpool, config trusted): read 199 log space maps (199 total blocks - blksz = 131072 bytes) in 67 ms 
     00:22:42.30 MMP thread started pool 'rpool' gethrtime 36787723190 
     00:22:42.30 spa=rpool async request task=1 
     00:22:42.30 spa=rpool async request task=2048 
     00:22:42.30 spa_load(rpool, config trusted): LOADED 
     00:22:42.30 txg 297240 open pool version 5000; software version 5000/5; uts    5.11 illumos-65ecf39910 i86pc 
     00:22:42.30 ioctl get_bootenv 
     00:22:42.30 MMP thread started pool 'testpool' gethrtime 238007147730 
     00:22:42.30 txg 5 create pool version 5000; software version 5000/5; uts openindiana 5.11 illumos-65ecf39910 i86pc 
     00:22:42.30 command: zpool create -f testpool c1t0d0 
     00:22:42.30 txg 7 create testpool/testfs (id 146) 
     00:22:42.30 ioctl create 
     00:22:42.30 command: zfs create testpool/testfs 
     00:22:42.30 txg 9 set testpool/testfs (id 146) mountpoint=/var/tmp/testdir 
     00:22:42.30 command: zfs set mountpoint=/var/tmp/testdir testpool/testfs 
     00:22:42.30 txg 10 set testpool/testfs (id 146) aclmode=3 
     00:22:42.30 command: zfs set aclmode=passthrough testpool/testfs 
     00:22:42.30 txg 11 set testpool/testfs (id 146) aclinherit=0 
     00:22:42.30 command: zfs set aclinherit=discard testpool/testfs 
     00:22:42.30 txg 36 set testpool/testfs (id 146) aclinherit=1 
     00:22:42.30 command: zfs set aclinherit=noallow testpool/testfs 
     00:22:42.30 txg 38 set testpool/testfs (id 146) aclinherit=4 
     00:22:42.30 command: zfs set aclinherit=restricted testpool/testfs 
     00:22:42.30 txg 40 set testpool/testfs (id 146) aclinherit=3 
     00:22:42.30 command: zfs set aclinherit=passthrough testpool/testfs 
     00:22:42.32 ================================================================= 
     00:22:42.32    End of zfs_dbgmsg log 
     00:22:42.32 ================================================================= 

 </pre>

Back