== Client-server visualization on Cedar, Graham and Béluga==
We have several versions of VisIt installed on the clusters. You can see them by running ''module spider visit''. To use remote VisIt in client-server mode, on your laptop you need the matching major version, either 2.12.x or 2.13.x or 3.2.x. Before starting VisIt, download the host profile XML file [https://nextcloud.computecanada.ca/index.php/s/aGeScGwF8RKJJji/download host_cedar.xml] -- this config file is for connecting to VisIt 3.2.1.
* On Linux/Mac, copy the file to ''~/.visit/hosts/.''
* On Windows, copy the file to ''My Documents\VisIt 3.2.1\hosts'' or similar directory.
Start VisIt on your laptop; in the main menu, under ''Options -> Host Profiles'', you should see the ''cedar'' host profile. If you want to do remote rendering on Graham instead, set
Host nickname = graham
Remote host name = graham.alliancecan.ca
For both Cedar and Graham, set your CCDB username.
Username = yourOwwUserName
With the exception of your username, your settings should be similar to the ones shown below:
[[File:HostSetting.png|880px]]
In the same setup window, click on the ''Launch Profiles'' tab. You should see two profiles (''login'' and ''slurm''):
[[File:LaunchProfiles.png]]
* The ''login'' profile is for running the engine on a login node, which we do not recommend for heavy visualizations.
* The ''slurm'' profile is for running the engine inside an interactive job on a compute node. If you are planning to do this, select the ''slurm'' profile and then click on the ''Parallel'' tab and below it on the ''Advanced'' tab. In the ''Launcher arguments'' field, replace ''--account=def-someuser'' by your default allocation, as shown below.
* On Cedar only, add the flag "--chdir=/scratch/username", specifying your actual username, to launch your job from your scratch directory.
[[File:LauncherBasicArguments.png]]
[[File:LauncherAdvancedArguments.png]]
Save the settings with ''Options -> Save Settings'' and then exit VisIt on your laptop for settings to take effect.
If your account has multifactor authentication enabled, you will need to [[Multifactor_authentication#Configuring_your_SSH_client_with_ControlMaster|configure your SSH client with ControlMaster]] and make sure to use the full host name for Host, e.g.
Host cedar.alliancecan.ca
HostName cedar.alliancecan.ca
User
ControlPath ~/.ssh/cm-%r@%h:%p
ControlMaster auto
ControlPersist 10m
Next, log into the cluster in a terminal window. Finally, relaunch VisIt on your computer, start the file-open dialogue and change the local host to cedar (or graham). Hopefully, the connection is established, the remote VisIt Component Launcher gets started on the cluster's login node, and you should be able to see the cluster's filesystem, navigate to your file and select it. You will be prompted to select either the login (rendering on the login node) or slurm (rendering inside an interactive Slurm job on a compute node) profile. If you select the slurm profile, you will need to specify the number of nodes and processors and the maximum time limit:
[[File:SelectProfile.png]]
Click on ''OK'' and wait for VisIt's engine to start. If you selected rendering on a compute node, it may take some time for your job to get started. Once your dataset appears in the ''Active source'', the VisIt's engine is running and you can proceed with creating and drawing your plot.