LIGHTWEIGHT GRID MANAGER TUTORIAL

Installation

The Wolfram Lightweight Grid Manager is installed when gridMathematica Server is installed. During installation, you can choose not to activate the Lightweight Grid. You would choose this option if you want to use gridMathematica Server but not use the Lightweight Grid or if you want to activate the Lightweight Grid manually.

What Installation Does

The full gridMathematica Server installation, including the Lightweight Grid Manager, carries out the following steps:

  • Installs a version of Mathematica to provide parallel kernels across the network. This is installed in a folder called gridMathematicaServer ("gridMathematica Server" on Windows).
  • Installs files for a server (this is a version of Apache Tomcat).
  • Creates an account (username and password) that runs the server, if requested.
  • Sets the server to run as a service when the machine is started.
  • Sets a password to allow web server configuration changes.
  • Starts the server running.

The installer gives you the option of activating the Lightweight Grid Manager, in which case it carries out the last four steps. If you do not want to use the Lightweight Grid Manager or you want to activate it manually, you would not choose to activate the Lightweight Grid. Remember that if you want to use a managed cluster or configure your own launching technology, you will not want to activate the Lightweight Grid. The "Introduction" has a summary of the Lightweight Grid technology.

The installer always installs a version of Mathematica for parallel computation. This is installed in a folder called gridMathematicaServer ("gridMathematica Server" on Windows), and by default it will appear in the standard location for the type of computer on which the installer is running.

If you choose to let the installer activate the Lightweight Grid server, here are some recommendations:

  • Run the installer with administrative privileges. This is necessary to let it create the account and set the server as a service.
  • Decide what user account the server will use. This account runs the server and it also runs the Mathematica parallel kernels. You can create a new account or use an existing one.
  • Decide on the web administrator password to use. This password allows the web interface to make configuration changes.
  • Check that the server port is not in use already. The server listens for HTTP connections on port 3737. You can change the port after installation.
  • Check that your software firewall allows other hosts to connect to port 3737. Check that your software firewall allows traffic both ways on port 5353 (mDNS) to allow the service discovery technology to function.

Windows

When you run the gridMathematica Server installer, make sure that you have decided whether to activate the Wolfram Lightweight Grid Manager. The section "What Installation Does" should help you to decide. Whichever you do, you should make sure that Mathematica or an installation of the Lightweight Grid is not running.

If you do not let the installer activate the Lightweight Grid, then it will run very similarly to the regular Mathematica installer.

If you let the installer activate the Lightweight Grid, then you should make sure you run it with administrative privileges. As explained previously, the Lightweight Grid server needs a user account under which to run. This account also runs the Mathematica parallel kernels that the Lightweight Grid launches. The installer gives you the option of creating a new account or using an existing account. If you are are not sure which option to choose, then creating a new account is recommended.

The installer will also ask you to enter a password to use for making administrative changes through the web interface. It is a good practice to use a different password from that used in the account that runs the server.

When the installer has finished it may suggest a restart of the system. If it does then it is a good idea to restart. When the system restarts, the server should be running and you can connect to the web interface and install a Mathematica license.

If the installer does not suggest a restart of the system, it will suggest connecting to the web interface and installing a Mathematica license.

You can see more details about operation of the Lightweight Grid in the section "Service Operation: Windows".

To uninstall gridMathematica Server, including the Lightweight Grid, you would use the normal procedure for uninstalling programs under Windows. Typically, it is good practice to stop the service before running the uninstaller. If the installer created a user, the user account will be deleted but its documents and settings folder will be retained.

Linux

When you run the gridMathematica Server installer, make sure that you have decided whether to activate the Wolfram Lightweight Grid Manager. The section "What Installation Does" should help you to decide. Whichever you do, you should make sure that Mathematica or an installation of the Lightweight Grid is not running.

The installer can only activate the server for certain operating systems. If your operating system is not supported for activation, then do not let the installer activate the Lightweight Grid. Follow a manual process instead. At present, we have tested Lightweight Grid installation for the following Linux distributions: CentOS 5.2, Red Hat Enterprise Linux WS 4, and Ubuntu 8.0.4.

If you do not let the installer activate the Lightweight Grid, then it will run very similarly to the regular Mathematica installer.

If you let the installer activate the Lightweight Grid, then you should make sure you run it with root privileges, such as with the sudo command. As explained previously, the Lightweight Grid server needs a user account under which to run, and this account also runs the Mathematica parallel kernels that the Lightweight Grid launches. The installer gives you the option of creating a new account or using an existing account. If you are not sure which option to choose, then creating a new account is recommended.

