This node uses a SSH connection to PuTTY to send a shell script from Windows to a Linux system and to run it there.
Expected File Content
There are no special requirements to the script content, ensure that it runs successful on your Linux system.
System Requirements
The node requires an existing password-less login. For more details see this article. The password-less login must be saved as the Default configuration of PuTTY.
Node Settings
The Process tab allows you to define the login details and the remote working directory.
Field | Description |
---|---|
User name | Defines the user name. |
Host name | Defines the host name or IP address to connect to. |
Remote working directory | Defines the remote working directory by using one of the
following options:
|
Poll process until finished on error | When selected, the node will try to handle SSH connection errors or crashes, for example when the network connection is interrupted for a short time. This changes the way the remote script is executed by redirecting the stdout and stderr streams to files in the same directory. The logs inside those files are only available after the run. |
Poll process timeout | Defines the maximum time period in seconds to wait for the remote process to finish after a crash. For example, If the remote script runs for 5 minutes and this setting is set to 2 minutes, the polling will be successful if the crash occurs after 3 minutes. If it crashes earlier, the node will fail with a timeout error. Ansys recommends setting this value to the expected duration of the remote script. |
PID polling interval | After the remote script is executed, the node will try to retrieve the ID of the spawned process to poll it. This setting defines the interval for polling this PID in seconds. Ansys recommends setting it as low as possible. |
Process polling interval | Defines the interval in seconds to send polling commands to the remote machine after the connection broke. |
The Send input files tab allows you to define process input files. They are sent to the remote working directory before running the process. If you are using a shared working directory, this tab is not available.
Click
to add another input file.Type the Working file name or click to browse for the file.
Click
to delete an input file.
The Receive output files tab allows you to define process output files. They are received from remote working directory after running the process.
Click
to add another output file.Type the Working file name or click or to browse for the file.
Define the Importance of the file:
Required file. The process raises an error if it is missing.
Optional file. The process does not raise an error if it is missing.
Wait for file. The process waits for the file or stops if the Maximum wait time is reached (0=infinite).
Wait, indicated failure file. The process stops with an error if the file exists.
Click
to delete an output file.
The Delete files tab allows you to define files to delete. They are deleted from the remote working directory after receiving output files. If you are using a shared working directory, this tab is not available.
Select
to delete the whole directory including its content.Click
to add another file to delete.Type the Working file name or click or to browse for the file.
Click
to delete a file.
Run Options
This node has general Run Options. The number of supported options is individual for each node.
Setting Environment Variables
Due to different shells on Linux systems, the command to set an environment variable may differ. It can be changed in the %appdata%\Roaming\Ansys\optiSLang\optiSLang_PuTTY_SSH.ini config file. Available commands are:
Value | Example Command |
---|---|
export (default) | export MYPWD=$PWD |
setenv | setenv MYPWD $PWD |
declare | declare -x MYPWD=$PWD |
"" | MYPWD=$PWD |
Troubleshooting
I need to change the PuTTY executable path because optiSLang cannot find the PuTTY executable or for some other reason.
Open the %APPDATA%/Ansys/optiSLang/optiSLang_PuTTY_SSH.ini configuration file.
Change the value of
putty_install_path
to the location of PuTTY (for example, tools/putty) in your latest optiSLang installation
Supported Versions
See the Supported Integration Versions table.