How to automate configuration of clients and remote servers
Most processing in Deephaven installations takes place on core servers running roles like Data Import Server, Query Server, or Merge Server. The Deephaven installation and upgrade processes ensure that these machines have all needed binaries and configuration files so that processes running on them, such as loggers and tailers, can connect to infrastructural Deephaven services.
For other systems to connect to a Deephaven installation, they need most of the same binaries and configuration files that are installed on the core Deephaven servers. Client systems running the Deephaven Console typically get these files from the Deephaven Launcher. At each connection to a Deephaven installation, the Launcher checks to verify that it has the latest files from the server, and downloads newer files as needed.
However, it is also common to run remote services, such as loggers and tailers, on machines that are not used for interactive Consoles. For these systems, the IrisConfigurationUpdater
class can be used to script or run a command line update of needed components. This class is part of the Deephaven Launcher, and the whole process of installing the Launcher and using this class in "headless" installations is detailed below.
For Windows Systems
- Download and silently install the Deephaven launcher at https://server.name:8443/ . Substitute your server name in the URL. This is a one-time install per system.
DeephavenLauncherSetupWithJdk1.8.0_162_X.XX.exe /S
Note
Be sure to update the command with the current Launcher version number (e.g., 8.12).
- Create instance (one time per instance per system).
For example, the following creates a DR instance directory under the instances root (default %AppData%\..\Local\Illumon)
:
mkdir %AppData%\..\Local\Illumon\DR
- Create the instance
getdown.txt
file to indicate where to get client files. For example:
echo appbase=https://deephaven-server-01.acme.com/iris/ > %AppData%\..\Local\Illumon\DR\getdown.txt
Note
Replace the above URL with the correct URL to your CUS server.
- Ideally, at each launch of client components, check for updates and download client files:
cd "C:\Program Files (x86)\Illumon"
%AppData%\..\Local\Illumon\jdk\bin\java -cp * com.illumon.iris.bootstrap.IrisConfigurationUpdater DR
- If a workspace path is needed for the class(es) being used (often required), create a path to be passed in the command line when executing classes.
mkdir %AppData%\..\Local\Illumon\DR\workspaces\default
The launch of a remote process accessing Deephaven will look similar to the following:
%AppData%\..\Local\Illumon\jdk\bin\java -cp %AppData%\..\Local\Illumon\DR\resources;%AppData%\..\Local\Illumon\DR\java_lib\*;[paths to any other resources] -server -Xmx256m -DConfiguration.rootFile=iris-common.prop -Dservice.name=iris_console -Dworkspace=%AppData%\..\Local\Illumon\DR\workspaces\default -Ddevroot=%AppData%\..\Local\Illumon\DR -DLoggerFactory.teeOutput=true -DWAuthenticationClientManager.defaultPrivateKeyFile=[key file] [class to be run and any program arguments]
For Non-Windows Systems
- Download and install the Deephaven launcher by extracting it from the tar file. Substitute your host name in the URL. This is a one-time install per system.
cd [your_install_folder]
tar -xvf [download_path]/DeephavenLauncher_X.XX.tar
Note
Be sure to update the command with the current Launcher version number (e.g. 8.08).
- Create instance (one time per instance per system).
For example, the following creates a DR instance directory under the instances root (default /Users/[username]/iris/.programfiles
on OSX or /home/[username]/iris/.programfiles
on UNIX/Linux):
mkdir [instances_root]/DR
- Create the instance
getdown.txt
file to indicate where to get client files. For example:
echo "appbase=https://deephaven-server-01.acme.com/iris/" > [instances_root]/DR/getdown.txt
Note
Replace the above URL with the correct URL to your CUS server.
- Ideally, at each launch of client components, check for updates and download client files:
cd [your_install_folder]
java -cp "./DeephavenLauncher/lib/*" com.illumon.iris.bootstrap.IrisConfigurationUpdater DR
- If a workspace path is needed for the class(es) being used (often required), create a path to be passed in the command line when executing classes. For example:
mkdir -p /home/[username]/Illumon/DR/workspaces/default
The launch of a remote process accessing Deephaven will look similar to the following:
java -cp "[instances_root]/DR/resources;[instances_root]/DR/java_lib/*;[paths to any other resources]" -server -Xmx256m -DConfiguration.rootFile=iris-common.prop -Dservice.name=iris_console -Dworkspace=/home/[username]/Illumon/DR/workspaces/default -Ddevroot=[instances_root]/DR -DLoggerFactory.teeOutput=true -DWAuthenticationClientManager.defaultPrivateKeyFile=[key file] [class to be run and any program arguments]