> For the complete documentation index, see [llms.txt](https://magic-mirror.gitbook.io/magicmi/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://magic-mirror.gitbook.io/magicmi/installation/ubuntu.md).

# Ubuntu

The following instructions were tested on a freshly installed Ubuntu LTS 18.04 system.

## Download MagicMirror Executable

MagicMirror Linux executable can be downloaded [here](https://www.dropbox.com/sh/tguoj2kpaewro4j/AABXZ2564iv4G0BI3o3LeuVUa?dl=0). The downloaded file needs to be unzipped.&#x20;

## Install Dependency

The only dependency MagicMirror needs based on a freshly installed Ubuntu LTS 18.04 system is the Java Runtime Environment(JRE) 11, which can be installed using the following commands.&#x20;

```
apt update
apt install openjdk-11-jre-headless -y
```

## Change Permission

You may encounter `Permission Denied` issue when executing the magic\_mirror executable. This is likely due to Ubuntu setting the file to be non-executable by default. You can execute the following command to make the file executable in the same directory of the magic\_mirror file.&#x20;

```
sudo chmod a+x ./magic_mirror
```

## Running MagicMirror

MagicMirror has two modes, `single-file-mode` and `batch-mode`, which corresponds to executing a single contract, or a batch of contracts. You can find the quick start and more details for running MagicMirror in these modes in [single-file-mode](https://magic-mirror.gitbook.io/magicmi/running-magicmirror/single-file-mode) and [batch-mode](https://magic-mirror.gitbook.io/magicmi/running-magicmirror/batch-mode).
