This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
howto:licensing [2022/04/07 22:16] ccrosby |
howto:licensing [2025/01/29 09:00] (current) ccrosby [SSH tunneling] |
||
|---|---|---|---|
| Line 49: | Line 49: | ||
| - | === SSH tunneling === | + | ==== SSH tunneling |
| It is possible for compute nodes to communicate with the outside world using ssh-tunnels. | It is possible for compute nodes to communicate with the outside world using ssh-tunnels. | ||
| < | < | ||
| Line 76: | Line 76: | ||
| < | < | ||
| 196.24.44.124 | 196.24.44.124 | ||
| + | 196.24.44.6 | ||
| 196.24.44.129 | 196.24.44.129 | ||
| + | 196.24.44.83 | ||
| + | 154.114.44.7 | ||
| </ | </ | ||
| Line 88: | Line 91: | ||
| - Provide the CHPC with the license server port numbers as well as your license server' | - Provide the CHPC with the license server port numbers as well as your license server' | ||
| - Once all these configurations have been set, test the connectivity from the nodes login1 and chpclic1 in the cluster. | - Once all these configurations have been set, test the connectivity from the nodes login1 and chpclic1 in the cluster. | ||
| - | - | + | - Now you can attempt to check out the license from a compute node. Preferably first test this in an interactive PBS session, but the instructions are essentially the same as you would use in the following PBS job script snippet: |
| + | <file bash JobScriptSnippet.pbs> | ||
| + | # | ||
| + | #PBS -l select=.... etc | ||
| + | |||
| + | # Set up the required number of ssh-tunnels to the license server ports | ||
| + | ssh -f jblogs@chpclic1 -L *: | ||
| + | ssh -f jblogs@chpclic1 -L *: | ||
| + | # Set the appropriate license server environment variable. | ||
| + | # Please RTFM of the software that you are using | ||
| + | export LM_LICENSE_FILE=1234@localhost | ||
| + | # Now run your code with the normal command line | ||
| + | mpirun -np $nproc ...... | ||
| + | # Finally take down each of your ssh tunnels again | ||
| + | kill -9 `ps ux | grep "ssh -f" | grep -o -E ' | ||
| + | kill -9 `ps ux | grep "ssh -f" | grep -o -E ' | ||
| + | </ | ||
| + | |||
| + | ==== Alternative procedure for off-site license servers ==== | ||
| + | **If** the user has control over the off-site license server that they want to use, it is possible to access the license from inside the cluster by means of ssh-tunneling, | ||
| + | |||
| + | === Alternative instructions === | ||
| + | * The user must have the ability to run commands on the license server. | ||
| + | * Command line access to the license server is necessary. | ||
| + | * Let us assume that the license server is running the license service on port 2345. | ||
| + | * On the license server command line, create the ssh tunnel: | ||
| + | < | ||
| + | ssh -R *: | ||
| + | </ | ||
| + | * In plain English, this translates as: " | ||
| + | * Do the same for the second (or third) license port. Do not try to do this through login1 or chpclic1 with default Ansys license ports, because the Ansys ports are already being used on these servers. | ||
| + | * You can now access the license by setting the relevant environment variables as such in your job script: | ||
| + | < | ||
| + | export LM_LICENSE_FILE=2345@login1 | ||
| + | </ | ||
| + | * When you take down the license tunnel, kill the tunnel process on the license server. | ||