- Why GraalVM?
- Getting Started
- Release Notes
- Reference Manual
- GraalVM Updater
- JVM Languages Reference
- LLVM Languages Reference
- Python Reference
- R Reference
- Ruby Reference
- Scala Reference
- Native Image
- Polyglot Reference
- Embedding Reference
- Tools Reference
- GraalVM as a Platform
- Security Guide
Some languages and functionalities are not part of the GraalVM core distribution and must be downloaded and installed separately. These include:
- GraalVM Native Image – a technology to compile an application ahead-of-time into a binary that runs natively on the system.
- Polyglot capabilities – support for Ruby, R and Python.
To assist you with this installation, these features are pre-packaged as
Components. The GraalVM installation contains the GraalVM Updater
gu, that can be used to manage components. GraalVM Updater also
verifies whether the version of the component is appropriate for your GraalVM
installation. Component packages are released for each GraalVM release with
respective updates. Component packages downloaded for previous release(s) cannot
be used with newer ones. Add the GraalVM
/bin folder to your
environment variable in order to deploy the
gu installer tool.
There is a command-line help available.
gu -h to get commands overview.
gu <command> -h to get help specific for the particular command, for example
gu install -h.
Component Installation Modes
Two modes of a component installation are supported:
You download the component package yourself and GraalVM Updater will install it. The following pre-built language packages are at your disposal:
With the already downloaded component package archive,
the component can be installed as
gu -L install component.jar
-L option, equivalent to
--local-file, tells to install from a downloaded component archive.
Installation from Catalog
There is a list of components maintained by Oracle, from which you can install a component just by its name. GraalVM Updater first downloads the list of components, then uses the information in the list to download the actual component package for you and install it. This is the default mode of operation.
To see which components are available in the catalog, use
to get a list of available components, their IDs, and descriptive names. Then,
ComponentId (for example
ruby) can be used as
gu install ruby
and that is all!
If you want to see more verbose messages during installation, you may use the
--verbose switch to see the download progress bar and verbose messages.
Installed components can be printed by
GraalVM Updater can list components in the component catalog (not necessarily installed on your machine):
GraalVM components used to create guest language implementations may change over time, requiring a Native Image to be rebuilt. Polyglot native image and polyglot native C library may be out of sync, particularly:
- new languages may not be accessible;
- removed languages may cause the native binary to fail on missing resources or libraries.
To rebuild and refresh the native binaries, use the following command:
gu rebuild-images [--verbose] polyglot|libpolyglot|js|llvm|python|ruby [custom native-image args]
Components may be uninstalled from the GraalVM environment when you no longer
need them. To uninstall a specific component you need to know its
which can be
python. The command to uninstall the component
gu remove ruby
If more components end with, for example,
ruby, the installer will print an
error message that you need to use component’s full names (
The uninstallation removes the files created during the installation. If a file
belongs to multiple components, it will be removed when the last component using
it is removed.
If GraalVM Updater needs to reach the component catalog, or download a
component package, it may need to pass through your HTTP proxy, if your network
uses one. On macOS, the proxy settings are automatically obtained from the OS.
On Linux, you must ensure that the
variables are set appropriately before you launch
gu. Please refer to your
distribution and/or desktop environment documentation for the details.
Replacing Components and Files
A component may be only installed once. GraalVM Updater refuses to install a
component if a component with the same ID is already installed. But the
installed component may be replaced. GraalVM Updater first uninstalls the
component and then installs the new package. To replace a component, use the
-r option. The
-L option tells to treat parameters as local filename of a packaged component.
gu install -L -r component.jar gu install -r ruby
The process is the same as if
gu remove is run first and
gu install next.
GraalVM Updater also refuses to overwrite existing files if the to-be-installed
and existing versions differ. There are cases when you may need to refresh file
contents, if they were modified or damaged. Use the
gu install -L -o component.jar gu install -o ruby
GraalVM Updater will just instruct to replace the contained files of a
component. By default, it will not alter anything. You can also use
--force) option, which disables most of the checks and allows you to install
If a language component is not installed running the code that tries to initialize the language context can result in an exception like this:
java.lang.ExceptionInInitializerError Caused by: com.oracle.truffle.polyglot.PolyglotIllegalArgumentException: A language with id '$language' is not installed. Installed languages are: [js, llvm].
If you see a problem like that, install the language component as explained on this page above.