Search…
v6.0.0 (latest)
Loading and Exporting Data
CentOS/RHEL Enterprise/Free Editions CPU with Tarball
This is an end-to-end recipe for installing HEAVY.AI Enterprise Edition on a CentOS/RHEL 7 machine using a tarball.
The order of these instructions is significant. To avoid problems, install each component in the order presented.

Assumptions

These instructions assume the following:
  • You are installing on a “clean” CentOS/RHEL 7 host machine with only the operating system installed.
  • Your HEAVY.AI host only runs the daemons and services required to support HEAVY.AI.
  • Your HEAVY.AI host is connected to the Internet.

Preparation

Prepare your CentOS/RHEL 7 machine by updating the system, installing the Java Development Kit, creating a HEAVY.AI user, and enabling access to HTTP port 6273 through the firewall.

Update and Reboot

Update the entire system and reboot to activate the latest kernel.
1
sudo yum update
2
sudo reboot
Copied!

JDK

Follow these instructions to install a headless JDK and configure an environment variable with a path to the library. The “headless” Java Development Kit does not provide support for keyboard, mouse, or display systems. It has fewer dependencies, and is best suited for a server host. For more information, see http://openjdk.java.net/.
  1. 1.
    Open a terminal on the host machine.
  2. 2.
    Install the headless JDK using the following command:
    1
    sudo yum install java-1.8.0-openjdk-headless
    Copied!

Create the heavyai User

Create a group called heavyai and a user named heavyai, who will be the owner of the HEAVY.AI database. You can create the group, user, and home directory using the useradd command with the -U and -m switches.
1
sudo useradd -U -m heavyai
Copied!

Firewall

If it is not installed on your host machine, install firewalld.
1
sudo yum install firewalld
2
sudo systemctl start firewalld
3
sudo systemctl enable firewalld
4
sudo systemctl status firewalld
Copied!
To use Immerse, you must prepare your host machine to accept HTTP connections. You can configure your firewall for external access.
1
sudo firewall-cmd --zone=public --add-port=6273-6274/tcp --permanent
2
sudo firewall-cmd --reload
Copied!
Most cloud providers provide a different mechanism for handling firewall configuration. The commands above might not run in cloud deployments.

Installation

These instructions follow conventions of the HEAVY.AI Engineering team. By creating an heavyai-installs directory and using a symbolic link that points to the current version, you can conveniently roll back to a previous version in the unlikely event that you would want to do so.

Create the heavyai-installs Directory

Use the following command to create the /opt/heavyai-installs directory.
1
sudo mkdir /opt/heavyai-installs
Copied!

Download the HEAVY.AI Archive File

You can download the HEAVY.AI archive file using curl or wget.
To download the HEAVY.AI archive file with curl, use the following command.
1
sudo curl https://releases.heavy.ai/ee/tar/heavyai-ee-latest-Linux-x86_64-cpu.tar.gz --output /opt/heavyai-installs/heavyai.tar.gz
Copied!
To download the HEAVY.AI TAR file with wget, use the following command.
1
sudo wget https://releases.heavy.ai/ee/tar/heavyai-ee-latest-Linux-x86_64-cpu.tar.gz -O /opt/heavyai-installs/heavyai.tar.gz
Copied!

Expand the Archive File

You install the HEAVY.AI application itself by expanding the TAR file.
  1. 1.
    Go to the /opt/heavyai-installs directory.
  2. 2.
    Expand the HEAVY.AI archive file with the following command:
    1
    sudo tar -xvf heavyai.tar.gz
    Copied!
  3. 3.
    The expanded directory name is long and complex, with information about the version and build date. For example, the HEAVY.AI 6.0.0 directory name is the following:
    1
    heavyai-ee-6.0.0-20190827-0f29e432f1-Linux-x86_64-cpu
    Copied!
    Go to the /opt directory and create a symlink to heavyai, using the name of the expanded directory for the current release. For example, for HEAVY.AI 6.0.0, you use the following commands:
    1
    cd /opt
    2
    sudo ln -s /opt/heavyai-installs/heavyai-ee-6.0.0-20190827-0f29e432f1-Linux-x86_64-cpu heavyhai
    Copied!

Configuration

These are the steps to prepare your HEAVY.AI environment.

Set Environment Variables

For convenience, you can update .bashrc with the required environment variables.
  1. 1.
    Open a terminal window.
  2. 2.
    Enter cd ~/ to go to your home directory.
  3. 3.
    Open .bashrc in a text editor (for example, vi .bashrc).
  4. 4.
    Add the following export commands under “User specific aliases and functions.”
    1
    # User specific aliases and functions
    2
    export HEAVYAI_USER=heavyai
    3
    export HEAVYAI_GROUP=heavyai
    4
    export HEAVYAI_STORAGE=/var/lib/heavyai
    5
    export HEAVYAI_PATH=/opt/heavyai
    6
    export HEAVYAI_LOG=/var/lib/heavyai/data/mapd_log
    Copied!
  5. 5.
    Save the .bashrc file. For example, in vi, [esc]:x!
  6. 6.
    Open a new terminal window to use your changes.
