0
I'm running an IIS command on a remote server via PSEXEC.
the command I'm running has the "set" keyword, which is a command-line reserved keyword.
My command looks like this and throws an error.
psexec \\server c:\windows\system32\inetsrv\appcmd set config "site" -section:system.webServer/httpRedirect /enabled:"True"
Is there any way I can escape the "set" keyword so the command-line process ignores it?
I have to point out that the Windows command line is not MS-DOS. While it shares some syntax due to its history, internally it has been nothing like DOS since Windows 2000 (and even more so since Vista). Please do not refer to it as DOS unless you are actually running Windows ME or older. This also doesn't have anything to do with batch files, strictly speaking. – Bob – 2013-11-07T02:09:47.873
1
set
is not a keyword, as far as I know. It is a built-in command, and the command interpreter doesn't (shouldn't?) care if it turns up as a parameter. Could you provide an error message? – Bob – 2013-11-07T02:12:04.353