mii Lite on Linux
mii Lite on Linux runs as the systemd service makeintelligent. It uses your distribution's PostgreSQL 16 server binaries but a private cluster on 127.0.0.1:5433. It never touches a distribution cluster.
Before you start
- Linux amd64 with glibc 2.36 or newer (Debian 12 baseline).
- 4 cores, 8 GB RAM, 40 GB free disk.
- PostgreSQL 16 server binaries in
/usr/lib/postgresql/16/bin,/usr/lib/postgresql/17/binor/usr/pgsql-16/bin. The.debpulls them in. The offline package bundles them. - root access.
Install
- .deb (Debian, Ubuntu)
- Tarball
sudo apt install ./mii-lite_<version>_amd64.deb
The package name is mii-lite. It depends on postgresql-16, libssl3 (or libssl3t64), libxml2 and ca-certificates. Its post-install step runs /opt/makeintelligent/mii install. Its pre-remove step runs mii uninstall.
On Ubuntu 22.04 or Debian 12, add the PostgreSQL PGDG apt repository first, or use the offline package.
tar xzf mii-lite-<version>-linux-amd64.tar.gz && cd mii-lite-<version>
sudo ./mii install
The tarball contains mii and README-linux.txt.
Then read the login:
sudo cat /var/lib/makeintelligent/FIRST-LOGIN.txt
Open http://<server>:8080.
What install does
| Action | Detail |
|---|---|
| System user | Creates mii (no login, home is the data folder) |
| Folders | /opt/makeintelligent and /var/lib/makeintelligent, mode 0750, owner mii |
| Service unit | /etc/systemd/system/makeintelligent.service with Restart=on-failure, RestartSec=60, LimitNOFILE=65536, KillMode=mixed, TimeoutStopSec=90, NoNewPrivileges=true, ExecStart=/opt/makeintelligent/mii service-run |
| Start | systemctl enable --now makeintelligent |
| Firewall | Opens 8080/tcp through ufw or firewalld if active; otherwise prints a hint. Ports 1883 and 5433 are not opened. |
mii uninstall does not remove firewall rules. --purge deletes the data folder.
Folders
| Path | Content |
|---|---|
/opt/makeintelligent/ | Program and versioned payload |
/var/lib/makeintelligent/config/mii.env | Settings |
/var/lib/makeintelligent/secrets/ | Generated secrets (0700 and 0600) |
/var/lib/makeintelligent/data/ | pg, buffer, ot, stream |
/var/lib/makeintelligent/logs/ | mii.log, per-component logs, health.jsonl |
/var/lib/makeintelligent/backups/ | Backups |
Commands
| Command | What it does |
|---|---|
sudo /opt/makeintelligent/mii status | Service state and health |
sudo /opt/makeintelligent/mii health | Counters per component |
sudo /opt/makeintelligent/mii backup [--out file] | Full backup |
sudo /opt/makeintelligent/mii restore <file> | Restore (service stopped) |
sudo /opt/makeintelligent/mii rollback | Return to the previous version |
sudo /opt/makeintelligent/mii uninstall [--purge] | Remove the service |
mii run | Foreground mode. It refuses root unless MI_LITE_ALLOW_ROOT=1. |
Logs: journalctl -u makeintelligent and the files in logs/.
Open read-only data access
Edit /var/lib/makeintelligent/config/mii.env:
MI_LITE_MQTT_PUBLIC_LISTEN=0.0.0.0:1883
MI_LITE_PG_PUBLIC=on
Restart with sudo systemctl restart makeintelligent, open the ports in your firewall, and read the logins in /var/lib/makeintelligent/DATA-ACCESS.txt. See Lite on Docker.
Upgrade
Install the new package over the old one (sudo apt install ./mii-lite_<new>_amd64.deb or sudo ./mii install from the new tarball). Data is kept, migrations run at start, and mii makes an automatic pre-upgrade backup. Run mii rollback if the upgrade fails.
Troubleshooting
| Symptom | Cause | Fix |
|---|---|---|
| Install says PostgreSQL not found | Server binaries missing | Install postgresql-16, or use the offline package. |
GLIBC_2.36 not found | Distribution too old | Use Debian 12 or newer, or the offline package. |
| Console not reachable from another PC | Firewall | Open 8080/tcp. |
| Service restarts every minute | Port collision or an invalid mii.env value | Read logs/mii.log and journalctl -u makeintelligent. |