Skip to main content

Troubleshooting

The first place to look: the per-deployment log in the dashboard. Every shell command's stdout/stderr streams there in real time. The second place: orbit-agent logs on the host.

Agent registration

SymptomCauseFix
Register failed (401 Unauthorized)Token typo, or revoked in the dashboardRe-issue from dashboard → environment → Agent Tokens. Update ~/orbit-agent.env. sudo systemctl restart orbit-agent.
Register failed (404 Not Found)ORBIT_SERVER_URL is wrongCheck the env file. SaaS is https://orbit.byte8.io. Self-hosted: your actual control plane URL.
Register failed (connection refused)Network can't reach the control planecurl -fsSI $ORBIT_SERVER_URL/health from the host. Firewall / VPN / proxy.
Agent doesn't come "online" in the dashboardService crashed silently on first startjournalctl -u orbit-agent --since "5 minutes ago". Usually a missing env var or unreadable env file (chmod 600 ~/orbit-agent.env).

Git clone

SymptomCauseFix
git clone … exit 128 — Repository not foundDeploy key not added to git hostAdd ~/.ssh/id_ed25519.pub to repo → Settings → Deploy keys (read-only is fine).
Host key verification failedknown_hosts doesn't have the git hostssh -T git@github.com once, answer "yes".
Permission denied (publickey)Wrong key, or key not loadedssh -T git@github.com to confirm the right key is being used. Check ~/.ssh/config doesn't override.
Clone takes foreverLarge repo + slow networkConsider shallow clone (PROGRESS: --depth=50 is on the roadmap as an env option).

Composer

SymptomCauseFix
composer install … exit 2 — lock file does not contain compatible packagesPHP version drift between dev and prodPin config.platform.php in composer.json to prod's PHP version, regenerate composer.lock.
Authentication required: repo.magento.comMarketplace creds missingCreate ~/.composer/auth.json (see installation).
composer install exits 0 but vendor/ is emptyStale cacherm -rf var/composer_home/cache/*, redeploy.
Memory exhaustionComposer needs more than PHP's CLI memory limitphp -d memory_limit=-1 ... — or set memory_limit = 2G in the PHP CLI ini.

setup:upgrade

SymptomCauseFix
Exit 1 + "modules are not enabled"Missing app/etc/config.phpDrop a working one into shared/app/etc/config.php.
Exit 1 + missing *Factory.php in autoloadStale generated/ from prior install — should be per-release after agent fixRedeploy. First di:compile rebuilds factories. If sharing shared/generated/, delete: rm -rf /var/www/magento/shared/generated.
Hangs foreverPending data patch with no I/O (rare)Check bin/magento setup:db-data:status for the stuck patch class. Manual bin/magento setup:upgrade from a debug shell often surfaces the issue.
"Please upgrade your database" on storefront after deploy completesDrift detection missed it — module bumped a version that needed upgradeVerify drift is enabled. Check SELECT module, schema_version FROM setup_module against the code's module.xml.

di:compile / static-content:deploy

SymptomCauseFix
di:compile exit 1 — undefined classModule's requirejs-config.js or di.xml references a non-existent classFix the offending file. If recent commit, git revert and redeploy.
static-content:deploy exits 0 but pages have unstyled markupTheme failed silently, ended up with empty CSSCheck theme require.js config and package.json. Common with newly-added themes.
Slow (>5 min)First deploy on a new locale — Magento compiles every locale's static contentReduce --locales in the agent's static-content step if you don't need all locales (PROGRESS roadmap: per-locale opt-in).
SymptomCauseFix
ln -sfn: permission deniedDeploy user doesn't own current or its parentsudo chown $USER:www-data /var/www/magento /var/www/magento/current, redeploy.
Site 500s for a few seconds after the swapOPcache hasn't picked up new filesopcache_reset() via a post-swap hook, or set opcache.validate_timestamps=1. Tradeoff: validation costs perf.
Site immediately reverts (auto-rollback)Health check failedSee "Health check" below.

Health check

SymptomCauseFix
Health check 502nginx upstream socket mismatchgrep -r php\.fpm\.sock /etc/nginx/ — match your installed PHP-FPM socket path.
Health check 500 + cache_dir … is not writableshared/var/ not group-writable by php-fpmRe-run init with --web-user www-data, or sudo chgrp -R www-data shared && find shared -type d -exec chmod 2775 {} \;.
Health check timeoutHealth endpoint too slowReplace with a thin custom endpoint that responds in <100ms. Don't health-check the homepage.
Health check 404URL path wrongDefault is http://127.0.0.1/health_check.php. Magento ships this at pub/health_check.php. Confirm the file exists in the deployed release.

After-deploy

SymptomCauseFix
Customers logged out every deployTypo in shared_dirs (var/sessions plural instead of var/session)Fix the shared list. The default has it right; double-check overrides.
User uploads disappearingpub/media not in shared_dirsAdd it. Verify with readlink current/pub/media.
current symlink danglingOld release pruned while symlinkedSanity-check keep_releases is ≥ 5; smaller values risk pruning the live release in failure paths.
Stale CSS / JS in browserCDN caching old static_content_signatureBump the static-content signature (bin/magento config:set system/full_page_cache/varnish/access_list ... or wait for TTL).

Maintenance window

SymptomCauseFix
503 lasts longer than setup:upgrade shouldLikely waiting on cron or queue consumer holding a row lockSet manage_cron_and_consumers = true on the env — Orbit kills them before deploy.
Site flips 503 even on code-only deploysDrift detection caught a setup_version bumpInspect setup_module vs code (module.xml). Either accept the migration window or remove the unnecessary version bump. (drift detection)
Allowlist IPs don't worknginx isn't passing the real client IPConfigure set_real_ip_from + real_ip_header X-Forwarded-For for your LB/CDN. See allowlist IPs.

Agent upgrade

SymptomCauseFix
orbit-agent self-upgrade 404Brand-new release artifact not yet uploadedWait a few minutes, retry. Verify with the curl probe in install.
Agent crashes on first start after upgradeNew version expects an env var that's missingRe-run orbit-agent init to refresh ~/orbit-agent.env with defaults.
Old + new agent both runningForgot to stop systemd before manual installsudo systemctl stop orbit-agent, verify with pgrep -af orbit-agent, restart.

Diagnostics quick-reference

QuestionCommand
Is maintenance mode actually on?ls -la /var/www/magento/shared/var/.maintenance.flag
What does external traffic see?curl -sI https://your-store.example.com/
Watch maintenance flip livewatch -n 1 'curl -sI http://127.0.0.1/ | head -1'
Agent log tailorbit-agent logs or journalctl -u orbit-agent -f
Recent deploys (DB)psql byte8_orbit -c "SELECT version, status, maintenance_window, completed_at FROM deployments ORDER BY started_at DESC LIMIT 10;"
Live release pointerreadlink -f /var/www/magento/current
All retained releasesls -la /var/www/magento/releases/
Shared dir contentsls -la /var/www/magento/shared/

Still stuck?

  • Open an issue against byte8io/orbit-agent for agent bugs
  • Email helo@byte8.io for control-plane issues or licensing
  • Check the changelog (/blog) — your issue might be a known issue with a fix in a more recent release