7.2.2. Editing RSM Application Settings (rsm.exe | rsmutils appsettings)

You can use the RSM Utilities application to query or edit any setting in the RSM\Config\Ans.Rsm.AppSettings.config file.

The appsettings command has two possible operators: get (for querying) and set (for editing).

To query or edit a setting in the Ans.Rsm.AppSettings.config file, you must know the name of the section in which the setting is located (SectionName), and the name of the setting (SettingName). In the following excerpt from the Ans.Rsm.AppSettings.config file, the SectionName is Global, and the first SettingName is DiskSpaceLowWarningLimitGb:

<appSettings name="Global">
    <add key="DiskSpaceLowWarningLimitGb" value="2.0" />
    <add key="IdleTimeoutMinutes" value="10" />
    <add key="PingServerTimeout" value="3000" />
    <add key="PingServerMaxRetries" value="4" />
    <add key="PortInUseTimeout" value="5000" />
    <add key="RemotingSecureAttribute" value="false" />
    <add key="EnablePerformanceLogging" value="false" />

Important:  If you edit settings in the Ans.Rsm.AppSettings.config file, you may need to restart RSM services in order for the changes to take effect.


Windows:

To query a setting, run the following command in the [RSMInstall]\bin directory:

rsm.exe appsettings get SectionName SettingName

To edit a setting, run the following command in the [RSMInstall]\bin directory:

rsm.exe appsettings set SectionName SettingName Value

Linux:

To query a setting, run the following command in the [RSMInstall]/Config/tools/linux directory:

rsmutils appsettings get SectionName SettingName

To edit a setting, run the following command in the [RSMInstall]/Config/tools/linux directory:

rsmutils appsettings set SectionName SettingName Value

Examples

The appsettings command is used in the following sections in this user's guide:

7.2.2.1. Specifying a Port Range for User Proxy Processes

When the cluster submit host is a remote machine, the RSM launcher service launches a user proxy process on the submit host which performs operations such as job submission, monitoring, and file transfer on the user's behalf. This means that there is a separate proxy process created for every user who submits a job to RSM. Each user proxy process will use a separate port chosen by RSM. By default, RSM will randomly select a port that is free from the 1000-2000 range. If you want to control which ports RSM can choose, you can specify a port range using the RSM Utilities application, which modifies the user proxy PortRange value in the RSM\Config\Ans.Rsm.AppSettings.config file.

To specify a port range for user proxy processes:

Windows: Run the following command in the [RSMInstall]\bin directory:

rsm.exe appsettings set UserProxy PortRange <PortRange>

Linux: Run the following command in the [RSMInstall]/Config/tools/linux directory:

rsmutils appsettings set UserProxy PortRange <PortRange>

For example, to set a port range of 2000-9000, you would enter the following:

appsettings set UserProxy PortRange 2000-9000

7.2.2.2. Specifying a Port Range for User Proxy Socket File Transfers

When the cluster submit host is a remote machine, the RSM launcher service launches a user proxy process on the submit host which transfers files to the cluster on the user's behalf. When this occurs, a port is opened for each file being transferred. By default, RSM will randomly select a port that is free. If you want to control which ports RSM can choose, you can specify a port range using the RSM Utilities application, which modifies the user proxy SocketTransfererPortRange value in the RSM\Config\Ans.Rsm.AppSettings.config file.

To specify a port range for socket file transfers:

Windows: Run the following command in the [RSMInstall]\bin directory:

rsm.exe appsettings set UserProxy SocketTransfererPortRange <PortRange>

Linux: Run the following command in the [RSMInstall]/Config/tools/linux directory:

rsmutils appsettings set UserProxy SocketTransfererPortRange <PortRange>

7.2.2.3. Specifying a Directory for RSM Configuration Files

By default, the directory in which RSM configurations are stored resolves to %APPDATA%\ANSYS\v242\RSM on Windows or ~/.ansys/v242/RSM on Linux, where ~ is the home directory of the account under which RSM is being run. When you submit a job in a client application, RSM reads the configuration files in this directory to acquire information about the HPC resource and determine how the job will be submitted to that resource.

Since the default directory is associated with a specific user account, it may not be an appropriate directory for storing configuration files if you plan to share the directory with other users. For more information, see Sharing and Accessing RSM Configurations.

You can change this to a different directory using the RSM Utilities application, or by editing the RSM\Config\Ans.Rsm.AppSettings.config file.

7.2.2.3.1. Querying the Location of the RSM Configuration Directory

You can use the RSM Utilities application to determine which directory is currently set as the RSM configuration directory. The directory is also listed in the ConfigurationDirectory setting in the RSM\Config\Ans.Rsm.AppSettings.config file.

To query the location of the RSM configuration directory:

Windows: Run the following command in the [RSMInstall]\bin directory:

rsm.exe appsettings get JobManagement ConfigurationDirectory

Linux: Run the following command in the [RSMInstall]/Config/tools/linux directory:

rsmutils appsettings get JobManagement ConfigurationDirectory

7.2.2.3.2. Specifying the Location of the RSM Configuration Directory

You can use the RSM Utilities application to change the directory in which RSM configurations will be saved when you generate them. The directory that you specify will populate the ConfigurationDirectory setting in the RSM\Config\Ans.Rsm.AppSettings.config file.

If you want to share RSM configurations with other users you can make the chosen configuration directory a shared directory so that users can retrieve configurations from it. Users can then map or mount the shared directory on their local machines and point their ConfigurationDirectory setting to it using the same steps presented in this section.

Follow the appropriate set of instructions below to change the RSM configuration directory.

Windows
  1. If the RSM launcher service is currently running, stop it. As an administrator, run net stop RSMLauncherService242.

  2. Open a command prompt in the [RSMInstall]\bin directory.

  3. Issue the following command, replacing the path with the desired value:

    rsm.exe appsettings set JobManagement ConfigurationDirectory c:\some\folder

    You can specify a local path if the directory is on the local machine, or a UNC path if the directory is a network share.

    Note that RSM will add the required sub-folders ANSYS\v242\RSM to the specified folder if they do not already exist (for example, if you specified the path c:\some\folder). Any new configurations that you create will be saved to this sub-location (for example, C:\some\folder\ANSYS\v242\RSM). This should also be your target location if you are copying existing configuration files from another source.

Linux
  1. If the RSM launcher service is currently running, run [RSMInstall]/RSM/Config/tools/linux/rsmlauncher stop.

  2. Run the rsmutils shell script located in the [RSMInstall]/Config/tools/linux directory. Issue the following command, replacing the path with the desired value:

    rsmutils appsettings set JobManagement ConfigurationDirectory /some/folder

    You can specify a local path, UNC path on Windows, or mounted file system on Linux depending on where the directory resides.

    Note that RSM will add the sub-folders ANSYS/v242/RSM to the specified folder if they do not already exist (for example, if you specified the path /some/folder). Any new configurations that you create will be saved to this sub-location (for example, /some/folder/ANSYS/v242/RSM). This should also be your target location if you are copying existing configuration files from another source.