ansitest/OSX/zfs-show-my-shares--osx.sh

16 lines
352 B
Bash
Raw Normal View History

2021-04-08 12:26:25 -05:00
#!/bin/bash
#smbclient -N -L localhost
2021-04-08 13:20:20 -05:00
# in linux guest: smbclient -U userid -L hostIP
2021-04-08 12:26:25 -05:00
outfile=/tmp/sharing.txt
zfs get sharesmb |grep ' on ' > $outfile
# REF: https://superuser.com/questions/499075/view-shared-folders-from-terminal
#sharing -l >> $outfile
sharing -l |grep -A 1 smb |grep -v smb >> $outfile
#less $outfile
grep -v '^--' $outfile