Friday, August 19, 2011

Turn off window machine from remote linux machine

Using samba you can turn off windows machine from remote linux machine.Use net rpc command in following way


net rpc SHUTDOWN -I -U < windows username>

For example to shutdown windows machine with ip 192.168.5.5 with username administrator , use following

root# net rpc SHUTDOWN -I 192.168.5.5 -U administrator
 
you can also create user remotely via linux pc


by entering command

#net rpc user ADD -I (ip of window pc) (user name) (password) -U administrator