|
In most compute environments today, users have a personal desktop (running the Windows operating system) and have access to a remote cluster to perform their simulations. The remote cluster usually consists of a few to hundreds of powerful machines that are used by many different users. This is very efficient for running your CFD-ACE+ simulation, but what about grid generation, monitoring the progress of the simulation, or post processing the results on the remote machine? These are all interactive applications and require a user interface to use. In this case, it may be necessary to display the application, such as CFD-VisCART, back to your desktop using an X server.
Why use an X server to display back to your desktop? Most desktops have a limit of 2Gb of RAM, which limits the size of the model that can be run on your machine. Another reason is that you are working with other applications on your desktop and do not want to slow your machine down. While these are probably the most common reasons to use a remote machine, there could be other situations where it would be useful to display remotely.
What tools are available for displaying remotely? Cygwin is a free tool that provides you with a Unix-like environment on a Windows operating system. Cygwin provides the user with a Unix-like shell where you can execute Unix commands, such as ls, grep, find, etc., as well as execute shell scripts. Also included in Cygwin is startx, which allows you to display applications remotely to your desktop.
Using startx:
To use startx, the first thing you need is Cygwin, which can be found here. Once you have downloaded Cygwin and installed it on your machine, you are ready to use startx.
From a Cygwin shell, simply type startx in the command line. This will start an X terminal, which will be used for remote display. In the X window, type "xhost +", as shown in Figure 1. The xhost command is used to add and delete hosts (remote machines) which are allowed to the X server. The "+" argument to the command simply allows all hosts to connect to the X server. If you only want to allow a specific machine to connect to the X server, you need to specify the host name for the machine after the xhost command. For example, if we need to connect to a machine named "kramer", the command would be "xhost kramer".
Figure 1. The xhost command in the X terminal.
Now that all hosts have been added, login to the remote machine using telnet or ssh. In this example, ssh is used to connect to the remote machine, as shown in Figure 2.

Figure 2. Connect to the remote machine using ssh.
Once you are connected to the remote machine, the display needs to be set to your local machine and now the remote machine. Depending on the type of shell you are running, you will need to use the export (bash shell) or setenv (t or c shell) to set the DISPLAY environment variable on the remote machine. To determine the type of shell you are using, you can type "echo $SHELL". To view the current setting for DISPLAY, you can type "echo $DISPLAY".
In this example, the remote machine is "hugo-00" and the local machine is "whkxp". For a bash shell, execute the following command to set the display to "whkxp":
export DISPLAY=whkxp:0
For a t or c shell, execute the following command:
setenv DISPLAY whkxp:0
Once this command has been executed, you can check the DISPLAY environment variable using "echo $DISPLAY" to see that the display is set to the local machine. If you have multiple displays, you can specify a value other than "0" to direct the display to your desired monitor.
Now that the display is set to your local machine, you can start any of the ESI CFD applications on the remote machine. As an example, you can start CFD-VisCART by typing "XCFD-VisCART" on the command line and hitting return. You are now ready to start meshing your model using CFD-VisCART. Figure 3 shows the remote display of CFD-VisCART.
Figure 3. Remote Display of CFD-VisCART
Note the "X" that is used when launching CFD-VisCART. By using "X", you will be launching CFD-VisCART with no OpenGL hardware acceleration, which in some cases may cause problems when displaying remotely.
Here are some other software packages that enable remote display:
Regards,
William Kuykendall
ESI CFD Support Team
|