The $HEAVYAI_STORAGE directory must be dedicated to HEAVY.AI. Do not set it to a directory shared by other packages.

Initialization

Run the systemd installer.
1
cd $HEAVYAI_PATH/systemd
2
./install_heavy_systemd.sh
Copied!
You will be prompted for two paths during install: HEAVYAI_PATH and HEAVYAI_STORAGE. HEAVYAI_PATH defaults to /opt/heavyai. HEAVYAI_STORAGE defaults to /var/lib/heavyai.
The script creates a data directory in $HEAVYAI_STORAGE with the directories heavyai_catalogs, heavyai_data, and heavyai_export. heavyai_import and heavyai_log directories are created when you insert data the first time. If you are an HEAVY.AI administrator, the heavyai_log directory is of particular interest.

Activation

Start and use HeavyDB and Immerse.
  1. 1.
    Start HeavyDB
    1
    sudo systemctl start heavydb
    2
    sudo systemctl start heavy_web_server
    Copied!
  2. 2.
    Enable HeavyDB to start automatically when the system reboots.
    1
    sudo systemctl enable heavydb
    2
    sudo systemctl enable heavy_web_server
    Copied!

Enter Your License Key

Validate your HEAVY.AI instance with your license key.
  1. 1.
    Copy your license key from the registration email message. If you have not received your license key, contact your Sales Representative or register for your 30-day trial here.
  2. 2.
    Connect to Immerse using a web browser connected to your host machine on port 6273. For example, http://heavyai.mycompany.com:6273.
  3. 3.
    When prompted, paste your license key in the text box and click Apply.
  4. 4.
    Log into Immerse by entering the default username (admin) and password (HyperInteractive), and then clicking Connect.
    .

Checkpoint

To verify that everything is working correctly, load some sample data, perform an heavysql query, and generate a Pointmap using Heavy Immerse.
  1. 1.
    HEAVY.AI ships with two sample datasets of airline flight information collected in 2008, and data from the 2015 New York City Tree Census. To insert sample data, run the following command.
    1
    cd $HEAVYAI_PATH
    2
    sudo ./insert_sample_data
    Copied!
  2. 2.
    When prompted, choose dataset 2 (10 thousand rows).
    1
    Enter dataset number to download, or 'q' to quit:
    2
    # Dataset Rows Table Name File Name
    3
    1) Flights (2008) 7M flights_2008_7M flights_2008_7M.tar.gz
    4
    2) Flights (2008) 10k flights_2008_10k flights_2008_10k.tar.gz
    5
    3) NYC Tree Census (2015) 683k nyc_trees_2015_683k nyc_trees_2015_683k.tar.gz
    Copied!
  3. 3.
    Connect to HeavyDB by entering the following command in a terminal on the host machine (default password is HyperInteractive):
    1
    $HEAVYAI_PATH/bin/omnisql
    2
    password: ••••••••••••••••
    Copied!
  4. 4.
    Enter a SQL query such as the following:
    1
    omnisql> SELECT origin_city AS "Origin", dest_city AS "Destination", AVG(airtime) AS "Average Airtime" FROM flights_2008_10k WHERE distance < 175 GROUP BY origin_city, dest_city;
    2
    Origin|Destination|Average Airtime
    3
    Austin|Houston|33.055556
    4
    Norfolk|Baltimore|36.071429
    5
    Ft. Myers|Orlando|28.666667
    6
    Orlando|Ft. Myers|32.583333
    7
    Houston|Austin|29.611111
    8
    Baltimore|Norfolk|31.714286
    Copied!
  5. 5.
    Connect to Immerse using a web browser connected to your host machine on port 6273. For example, http://heavyai.mycompany.com:6273.
  6. 6.
    Create a new dashboard and a Table chart to verify that backend rendering is working.
    1. 1.
      Click New Dashboard.
    2. 2.
      Click Add Chart. Table is the default chart type.
    3. 3.
      Click Select Data Source.
    4. 4.
      Choose the flights_2008_10k table as the datasource.
    5. 5.
      Click Add Measure.
    6. 6.
      Choose depdelay.
    7. 7.
      Click Add Measure.
    8. 8.
      Choose arrdelay.
    The resulting chart shows, unsurprisingly, that there is a correlation between departure delay and arrival delay.