shutdown is a small tool that enables to shutdown Windows OS from command line. shutdown tool can be used to either shutdown or restart local or remote computer. To shutdown or restart remote computer you have to use /m switch for example: shutdown /m \\RemoteComputerName /s /t 0 however sometimes you can receive following error:
RemoteComputerName: The entered computer name is not valid or remote shutdown is not supported on the target computer. Check the name and then try again or contact your system administrator.(53)
The solutions is quite simple and it is related to firewall setup between computer from which shutdown tool was invoked and target computer.
shutdown tool works using Samba over TCP, which means that remote computer must accept packets on TCP port 445. So the only thing you need to do is to open Windows Firewall with Advanced Security and enable the rule: File and Printer Sharing (SMB-In)
and shutting down remote computer will start working.