Link Search Menu Expand Document
Start for Free

Install from Zip

This page describes how to install Stardog from Zip.


1. Download the Latest Release

Download the latest release of Stardog.

Or if you have curl installed, execute the following command to download the latest distribution of Stardog into your current working directory.

curl https://downloads.stardog.com/stardog/stardog-latest.zip --output stardog-latest.zip

2. Extract Stardog from the downloaded zip.

Using the command line on unix-like systems:

unzip stardog-latest.zip

Stardog binaries are located in the ./stardog-<version>/bin directory.

3. Configure Stardog Environment Variables

The STARDOG_HOME environment variable needs to be set before starting up Stardog. This environment variable should be set to the directory where all Stardog databases and files will be stored. The directory needs to be created/exist prior to starting up Stardog.

If STARDOG_HOME is not defined, Stardog will start up and use the Java user.dir property value meaning the directory the Stardog was started up in.

  • Place the following in your .bashrc, .zshrc or whichever file you use to configure your shell, replacing /path/to/stardog-home to a newly created directory.

    export STARDOG_HOME=/path/to/stardog-home
    
  • Execute the following command in a command prompt session. STARDOG_HOME can be set to any empty directory.

    setx STARDOG_HOME "%USERPROFILE%\stardog-home"
    

    You may need to open a new command prompt session in order for the environment variable to take effect.

You should not set STARDOG_HOME to be the same as the directory where you put the Stardog binary.

Example directory structure:

/
│   
└─── opt/
│   │  
│   └─── stardog/ <--- stardog installations here
│       │  stardog-7.4.0/
│       │  stardog-7.4.1/ 
│       │  ...
│   
└─── var/
    │   
    └───stardog/ <--- $STARDOG_HOME

The advantage to using a directory structure as shown above is that you can keep all your Stardog versions in the same place and use the same STARDOG_HOME when you switch versions.

4. License key

If you do not have a license key

If you have a license key

  • Copy or move 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
    
  • COPY /B stardog-license-key.bin %STARDOG_HOME%
    

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

5. Setting Your Path

Place the bin/ folder of the Stardog installation on your PATH so stardog and stardog-admin commands can be used regardless of current working directory.

  • We recommend adding to your .bashrc, .zshrc or whichever file you use to configure your shell, though you can also set it temporarily.

    # This assumes you've followed our example directory structure above. If you put Stardog somewhere else, update accordingly.
    export PATH="$PATH:/opt/stardog/stardog-<version>/bin"
    
  • Be sure to provide the actual path to your Stardog installation.

    setx PATH=%PATH%;%USERPROFILE%\path\to\stardog-<version>\bin
    

    You may need to open a new command prompt session in order for the environment variable to take effect.

6. Start up the Stardog server

Start the server up using the stardog-admin server start command.

$ 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?

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.