Enable CLI Access on Windows

This section explains how to set up a Window user's command prompt environment to have the proper context for the user to run installed Altair Accelerator programs from the command line. The programs that are run from the command line are called the CLI commands.

Altair Accelerator products require that the PATH environment variable be set to include the directories in the Altair Accelerator release which hold programs that will be run from the command line. Also, there are two environment variables that need to be set so that when an Altair Accelerator program is run, it will know where the release is installed and know what type of machine it is running on. These two environment variables are VOVDIR and VOVARCH.

There are two methods for setting the correct environment. Both involve running the same context-setting bat script. This context-setting bat script establishes the correct environment variables for the local situation, reflecting where Altair Accelerator products are installed.
Note: This operation to set the environment is not required to use every Altair Accelerator feature on Windows. This operation is only needed to enable using the CLI commands from the command prompt.

Method 1: Use Windows Explorer to Set Command Line Environment

  1. Using Windows Explorer, navigate to the Altair Accelerator installation directory.
  2. Enter the win64/startup folder and double-click the vovcmd.bat script to run it.
    This will open a command prompt with the proper environment settings for the Altair Accelerator and scripts to work.
When vovcmd.bat runs, it will execute the win64/bat/vovinit.bat script as part of what it does. The following section covering Method 2 explains what win64/bat/vovinit.bat does when it runs. It does the same thing when run by either method.

Method 2: Using Windows Command Prompt to Set Command Line Environment

  1. In a command prompt window, navigate to the Altair Accelerator installation directory using the cd command.
  2. Change directory to the win64/bat folder with cd and run the vovinit.bat script.
    This will establish the needed environment for the open command prompt.
When win64/bat/vovinit.bat runs, it figures out needed environment variables and sets them, based upon where it is located. In particular, it sets VOVDIR to be the path to where Altair Accelerator is installed. It then executes another initialization script, $VOVDIR/win64/local/vovinit.bat, if it exists.

This is an initialization script that you can create and modify to perform site specific activities customized for your local configuration and usage. You can add commands to the local/vovinit.bat file that you want to run whenever a user starts up a command prompt.

After running both vovinit.bat scripts, the context of the command prompt has the correct environment needed so that CLI commands will work correctly with the installed Altair Accelerator.

Customize Actions Needed to Enable Access to Altair Accelerator Products on Windows

You can add commands to the win64/local/vovinit.bat file that perform specific operations that enable your Windows users to access Altair Accelerator programs properly, or to set up things on the machine to follow a standard convention.

You could add operations that perform actions such as these, and others:
  • Mounting network drives
  • Setting environment variables for local needs
  • Establishing time synchronization
Example of a custom $VOVDIR/win64/local/vovinit.bat
rem -- Mount network drives:
rem -- In this example we mount the Altair Accelerator installation on drive v:
if not exist v:\nul net use v: \\somehost\rtda

rem -- Set locally useful environment variables.
set VNCSWD=v:\vnc
set DLOG=d:\dailylog

rem -- Set Windows time from server on local network
rem -- Put this last; it may fail if lacking time set privilege
net time \\timehost /set /y

Verify Context Is Working

When you have a command prompt open and expect that it has a context for accessing Altair Accelerator programs, check that the environment is set by looking at environment variables to note that the PATH value contains a reference to the folders in the release which hold programs, and to note that VOVDIR and VOVARCH are set. VOVDIR should contain the path to the installation. VOVARCH should contain the name that matches the machine it is running on.

Beyond just looking, you can try running a program as a positive test that the context is set up properly. One program that is simple to run and is available with all Altair Accelerator products is vovarch. This program reports on the machine type on which it is running. A side effect is that it tests that needed environment variables are set properly. If the environment is valid, the program will run and report the correct machine type. If the environment is not valid, the program will not work.

Run vovarch to verify the environment is set ok:
c:\ > vovarch
win64
Note: The output will always show win64 when running on any of the Microsoft Windows operating systems. This result is expected. It reports that we are on a generic "windows" architecture and indicates that the context is working.

If you are not able to verify that the context is valid, check the details within the /folder/where/Altair Accelerator/software/is/installed/win64/bat/vovinit.bat file.

Enable the Command Prompt to Communicate With a Running Product Server

If you need to issue commands that will communicate to a running product instance, the instance will need to be "enabled", which involves setting certain environment variables that point the commands to the location of the running vovserver.
 c:\ > vovproject enable instance-name 

Some common instance names are "licmon" (for Monitor), "vnc" (for Accelerator), and "wx" (for Accelerator Plus). Instance names can be anything though since they are user-definable upon first start of each product.