The installer will also ask you to enter a password to use for making administrative changes through the web interface. It is a good practice to use a different password from that used in the account that runs the server.

When setup is complete, you should connect to the web interface using http://localhost:3737/WolframRemoteServices/Licensing/ and install a Mathematica license.

You can see more details about operation of the Lightweight Grid in the section "Service Operation: Linux". This also contains information on manual configuration of the Lightweight Grid in case you do not activate it from the installer.

To uninstall gridMathematica Server, including the Lightweight Grid, you would shut down the server, remove /etc/init.d/wolframlightweightgrid, remove other init scripts, and delete the installation directory. If the installer created a user account, you will need to manually delete the user account and remove the home directory if desired. This is typically done with the userdel command. The following shows an example of these steps.

linux> sudo /etc/init.d/wolframlightweightgrid stop
linux> sudo rm /etc/init.d/wolframlightweightgrid
linux> sudo rm /etc/rc3.d/S99wolframlightweightgrid
linux> sudo rm /etc/rc3.d/K99wolframlightweightgrid
linux> sudo rm /etc/rc4.d/S99wolframlightweightgrid
linux> sudo rm /etc/rc4.d/K99wolframlightweightgrid
linux> sudo rm /etc/rc5.d/S99wolframlightweightgrid
linux> sudo rm /etc/rc5.d/K99wolframlightweightgrid
linux> sudo rm -rf /usr/local/Wolfram/gridMathematicaServer/9.0
linux> sudo userdel -r wolframgrid

Mac OS X

When you run the gridMathematica Server installer, make sure that you have decided whether to activate the Wolfram Lightweight Grid Manager. The section "What Installation Does" should help you to decide. Whichever you do, you should make sure that Mathematica or an installation of the Lightweight Grid is not running.

On the Macintosh, gridMathematica Server is built as a Macintosh bundle application, contained in a folder named gridMathematicaServer.app. When you unpack the archive, it is suggested that you copy the application into /Applications, though it could be installed elsewhere. Once you have copied gridMathematicaServer.app you should launch it. This opens a configuration tool that will let you set up the Lightweight Grid. Typically, on starting the configuration tool Mac OS X will ask for authentication to get root privileges.

If you do not launch the gridMathematica Server application, then the Lightweight Grid will not get set up.

As explained previously, the Lightweight Grid server needs a user account under which to run. This account also runs the Mathematica parallel kernels that the Lightweight Grid launches. The installer gives you the option of creating a new account or using an existing account. If you are are not sure which option to choose, then creating a new account is recommended.

The installer will also ask you to enter a password to use for making administrative changes through the web interface. It is a good practice to use a different password from that used in the account that runs the server.

When setup is complete, you should connect to the web interface using http://localhost:3737/WolframRemoteServices/Licensing/ and install a Mathematica license.

You can see more details about operation of the Lightweight Grid in the section "Service Operation: Mac OS X". This also contains information on manual configuration of the Lightweight Grid in case you do not activate it with the setup application.

To uninstall gridMathematica Server, including the Lightweight Grid, you would shut down the service, remove the entry in /Library/StartupItems, and delete gridMathematicaServer.app. If the installer created a user account, you will need to manually delete the user account and remove the home directory if desired. The following shows an example of these steps.

macosx> sudo /sbin/SystemStarter stop "Wolfram Lightweight Grid"
macosx> sudo rm -rf /Library/StartupItems/WolframLightweightGridManager
macosx> sudo rm -rf /Applications/gridMathematicaServer.app
macosx> sudo /usr/bin/dscl . delete /Users/wolframgrid
macosx> sudo rm -rf /Users/wolframgrid

Testing and Configuring

When you have finished installing the Lightweight Grid and you think that it is running, you can use the web interface to carry out configuration and testing.

The main feature for configuration is to install a Mathematica license. There is a convenient way to do this with the Licensing tab of the web interface. After this you can check the license status in the Kernel Settings tab of the web interface by examining the LicenseState property. If this says the license is valid, then your server should be ready for operation.

If you installed gridMathematica Server into a non-default location, you should confirm that the value of the KernelCommand property is correct. You can see this in the Kernel Settings tab of the web interface.

New to Mathematica? Find your learning path »
Have a question? Ask support »