Link Search Menu Expand Document
Start for Free

macOS Installation

This page describes how to install Stardog on macOS.

Page Contents
  1. Prerequisites
  2. Homebrew
  3. What’s Next?

Prerequisites

Before continuing with the installation guide, please review the System Requirements for running Stardog.

If you are using a new Mac with an M1 chip, Stardog does not natively support this new architecture. You will need to install Rosetta via softwareupdate --install-rosetta and download/install an x86 JDK. There are several options for doing this, but it can be accomplished via Homebrew with a single command: arch -x86_64 /bin/zsh -c "brew tap adoptopenjdk/openjdk && brew install adoptopenjdk11"

Homebrew

  1. To install Stardog via Homebrew, use the following command:

     ​​$ brew install stardog-union/tap/stardog
    

    Homebrew will take care of the installation for you including adding Stardog’s /bin folder to your PATH so stardog and stardog-admin commands can be used regardless of current working directory.

  2. Setup STARDOG_HOME

    The most important piece of configuration to do before you start Stardog is setting the STARDOG_HOME environment variable. This is the directory where all the Stardog databases and other files will be stored. If STARDOG_HOME is not defined, Stardog will use the Java user.dir property value.

    Our convention is to set STARDOG_HOME to /var/stardog but this can be any directory. We highly reccomend not setting this to the directory where Homebrew installed Stardog to (likely /usr/local/Caskroom/stardog ).

    Place the following in your .bash_profile or whichever file you use to configure your shell.

     export STARDOG_HOME = /var/stardog
    
  3. License key

    If you do not have a license key

    You can obtain a license key on the Getting Started Page.

    If you have a license key

    Add it to your STARDOG_HOME. Ensure that the stardog-license-key.bin file is readable by the Stardog process.

     $ cp stardog-license-key.bin $STARDOG_HOME
    

    You can specify a different location for the license file by setting the environment variable STARDOG_LICENSE_PATH.

  4. Start up the Stardog server

     $ stardog-admin server start
    

    If the server starts up successfully, you should see an output like this in your terminal:

     ************************************************************
     This copy of Stardog is licensed to Somebody Awesome (somebody.awesome@stardog.com), Stardog
     This is a Enterprise license
     This license does not expire.
     ************************************************************
    
                                                                 :;
                                         ;;                   `;`:
     `'+',    ::                        `++                    `;:`
     +###++,  ,#+                        `++                    .
     ##+.,',  '#+                         ++                     +
     ,##      ####++  ####+:   ##,++` .###+++   .####+    ####++++#
     `##+     ####+'  ##+#++   ###++``###'+++  `###'+++  ###`,++,:
     ####+    ##+        ++.  ##:   ###  `++  ###  `++` ##`  ++:
     ###++,  ##+        ++,  ##`   ##;  `++  ##:   ++; ##,  ++:
         ;+++  ##+    ####++,  ##`   ##:  `++  ##:   ++' ;##'#++
         ;++  ##+   ###  ++,  ##`   ##'  `++  ##;   ++:  ####+
     ,.   +++  ##+   ##:  ++,  ##`   ###  `++  ###  .++  '#;
     ,####++'  +##++ ###+#+++` ##`   :####+++  `####++'  ;####++`
     `####+;    ##++  ###+,++` ##`    ;###:++   `###+;   `###++++
                                                         ##   `++
                                                     .##   ;++
                                                         #####++`
                                                         `;;;.
     ************************************************************
    
    
     Stardog server 7.4.0 started on Thu Oct 01 21:12:22 EDT 2020.
    
     Stardog server is listening on all network interfaces.
     HTTP server available at http://localhost:5820.
    
     STARDOG_HOME=/var/stardog/
    

    By default, the Stardog server will become available at http://localhost:5820

    What’s Next?

What’s Next?

Access Stardog Studio, our IDE for interacting with Stardog, and connect to your running Stardog server.

Check out our additional Getting Started Resources for some introductory blog posts, tutorials, video trainings and more.