Manual Update Guide
Step-by-step guide to manually update Mist when the dashboard update fails or gets stuck.
Overview
If you're experiencing issues updating Mist through the dashboard, you can perform a manual update using the same installation script. This method is safe and will preserve all your data, applications, and settings.
Safe Update Process
The installation script is designed to be idempotent - you can run it multiple times safely. It will:
- ✅ Preserve your database and all data
- ✅ Keep all applications and deployments running
- ✅ Maintain your settings and configurations
- ✅ Update only the Mist binary and system files
When to Use Manual Update
Use manual update when:
- Dashboard update gets stuck in "in progress" state
- Update fails with errors in the dashboard
- Service won't restart after an update
- You want to update from a specific Git branch
- You need to rollback to a previous version
Quick Update Steps
1. SSH into Your Server
ssh user@your-server-ip2. Run the Installation Script
The same script used for installation will update your existing installation:
curl -fsSL https://trymist.cloud/install.sh | sudo bashThat's it! The script will:
- Detect your existing installation
- Update the repository to the latest version
- Rebuild the binary
- Restart the service
- Verify everything is working
3. Verify Update
# Check service status
sudo systemctl status mist
# Check version
curl http://localhost:8080/api/updates/version
# Access dashboard
# https://your-mist-domain.comDetailed Manual Update Process
Step 1: Prepare for Update
Before updating, it's good practice to check the current state:
# Check current version
curl http://localhost:8080/api/updates/version
# Check service status
sudo systemctl status mist
# View current running containers
docker psStep 2: Run the Update Script
Execute the installation script with sudo:
curl -fsSL https://trymist.cloud/install.sh | sudo bashWhat the script does:
- Checks system requirements
- Updates Git repository from the
releasebranch - Downloads Go dependencies
- Builds the new binary
- Restarts the Mist service
- Verifies the service is running
Expected output:
Starting Mist installation...
▶ Updating repository...
✔ Done
▶ Downloading dependencies...
✔ Done
▶ Building backend...
✔ Done
▶ Restarting service...
✔ Done
╔════════════════════════════════════════════╗
║ 🎉 Mist installation complete ║
║ 👉 http://your-server-ip:8080 ║
╚════════════════════════════════════════════╝Step 3: Verify the Update
After the script completes:
- Check service is running:
sudo systemctl status mistExpected output: Active: active (running)
- Verify new version:
curl http://localhost:8080/api/updates/version- Check service logs:
sudo journalctl -u mist -n 50 --no-pagerTest dashboard access:
- Open your browser
- Navigate to your Mist dashboard
- Log in and verify functionality
Check applications:
- Verify all applications are still running
- Check deployment history
- Test application access
Handling Update Issues
Update Script Fails
If the update script encounters errors:
1. Check the installation log:
tail -100 /tmp/mist-install.log2. Common issues:
Port Already in Use
# Stop Mist service first
sudo systemctl stop mist
# Run update script
curl -fsSL https://trymist.cloud/install.sh | sudo bashGit Conflicts
# Navigate to installation directory
cd /opt/mist
# Reset any local changes
sudo git reset --hard
# Run update script again
curl -fsSL https://trymist.cloud/install.sh | sudo bashBuild Failures
# Clear Go cache
sudo go clean -cache -modcache
# Rebuild manually
cd /opt/mist/server
sudo go mod tidy
sudo go build -o mist
# Restart service
sudo systemctl restart mistService Won't Start After Update
If Mist service fails to start after update:
1. Check service status and logs:
sudo systemctl status mist
sudo journalctl -u mist -n 100 --no-pager2. Check for common issues:
Database Locked
# Stop service
sudo systemctl stop mist
# Check for processes using database
sudo lsof /var/lib/mist/mist.db
# Kill any stale processes if found
sudo pkill -9 mist
# Start service
sudo systemctl start mistBinary Not Executable
# Make binary executable
sudo chmod +x /opt/mist/server/mist
# Restart service
sudo systemctl restart mistMissing Dependencies
# Reinstall dependencies
cd /opt/mist/server
sudo go mod download
sudo go build -o mist
sudo systemctl restart mistApplications Not Working After Update
If your applications are inaccessible after update:
1. Check Traefik is running:
docker ps | grep traefik2. Restart Traefik if needed:
cd /opt/mist
docker compose -f traefik-compose.yml restart3. Check application containers:
docker ps -a4. Restart specific containers if needed:
docker restart <container-name>Update from Specific Version or Branch
Update from Specific Git Branch
To update from a different branch (e.g., main, develop):
# Navigate to installation directory
cd /opt/mist
# Switch to desired branch
sudo git fetch origin
sudo git checkout <branch-name>
sudo git pull origin <branch-name>
# Build and restart
cd server
sudo go mod tidy
sudo go build -o mist
sudo systemctl restart mistRollback to Previous Version
If the new update causes issues, you can rollback:
1. View recent versions:
cd /opt/mist
git log --oneline -102. Rollback to specific commit:
# Replace <commit-hash> with desired version
sudo git reset --hard <commit-hash>
# Rebuild
cd server
sudo go build -o mist
# Restart
sudo systemctl restart mist3. Rollback to previous release tag:
# View available tags
git tag -l
# Checkout specific tag
sudo git checkout tags/v1.0.0
# Rebuild and restart
cd server
sudo go build -o mist
sudo systemctl restart mistClearing Stuck Updates
If a dashboard update is stuck in "in progress" state:
Method 1: Restart Service (Automatic Fix)
Simply restart the Mist service - the startup check will automatically resolve stuck updates:
sudo systemctl restart mistThe system will:
- Check for stuck updates on startup
- Compare current version with target version
- Mark update as success if versions match
- Mark as failed if versions don't match
Method 2: Manual Fix Using CLI
Clear the stuck update manually:
1. List update history:
# Check update logs via dashboard or:
curl http://localhost:8080/api/updates/history2. Clear stuck update:
Via API (requires authentication):
# Note: You need to be logged in and get the update_log_id
curl -X POST "http://localhost:8080/api/updates/clear?id=<update_log_id>" \
--cookie "session_token=your_session_token"Method 3: Complete Manual Update
Perform a complete manual update which will automatically fix the stuck state:
# Run installation script
curl -fsSL https://trymist.cloud/install.sh | sudo bash
# Service restart will resolve stuck updateUpdate Best Practices
Before Updating
- Backup database:
# Create backup directory
sudo mkdir -p /var/lib/mist/backups
# Copy database
sudo cp /var/lib/mist/mist.db /var/lib/mist/backups/mist.db.$(date +%Y%m%d_%H%M%S)- Check disk space:
df -h /opt- Note current version:
curl http://localhost:8080/api/updates/version- Check running applications:
docker psDuring Update
- Monitor the update process:
# In a separate terminal, watch logs
sudo journalctl -u mist -f- Don't interrupt the process:
- Let the script complete
- Don't cancel or close the terminal
- Wait for confirmation message
After Update
- Verify service health:
# Check service
sudo systemctl status mist
# Check logs for errors
sudo journalctl -u mist -n 50 --no-pager | grep -i error
# Test health endpoint
curl http://localhost:8080/api/healthTest critical functionality:
- Log into dashboard
- Check applications are accessible
- Test deployment (optional)
- Verify domains are working
Clean up old builds (optional):
# Clean Docker resources if needed
docker system prune -fAutomated Update Script
For convenience, you can create a custom update script:
#!/bin/bash
# save as: /usr/local/bin/mist-update
set -e
echo "🔄 Starting Mist update..."
# Backup database
echo "📦 Creating database backup..."
sudo mkdir -p /var/lib/mist/backups
sudo cp /var/lib/mist/mist.db /var/lib/mist/backups/mist.db.$(date +%Y%m%d_%H%M%S)
# Run update
echo "⬇️ Downloading and installing update..."
curl -fsSL https://trymist.cloud/install.sh | sudo bash
# Verify
echo "✅ Verifying update..."
sleep 3
sudo systemctl status mist --no-pager
echo "🎉 Update complete!"
echo "Current version:"
curl -s http://localhost:8080/api/updates/version | jq -r '.data.version'Make it executable and use it:
sudo chmod +x /usr/local/bin/mist-update
sudo mist-updateUpdate Frequency
Recommended Update Schedule
- Security updates: As soon as available
- Feature updates: Monthly or as needed
- Patch updates: When issues are fixed
Check for Available Updates
Via Dashboard:
- Navigate to Settings → Updates
- Click "Check for Updates"
Via API:
curl http://localhost:8080/api/updates/checkVia GitHub:
- Check releases page
- Watch repository for notifications
Maintenance Mode (Optional)
For minimal downtime during updates:
1. Create maintenance page:
# Add to Traefik config to show maintenance page
# This is optional - most updates complete in under 30 seconds2. Notify users:
- Post in team chat
- Send email notification
- Update status page
3. Schedule updates:
- Choose low-traffic periods
- Plan for 5-10 minutes downtime
- Have rollback plan ready
Troubleshooting Specific Errors
Error: "go: command not found"
# Install Go
wget https://go.dev/dl/go1.22.11.linux-amd64.tar.gz
sudo rm -rf /usr/local/go
sudo tar -C /usr/local -xzf go1.22.11.linux-amd64.tar.gz
export PATH=$PATH:/usr/local/go/bin
# Run update again
curl -fsSL https://trymist.cloud/install.sh | sudo bashError: "Permission denied"
# Ensure you're using sudo
sudo bash install.sh
# Or fix ownership
sudo chown -R root:root /opt/mist
sudo chmod -R 755 /opt/mistError: "Database is locked"
# Stop all processes
sudo systemctl stop mist
# Check for lock
sudo lsof /var/lib/mist/mist.db
# Kill if needed
sudo pkill -9 mist
# Restart
sudo systemctl start mistGetting Help
If manual update doesn't resolve your issue:
Gather Information
# System info
uname -a
# Mist version
curl http://localhost:8080/api/updates/version
# Service status
sudo systemctl status mist
# Recent logs
sudo journalctl -u mist -n 100 --no-pager
# Installation log
tail -50 /tmp/mist-install.logCommunity Support
- GitHub Issues: Report update issues
- Discord: Get real-time help
- Discussions: Ask questions
Include in Bug Report
When reporting update issues, include:
- Current version and target version
- Complete error messages
- Installation log (
/tmp/mist-install.log) - Service logs (
sudo journalctl -u mist -n 100) - System information (
uname -a)
Related Documentation
- Upgrading Guide - Official upgrade documentation
- Common Issues - General troubleshooting
- Installation Guide - Initial installation
- Backup & Recovery - Data backup procedures
