Executing a batch file containing an exe path remotely via wmic

十年热恋 提交于 2019-12-25 09:37:40

问题


I have a batch file on Computer-A that contains several commands and a path to an exe file.

When I execute the batch file on Computer-B via wmic, I can see all the commands being executed in the batch file except that it does not run the exe. What are the things I need to check for to see why the .exe is not being executed on Computer-A?

wmic execution:

wmic /node:"<server_ip>" /user:domain\user /PASSWORD:"password" /OUTPUT:STDOUT process call create "cmd.exe /c C:\Folder\batch.bat"

回答1:


File paths in wmic need to be c style paths. So C:\\somefolder\\somefile.ext. \\ for\ in paths.



来源:https://stackoverflow.com/questions/28120566/executing-a-batch-file-containing-an-exe-path-remotely-via-wmic

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!