Skip to content

Instantly share code, notes, and snippets.

@rponte
Created January 3, 2012 17:56
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save rponte/1556084 to your computer and use it in GitHub Desktop.
Save rponte/1556084 to your computer and use it in GitHub Desktop.
running cmd.exe as a windows service
-- install cmd.exe as a windows service
sc create CmdAsService binpath= "cmd /K start" type= own type= interact
-- now execute this to run cmd.exe service
sc start CmdAsService
-- you can delete cmd.exe service with this command
sc delete CmdAsService