2

I use a SSH client (bitvise SSH client) to connect to another Windows machine and launch a process. The processes take a long time to complete and I want to disconnect from the remote machine while keeping the process running. How can I do this? When I close the terminal or terminate the SSH session, the process is killed too.

This question has been asked and answered for Unix machines but I couldn't find anything for Windows.

0

1 Answer 1

1

I contacted Bitvise support for a solution. Turns out Bitvise SSH server does have this functionality, as explained here, and I explain their answer:

First make sure that the setting "Allow session job breakaway" is enabled for the SSH login account. It is located in the "Advanced SSH Server settings", for the account or group settings entry, under "Terminal and exec requests". (It is by default enabled in recent Bitvise SSH Server versions)

Now we can run the process detached from the session using BvRun, located in the Bitvise installation directory (we should add it to the PATH so that we can run it everywhere)

BvRun -brj -new (insert full command here)

this runs the command in a new terminal window. Alternatively:

BvRun -brj -det (insert full command here)

this runs the command detached from the session. Note that in both cases you can't see the output in terminal window and should redirect the output to a file if you want.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .