Installing and Starting GridGain
This chapter explains system requirements for running GridGain, how to install GridGain, and how to start a GridGain node.
Since GridGain is built on top of Apache Ignite, GridGain reuses Ignite’s system properties, environment properties, startup scripts, etc. wherever possible.
Prerequisites
GridGain was officially tested on:
JDK |
Oracle JDK 8 and later, Open JDK 8 and later, IBM JDK 8 and later |
OS |
Linux (any flavor), Mac OSX (10.6 and up), Windows (XP and up), Windows Server (2008 and up), Oracle Solaris |
ISA |
x86, x64, SPARC, PowerPC |
Network |
No restrictions (10G recommended) |
If you use Java version 9 or later, see Running GridGain with Java 9 or later for details.
Running GridGain with Java 9 or later
To run GridGain with Java 9/10/11, follow these steps:
-
Set the
JAVA_HOMEenvironment variable or Windows PATH to point to the Java installation directory. -
GridGain uses proprietary SDK APIs that are not available by default. You need to pass specific flags to JVM to make these APIs available. If you use the start-up script
ignite.sh(orignite.batfor Windows), you do not need to do anything because these flags are already set up in the script. Otherwise, provide the following parameters to the JVM of your application:--add-exports=java.base/jdk.internal.misc=ALL-UNNAMED # Used to get access to java UNSAFE (access to offheap memory). --illegal-access=permit # Allows access to private fields without accessors, used for dependency injection in user classes (for example, @IgniteInstanceResource annotation). --add-exports=java.base/sun.nio.ch=ALL-UNNAMED # Used for java.nio Selector optimization. --add-exports=java.management/com.sun.jmx.mbeanserver=ALL-UNNAMED # Used to enable JMX monitoring capability. --add-exports=jdk.internal.jvmstat/sun.jvmstat.monitor=ALL-UNNAMED # Used to allow jvisualvm to connect to Ignite process. --add-exports=java.base/sun.reflect.generics.reflectiveObjects=ALL-UNNAMED # Used for fast object construction during marshalling/unmarshalling.
-
TLSv1.3, which is available in Java 11, is not supported at the moment. Consider adding
-Djdk.tls.client.protocols=TLSv1.2if SSL between nodes is used.
Installation
GridGain is available in three editions: Community Edition (CE), Enterprise Edition (EE) and Ultimate Edition (UE). For this example, we’ll use the GridGain CE, which is distributed as binary, docker, and cloud images, and via RPM/DEB. This chapter explains how to install the GridGain CE binary distribution.
To get started with the GridGain CE binary distribution:
-
Download the GridGain binary as a zip archive.
-
Unzip the zip archive into the installation folder in your system.
-
Move the
ignite-rest-httpfolder from{gridgain}/libs/optionalto{gridgain}/libsto enable the Ignite REST library for the cluster. The library is used by GridGain Web Console for cluster management and monitoring needs. -
(Optional) Enable required modules.
-
(Optional) Set the
IGNITE_HOMEenvironment variable or Windows PATH to point to the installation folder and make sure there is no trailing/(or\for Windows) in the path.
Starting a GridGain Node
You can start a GridGain node from the command line using the default configuration or by passing a custom configuration file. You can start as many nodes as you like and they will all automatically discover each other.
With Default Configuration
To start a GridGain node with the default configuration, open the command shell and, assuming you are in GridGain installation directory, run this from the command line:
$ bin/ignite.sh
$ bin\ignite.bat
You will see output similar to this:
[02:49:12] Ignite node started OK (id=ab5d18a6) [02:49:12] Topology snapshot [ver=1, nodes=1, CPUs=8, heap=1.0GB]
By default, ignite.sh|bat starts a node with the default configuration file: config/default-config.xml.
With Custom Configuration
To start a GridGain node with a custom configuration file, open the command shell and, assuming you are in IGNITE_HOME (the GridGain installation folder), pass the configuration file as a parameter to
ignite.sh|bat as follows:
$ bin/ignite.sh examples/config/example-ignite.xml
$ bin\ignite.bat examples\config\example-ignite.xml
You will see output similar to this:
[02:49:12] Ignite node started OK (id=ab5d18a6) [02:49:12] Topology snapshot [ver=1, nodes=1, CPUs=8, heap=1.0GB]
Congratulations! You’ve just launched your first GridGain cluster.
© 2021 GridGain Systems, Inc. All Rights Reserved. Privacy Policy | Legal Notices. GridGain® is a registered trademark of GridGain Systems, Inc.
Apache, Apache Ignite, the Apache feather and the Apache Ignite logo are either registered trademarks or trademarks of The Apache Software Foundation.