Test is to be run locally on TrueNAS server. Syntax is as follows:
"smbtorture //127.0.0.1/zshare -U smbuser%password vfs.shadow_copy_zfs"
returns 0 on success 1 on failure. On failure, details are printed to stderr.
Setup for test requires the following:
1) Create pool "tank"
2) Create user
3) Create dataset "zshare" , and grant user from (2) full_control to dataset
4) Create SMB share "zshare" with shadow copies enabled. Set auxiliary parameter "shadow:ignore_empty_snaps=false" on share.
Test will create a subdataset tank/zshare/TESTDATASET and will not destroy it.