Recent Changes - Search:

Softwares

.

Stop-or-Start-a-Windows-service-from-a-Linux-machine

Main.Stop-or-Start-a-Windows-service-from-a-Linux-machine History

Hide minor edits - Show changes to output

June 30, 2010, at 02:27 AM by 15.211.153.74 -
Added lines 1-17:
(:Google1:)
(:Googlemm:)
----

Reference:

http://www.commandlinefu.com/commands/view/5943/stop-or-start-restart-a-windows-service-from-a-linux-machine

Make sure that you have the samba-common package installed for Ubuntu, or the corresponding package for your Linux distribution. The simple sudo apt-get install samba-common command will do it for any Debian-based Linux.


net rpc -I ADDRESS -U USERNAME%PASSWORD service {stop|start} SVCNAME


list the services available on a Windows machine by using the following command, making sure to use credentials that have administrative privileges on the remote machine:

net rpc service list -I IPADDRESS -U USERNAME%PASSWORD
Edit - History - Print - Recent Changes - Search
Page last modified on June 30, 2010, at 02:27 AM