Updating the installation service (controller)
When the panel asks you to update the installation service and how to run the install.sh --update-controller command on the server.
The installation service (controller) is a separate service on the server that installs tracker releases on command from the Settings → Updates («Настройки → Обновления») tab. It is installed together with the tracker, but it does not change when you update from the panel: it is updated separately, with a command in the terminal. You will need SSH access to the server with root privileges.
When to update
Open Settings → Updates under the installation owner's account. For everyone else, the tab shows “Updates are available only to the installation owner” («Обновления доступны только владельцу установки») — see who can update.
Under the Installed version («Установленная версия») block there is the line “Installation service: 20261004 · protocol 1” («Служба установки: 20261004 · протокол 1»). The number is the version of the service on your server. If the service does not report its version, “previous version” («прежняя версия») is shown instead of the number.
You need to update the service when a new tracker release requires a newer version of it. The tab then shows this message (“First update the installation service on the server: bash install.sh --update-controller. The running tracker is kept.”):
Сначала обновите службу установки на сервере: bash install.sh --update-controller. Работающий трекер сохраняется.The Install… («Установить…») button in the “Version … available” («Доступна версия …») card is inactive in this case.
The second sign is that the tab has no Local update copies («Локальные копии обновлений») block. The block appears after the service is updated, see Local update copies.
Updating on the server
- Make sure no update, backup creation or restore is running in the panel. If one is running, wait for it to finish.
- Connect to the server over SSH.
- Download the installer with the first command.
- Run it as root with the
--update-controllerparameter using the second command. - Wait for the line with the result.
curl -fsSLo install.sh https://install.micator.com/install.sh
sudo bash install.sh --update-controllerThe installer prints “Downloading the signed release…” («Загружаю подписанный выпуск…»), downloads the entire release archive and updates the service. On success, the terminal shows these lines (“Controller updated: 20261004. Traffic was not stopped.” and “Server command: sudo micatorctl. The previous sudo trackerctl also works.”):
Контроллер обновлён: 20261004. Трафик не останавливался.
Команда на сервере: sudo micatorctl. Прежняя sudo trackerctl тоже работает.The number in the first line is the new version of the service. The second line is about the server command; it mentions trackerctl only if the server was installed with an earlier release.
The tracker is installed in a different directory
Without --path, the command works with the /opt/micator directory, or, if the server has an installation in /opt/tracker — the default directory of earlier releases — with that installation: the installer finds it by itself. If the directory was set with the --path parameter during installation, specify it here too:
sudo bash install.sh --update-controller --path /opt/micator-2The path must have the form /opt/name: Latin letters, digits, _ and -.
Download install.sh again before each run. The file contains the URL of a specific release: a copy downloaded earlier may point to an earlier release.
What the command does
- Downloads the release and verifies its signature with the key pinned to the installation: the
.updates/trusted-release.pemfile in the installation directory. The key from the downloadedinstall.shis not used in this mode. - Writes the new service to a separate directory inside
/usr/local/lib/micator-updater-releases/. The files of the previous service stay on the server. - Switches the
micator-updates.serviceservice to the new files, restarts it and checks that it responds with the new version. - After that, installs the
/usr/local/bin/micatorctlcommand. On servers of earlier releases, thetrackerctlcommand stays and works the same way. If the service fails the check, the command is not installed.
The command does not touch the tracker, the databases or the data. Clicks and postbacks are received without a pause, and the panel keeps working.
In installations made before this release, the directory for new service versions is /usr/local/lib/tracker-updater-releases/, and the service is tracker-updates.service. The command does not rename them, see names in such installations.
If the new service fails the check, the installer brings back the previous one and prints “Update not completed. The previous controller has been restored.” («Обновление не завершено. Возвращён прежний контроллер.») The command does not install a version lower than the installed one.
Check
- Open Settings → Updates. If the tab was already open, refresh the page.
- Find the line “Installation service: …”. It should show the version from the terminal.
- Make sure the message about the installation service is gone and the Install… button is active.
If the tab has no “Version … available” card, click Check for updates («Проверить обновления»). After that, the release is installed from the panel — see Updating the tracker from the panel.
If it did not work
You can run the command again.
| Terminal message | Cause | What to do |
|---|---|---|
| “Run the installation with sudo.” («Установку запускать через sudo.») | The command was not run as root | Run it with sudo |
| “Invalid installation path.” («Некорректный путь установки.») | --path points to a directory that does not have the form /opt/name | Specify the directory the tracker is installed in |
| “Several installations found. Specify --path explicitly.” («Найдено несколько установок. Укажите --path явно.») | The command was run without --path, and there are installations in both /opt/micator and /opt/tracker | Specify the directory of the installation you need in --path |
| “The installation's pinned key was not found.” («Не найден закреплённый ключ установки.») | The directory has no .updates/trusted-release.pem file: the wrong directory was specified, or the tracker in it has not been started yet | Check --path. Without the parameter, the installer uses the /opt/micator directory or the installation it finds in /opt/tracker |
| “The release signature failed verification. Installation stopped.” («Подпись выпуска не прошла проверку. Установка остановлена.») | The archive was not downloaded completely, was modified or was signed with a key other than the one pinned to the installation | Download install.sh again and retry. See Release signature and contents |
| “Root and the directory of the installed tracker are required.” («Нужен root и каталог установленного трекера.») | The installation directory is a symbolic link, or the command was not run as root | Run it with sudo and specify the tracker directory itself in --path |
| “The controller update is intended for a client installation.” («Обновление контроллера предназначено для клиентской установки.») | The directory is not owned by root, is writable by other users or contains .git | Run the command only on a tracker installed with install.sh |
| “Finish the installation or restore first.” («Сначала завершите установку или восстановление.») | The first-run wizard is not completed, or a tracker update is running or was interrupted | Complete the wizard or wait for the update to finish on the Updates tab |
| “An operation is already running on the server.” («На сервере уже выполняется операция.») | A backup, restore, check, update installation or copy cleanup is running | Wait for it to finish and retry |
| “Wait for the update or restore to finish.” («Дождитесь окончания обновления или восстановления.») | The installation service is busy, or it is locked after a failed return to the previous version | Wait for the operation to finish on the Updates tab. If it is locked, see Lock |
| “The standard update service was not found.” («Не найдена штатная служба обновлений.») | /etc/systemd/system/ has no file for the micator-updates.service installation service (its old name is tracker-updates.service) | Run the command only on a tracker installed with install.sh |
| “This release does not contain a compatible controller.” («Этот выпуск не содержит совместимый контроллер.») | The downloaded release has no service of the required version | Download install.sh again and retry |
| “Downgrading the controller is not allowed.” («Понижение версии контроллера запрещено.») | The service in the downloaded release is older than the installed one | Download install.sh again and retry |
| “Incomplete controller bundle.” («Неполный комплект контроллера.») | Some of the service files are missing from the release | Download install.sh again and retry |
| “The micatorctl command was not added (…); repeat --update-controller. Until then, sudo trackerctl works.” («Команда micatorctl не добавлена (…); повторите --update-controller. До тех пор работает sudo trackerctl.») | The service was updated, but the command file was not written. The last sentence is absent if the server has no previous trackerctl command | Run the command again. Until then, the previous trackerctl works, if there is one |
| “The micatorctl command was not overwritten (…); repeat --update-controller.” («Команда micatorctl не перезаписана (…); повторите --update-controller.») | A repeated run: the service was updated, but the file of the command already on the server was not overwritten | Run the command again. The previous command file stays in place |
| “Update not completed. The previous controller has been restored.” | The new service did not start or did not confirm its version | The previous service is running. Run the command again. For the service log, see systemd services |
The messages “Operation not completed: …” («Операция не завершена: …») and “Command … failed (N).” («Команда … завершилась ошибкой (N).»), as well as the installer's messages about the system, the download and the release contents, are covered on the Installation errors and how to fix them page. The other install.sh parameters are in the installer reference.