Select your cookie preferences

We use essential cookies and similar tools that are necessary to provide our site and services. We use performance cookies to collect anonymous statistics, so we can understand how customers use our site and make improvements. Essential cookies cannot be deactivated, but you can choose “Customize” or “Decline” to decline performance cookies.

If you agree, AWS and approved third parties will also use cookies to provide useful site features, remember your preferences, and display relevant content, including relevant advertising. To accept or decline all non-essential cookies, choose “Accept” or “Decline.” To make more detailed choices, choose “Customize.”

Prerequisites for connecting Amazon Neptune databases using IAM authentication

Focus mode
Prerequisites for connecting Amazon Neptune databases using IAM authentication - Amazon Neptune

The following are instructions for installing Apache Maven and Java 8 on an Amazon EC2 instance. These are required for the Amazon Neptune Signature Version 4 authentication samples.

To Install Apache Maven and Java 8 on your EC2 instance
  1. Connect to your Amazon EC2 instance with an SSH client.

  2. Install Apache Maven on your EC2 instance. First, enter the following to add a repository with a Maven package.

    sudo wget https://repos.fedorapeople.org/repos/dchen/apache-maven/epel-apache-maven.repo -O /etc/yum.repos.d/epel-apache-maven.repo

    Enter the following to set the version number for the packages.

    sudo sed -i s/\$releasever/6/g /etc/yum.repos.d/epel-apache-maven.repo

    Then you can use yum to install Maven.

    sudo yum install -y apache-maven
  3. The Gremlin libraries require Java 8. Enter the following to install Java 8 on your EC2 instance.

    sudo yum install java-1.8.0-devel
  4. Enter the following to set Java 8 as the default runtime on your EC2 instance.

    sudo /usr/sbin/alternatives --config java

    When prompted, enter the number for Java 8.

  5. Enter the following to set Java 8 as the default compiler on your EC2 instance.

    sudo /usr/sbin/alternatives --config javac

    When prompted, enter the number for Java 8.

PrivacySite termsCookie preferences
© 2025, Amazon Web Services, Inc. or its affiliates. All rights reserved.