windows - Execute system commands using wmi python on remote computer -


i trying create directory on remote computer using wmi , python. able run batch file providing complete path it. not execute system command.

this following code not create directory on remote computer.

conn = wmi.wmi('172.20.23.45', user='administrator', password='pass@123') conn.win32_process.create(commandline='mkdir temp') 

it done as.

conn.win32_process.create(commandline='cmd.exe /c mkdir temp') 

Comments

Popular posts from this blog

ruby on rails - RuntimeError: Circular dependency detected while autoloading constant - ActiveAdmin.register Role -

c++ - OpenMP unpredictable overhead -

javascript - Wordpress slider, not displayed 100% width -