Skip to content

Update

An update replaces the binaries run by SmartAGT. The application automatically handles any database or data migrations, with no action required from you.

An update replaces the binaries on each relevant Backend and Frontend node. The application automatically handles any database or data migrations, with no action required from you. Stop the services on every node before replacing their packages.

This procedure updates the Backend and Frontend packages in four steps.

  1. ShutdownSmartAGT services
  2. Old packagesKeep a backup
  3. New versionReplace the packages
  4. StartupResume SmartAGT

Prerequisites

  • New Backend and Frontend package versions available.
  • Databases backed up.
  • Snapshot taken if the installation runs on a VM.
  • S3 storage backed up, when used.

Procedure

1. Stop the services

Stop the SmartAGT services.

sudo systemctl stop smartagt-frontend-service SmartAGT-AI-Gateway-Service
sudo systemctl stop smartagt-scheduler-worker smartagt-rag-ingestor-worker smartagt-rag-embed-worker
sudo systemctl stop SmartAGT-Platform-Service
Stop-Service smartagt-frontend-service, SmartAGT-AI-Gateway-Service
Stop-Service smartagt-scheduler-worker, smartagt-rag-ingestor-worker, smartagt-rag-embed-worker
Stop-Service SmartAGT-Platform-Service

Keep only the services installed on the host in these commands.

Expected result: SmartAGT services are stopped.

2. Retain the old packages

Separate data from binaries

This procedure assumes that data and binaries are in separate directories. If data has been configured inside the binary directories, update the YAML configuration and move the data outside those directories before continuing, to avoid data loss during updates.

Rename the directories to keep a backup of the old packages.

On each node, rename the installed package directory to keep a backup.

cd /app
sudo mv -T smartagt-backend-core smartagt-backend-core-old
sudo mv -T smartagt-bff-core smartagt-bff-core-old
Set-Location C:\app
Rename-Item -LiteralPath C:\app\smartagt-backend-core -NewName smartagt-backend-core-old
Rename-Item -LiteralPath C:\app\smartagt-bff-core -NewName smartagt-bff-core-old

Expected result: a backup of the old packages is retained.

3. Deploy the new packages

Extract the new packages to their original locations.

On each node, extract the new package for its component to the original location.

sudo tar -xzf <Backend package> -C /app
sudo tar -xzf <Frontend package> -C /app
Expand-Archive <Backend package> C:\app\smartagt-backend-core
Expand-Archive <Frontend package> C:\app\smartagt-bff-core

Expected result: the new packages are in place.

4. Start the services

Start the Platform service, then the other services once the API is available.

Once every package has been replaced, start the Platform services on the Backend nodes. When their APIs are available, start the workers, Gateway and Frontend services on their respective hosts.

sudo systemctl start SmartAGT-Platform-Service
Start-Service SmartAGT-Platform-Service

When the API is available, start the other installed services:

sudo systemctl start smartagt-rag-ingestor-worker smartagt-rag-embed-worker smartagt-scheduler-worker
sudo systemctl start SmartAGT-AI-Gateway-Service
sudo systemctl start smartagt-frontend-service
Start-Service smartagt-rag-ingestor-worker, smartagt-rag-embed-worker, smartagt-scheduler-worker
Start-Service SmartAGT-AI-Gateway-Service
Start-Service smartagt-frontend-service

Expected result: the SmartAGT sign-in page is displayed in your browser.