> For the complete documentation index, see [llms.txt](https://squirrel.k43.ch/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://squirrel.k43.ch/quick-start/installation.md).

# Installation / Update

## Prerequisites

* HCL Domino 9.0.1 FP8 or higher (requires Java Virtual Machine 1.8 or higher)
* Connection to the Internet mail server(s) from the HCL Domino server
* Root (and intermediate) certificates of the Internet mail server(s) in the CACert keystore file (see [Administrator Tips](/tips-for-the-administrator.md))
* Java Virtual Machine heap size with 256MB or more

## Installation / Update

### Step 1: Check Java VM Heap Size

To avoid out-of-memory errors in the Java Virtual Machine, make sure that the JVM heap size is set to at least 256 MB in the Notes.ini on the HCL Domino server, e.g. *JavaMaxHeapSize=256MB*

### Step 2: Copy distribution files

After [downloading](/quick-start/download.md) and unzipping the installation package, the distribution files must be copied as follows:

| File Name                   | Target Directory      | Description                                                                       |
| --------------------------- | --------------------- | --------------------------------------------------------------------------------- |
| SOFA-Logging.properties     | Domino                | *Only needed to enable OAUTH debugging (see* [*Debugging*](/debugging-tips.md)*)* |
| Squirrel.jar                | Domino/ndext/         | Server add-in                                                                     |
| 1-Squirrel-Jakarta-Mail.jar | Domino/ndext/         | Eclipse Jakarta Mail                                                              |
| Squirrel.ntf                | Domino data directory | Database template                                                                 |

{% hint style="warning" %}
Under Linux/Unix/AIX, make sure that the JAR files are marked with executable rights thru 'chmod +rx‘
{% endhint %}

{% hint style="info" %}
The file name prefix '1-' ensures that the newer Eclipse Jakarta Mail is loaded in favor of the standard mail.jar included in HCL Domino (required for OAuth 2.0)
{% endhint %}

### Step 3: Create / Update Squirrel Database

* Sign the database template *Squirrel.ntf* with the HCL Domino server-id
* Create a new database *Squirrel.nsf* in the root data directory or replace the design of the existing database using the signed template
* Create, edit or verify the configuration, connection and account documents

The database access control (ACL) must be set as follows:

| User types     | Role                                         |
| -------------- | -------------------------------------------- |
| Users          | EditAcc                                      |
| Administrators | EditConfigSrv, EditConn                      |
| Servers        | EditConfigSrv, EditConn, EditAcc, ReadAllAcc |

The HCL Domino database *Squirrel.nsf* contains configuration and status information. There are three types of documents:

* One Configuration Document per Domino server is used to define the Squirrel add-in running on a server (ACL Role *EditConfigSrv*).
* One Host Connection Document must be defined for each Internet mail server referenced in the mail account documents (ACL Role *EditConn*).
* One Mail Account Subscription Document must be defined for each mail account to be processed (ACL Role *EditAcc*) .

### Step 4: Post-installation

* If you plan to process all folders from the IMAP host, check the [Developer Tips](/developer-tips.md) on how to move the messages in the users mail box to the corresponding folders after processing.
* If any RunJava task is running on the server,  it is necessary to restart RunJava to load the newly installed Java containers.

### Step 5: Start the Application

Now you are ready to [start the Application](/quick-start/start-stop-squirrel.md).
