A
A
Arthur Samurai2021-12-17 14:34:30
Python
Arthur Samurai, 2021-12-17 14:34:30

How can I do something like os.startfile() on a remote host?

We have network path
rem_dir = '\\192.168.150.20\test\x.bat'

Can I do something like
os.startfile(rem_dir)

This will execute the batch file on my side, can I execute it on the remote host ?
What should be used?

Machines on Windows in the local network, the remote user is an administrator.
Help with valuable advice.
Thanks

Answer the question

In order to leave comments, you need to log in

2 answer(s)
V
Vladimir Kuts, 2021-12-17
@zvepb

Utilities system internals specifically for windows will help. About psexec you shurshur mentioned
For * nix systems - ssh

V
Vindicar, 2021-12-17
@Vindicar

You need a program running on a remote host that will execute code on request from the network.
Either terminal servers like SSH (for Linux systems are included, you need to install it under Windows), or a remote desktop like VNC, or your own application that you run on the host and that will listen to requests from the network.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question