If you get the following error:
Could not connect to server 172.16.1.16 Connection failed: NT_STATUS_ACCESS_DENIED Could not connect to server 172.16.1.16 Connection failed: NT_STATUS_ACCESS_DENIED
with this command line
net rpc -S 172.16.1.16 -U administrator%password shutdown -t 1 -f
You have to add the following line to /etc/samba/smb.conf
client ipc signing = auto