Sourcegraph Repository Not Cloning or Not Updating
Quick answer
Check Settings > Mirroring on the repo, click Refresh Now, then look at gitserver logs and code host connectivity.
Most likely fix: Refresh the repo
How to fix it
Try these in order — the most common fix is first.
1. Refresh the repo
- Open the repo, then Settings > Mirroring and review Last refreshed, queue position and last sync log
- Click Refresh Now
- If that fails, trigger updates with repository webhooks
Did this fix it?2. Test the code host connection
- On the code host configuration page click Test connection
- Errors like 'context deadline exceeded' or 'no such host' mean network or DNS must be fixed
Did this fix it?3. Check logs and resources
- Check gitserver logs and the worker container or pod logs
- Compare resources with the resource estimator; a small Postgres (driver: bad connection) or crash-looping worker blocks syncing, so raise memory
Did this fix it?
Symptoms
Repositories show up but never clone, or stay stale after commits.
Why it happens
- Very large, empty, locked or corrupted repo
- Code host overloaded or permission problems
- Instance short on resources
- Code host unreachable from Sourcegraph
This guide also covers
- sourcegraph repository not cloning
- sourcegraph repo not updating
- sourcegraph repositories not showing up
Still not working?
If Sourcegraph keeps failing, you're not alone. See every Sourcegraph problem users report or the alternatives people switch to.
Have an app idea? Our small team builds any software: web and mobile apps, games, desktop, AI tools. Price agreed together.
Talk to usOther Sourcegraph errors
- Sourcegraph Cody Free and Pro Discontinued: What Happened and What to Do
- Sourcegraph Cody Not Working in VS Code
- Sourcegraph Cody Sign-In Error: Authentication Failed or Signed Out on Restart
- Sourcegraph Cody Not Working in JetBrains (IntelliJ, Android Studio)
- Sourcegraph Cody Rate Limit or Usage Limit Reached
- Sourcegraph Search Not Finding Results
- Sourcegraph Search Slow or Timing Out (Zoekt Crash Loop)
- Sourcegraph Upgrade Failed: Dirty Database Migration Error