Skip to content

Fix Mideye Installation & Upgrade Issues (Linux/Windows)

This guide addresses common problems encountered during Mideye Server installation and upgrades, particularly the critical timing issue where the service starts before all configuration files are properly in place.

The most common installation and upgrade issue occurs when the service starts too quickly — before configuration files are fully copied or database migrations complete. This results in startup failures that require manual intervention.

Problem: After installing or upgrading the Mideye Server package, the service starts immediately but fails because configuration files aren’t ready.

Symptoms:

  • Service fails to start after package installation/upgrade
  • Error messages about missing configuration files
  • Service status shows “failed” or “activating”

Solution:

  1. Check service status:

    Linux:

    Terminal window
    systemctl status mideyeserver6
    journalctl -u mideyeserver6 -n 50 --no-pager

    Windows:

    Terminal window
    Get-Service MideyeServer6
    Get-Content "C:\Program Files\Mideye Server\log\mideyeserver.log" -Tail 50
  2. Verify configuration files exist:

    Linux:

    Terminal window
    ls -la /opt/mideyeserver6/config/application-prod.yml
    ls -la /opt/mideyeserver6/config/logback.xml
    ls -la /opt/mideyeserver6/config/keystore.p12

    Windows:

    Terminal window
    Test-Path "C:\Program Files\Mideye Server\config\application-prod.yml"
    Test-Path "C:\Program Files\Mideye Server\config\keystore.p12"
  3. Fix file permissions (Linux):

    Terminal window
    sudo chown mideye:mideye /opt/mideyeserver6/config/*
    sudo chmod 660 /opt/mideyeserver6/config/application-prod.yml
    sudo chmod 660 /opt/mideyeserver6/config/logback.xml
    sudo chmod 660 /opt/mideyeserver6/config/keystore.p12
  4. Manually restart the service:

    Linux:

    Terminal window
    sudo systemctl restart mideyeserver6

    Windows:

    Terminal window
    Restart-Service MideyeServer6

Prevention:

  • After upgrades, always wait 10–15 seconds before checking service status
  • Monitor logs during first startup after upgrade

Missing or Inaccessible Configuration Files

Section titled “Missing or Inaccessible Configuration Files”

Problem: Service fails to start with errors about missing configuration files.

Root Causes:

  • Configuration files not preserved during upgrade
  • Files exist but have wrong permissions
  • Incorrect file paths

Required files:

  • application-prod.yml — Main production configuration
  • logback.xml — Logging configuration
  • keystore.p12 — TLS/SSL keystore

Solution:

Linux:

Terminal window
# List all config files
ls -la /opt/mideyeserver6/config/
# Fix ownership and permissions
sudo chown -R mideye:mideye /opt/mideyeserver6/config
sudo chmod 660 /opt/mideyeserver6/config/*.yml
sudo chmod 660 /opt/mideyeserver6/config/*.xml
sudo chmod 660 /opt/mideyeserver6/config/*.p12
# If keystore is missing, regenerate
sudo /opt/mideyeserver6/bin/generate-selfsigned-tls-keystore.sh
sudo chown mideye:mideye /opt/mideyeserver6/config/keystore.p12
sudo chmod 660 /opt/mideyeserver6/config/keystore.p12

Problem: Service starts but fails because the database isn’t ready for connections.

Symptoms:

  • “Communications link failure” in logs
  • “Connection refused” to database
  • Service enters failed state after several minutes

Diagnostic Steps:

Linux:

Terminal window
# Check database is running
systemctl status mariadb
# Test database connection
mysql -h localhost -u root -p mideyeserver

Solution:

  1. Start the database service before Mideye Server
  2. Ensure the database service is configured to start on boot
  3. Restart Mideye Server after the database is running

See Database Issues for detailed database troubleshooting.


Problem: Database schema migrations fail during startup, leaving the database in an inconsistent state.

Symptoms:

  • “Waiting for changelog lock” messages in logs
  • “Validation Failed” errors
  • Service fails to start

Solution:

  1. Check for stuck migration lock:

    SELECT * FROM DATABASECHANGELOGLOCK;
  2. If lock is stuck (LOCKED=1 with no service running), release it:

    UPDATE DATABASECHANGELOGLOCK SET LOCKED=0, LOCKGRANTED=NULL, LOCKEDBY=NULL;
  3. Restart Mideye Server

See Database Issues for more details.


Problem: Service can’t read configuration files or write to log directories.

Symptoms:

  • “Permission denied” errors in logs
  • Service fails to start
  • Unable to write log files

Solution (Linux):

Terminal window
# Fix ownership recursively
sudo chown -R mideye:mideye /opt/mideyeserver6
# Set correct permissions on directories
sudo find /opt/mideyeserver6 -type d -exec chmod 750 {} +
# Set correct permissions on config files
sudo chmod 660 /opt/mideyeserver6/config/application-prod.yml
sudo chmod 660 /opt/mideyeserver6/config/logback.xml
sudo chmod 660 /opt/mideyeserver6/config/keystore.p12
# Ensure log directory is writable
sudo mkdir -p /opt/mideyeserver6/log
sudo chown mideye:mideye /opt/mideyeserver6/log
sudo chmod 750 /opt/mideyeserver6/log
# If using SELinux
sudo restorecon -Rv /opt/mideyeserver6

Problem: During installation, the automatic generation of the self-signed TLS certificate fails.

Symptoms:

  • No keystore.p12 file created
  • Service fails to start with keystore-related errors

Solution (Linux):

Terminal window
# Manually run keystore generation
sudo /opt/mideyeserver6/bin/generate-selfsigned-tls-keystore.sh
# Set permissions
sudo chown mideye:mideye /opt/mideyeserver6/config/keystore.p12
sudo chmod 660 /opt/mideyeserver6/config/keystore.p12
# Restart service
sudo systemctl restart mideyeserver6

Alternatively, once the service is accessible, use the Certificate Management page in the web interface to manage certificates.


After installing or upgrading, verify the installation is successful:

Linux:

Terminal window
systemctl status mideyeserver6

Windows:

Terminal window
Get-Service MideyeServer6

Expected: Service is running.

Linux:

Terminal window
ss -tlnp | grep -E "8080|1812|1813"

Windows:

Terminal window
Get-NetTCPConnection -LocalPort 8080 -ErrorAction SilentlyContinue

Expected: Service listening on configured ports (typically 8080, 1812, 1813).

Open the Log Files page in the web interface and look for:

  • “Started MideyeServerApp” message
  • No ERROR messages
  • Successful database connection messages

Open browser to https://your-server:8080 — you should see the Mideye Server login page.

Authenticate a test user through RADIUS to verify full functionality.


To minimize upgrade issues:

  1. Back up before upgrading:

    Linux:

    Terminal window
    # Backup configuration
    sudo tar -czf /tmp/mideyeserver-config-backup.tar.gz /opt/mideyeserver6/config
    # Backup database
    mysqldump -u root -p mideyeserver > /tmp/mideyeserver-db-backup.sql

    Windows:

    Terminal window
    # Backup configuration folder
    Copy-Item "C:\Program Files\Mideye Server\config" -Destination "C:\backups\mideyeserver-config" -Recurse
  2. Stop service before upgrade:

    Linux:

    Terminal window
    sudo systemctl stop mideyeserver6

    Windows:

    Terminal window
    Stop-Service MideyeServer6
  3. Verify database is running before starting the upgrade

  4. Perform upgrade using your package manager

  5. Wait 10–15 seconds after upgrade completes

  6. Check service status and monitor logs during first startup

  7. Verify web interface is accessible

  8. Test authentication functionality


If an upgrade fails and the service won’t start:

  1. Stop the service
  2. Restore configuration from backup
  3. Restore database from backup
  4. Downgrade the package to the previous version
  5. Start the service
  6. Verify functionality

If installation or upgrade issues persist, contact Mideye Support with:

  • Mideye Server version
  • Operating system and version
  • Log files (from Log Files page or exported)
  • Description of what was being done when the issue occurred
  • Configuration files (passwords removed)