π ~1 min read
Table of contents
Symptom & Impact
Boot times are prolonged due to repeated datasource discovery retries.
Environment & Reproduction
Common on cloned images moved between cloud and non-cloud platforms.
cloud-init status --long
systemd-analyze blame | grep cloud-init
Root Cause Analysis
cloud-init probes metadata endpoints that are unreachable in current environment.
Quick Triage
Check active datasource list and timeout behavior.
grep -R datasource_list /etc/cloud /etc/cloud/cloud.cfg.d 2>/dev/null
Step-by-Step Diagnosis
Review cloud-init logs to confirm datasource retry loops.
sudo journalctl -u cloud-init -n 120 --no-pager
sudo cloud-init status --long

Solution – Primary Fix
Limit datasource list to the platform in use and clean stale cloud-init cache.
Still having issues? Our Server Management team can diagnose and resolve this for you. Get in touch for a free consultation.
echo 'datasource_list: [ NoCloud ]' | sudo tee /etc/cloud/cloud.cfg.d/99-datasource.cfg
sudo cloud-init clean

Solution – Alternative Approaches
Disable cloud-init stages that are not needed for static server deployments.
sudo cloud-init status --long
Verification & Acceptance Criteria
Boot completes without excessive cloud-init wait time and status reaches done.
cloud-init status --wait
Rollback Plan
Remove custom datasource config and restore default cloud-init files.
sudo rm -f /etc/cloud/cloud.cfg.d/99-datasource.cfg
Prevention & Hardening
Bake environment-specific cloud-init settings into base images.
sudo cloud-init schema --system
Related Errors & Cross-Refs
Related to delayed networking and duplicate hostname initialization.
Related tutorial: View the step-by-step tutorial for Ubuntu 24.04 LTS.
View all Ubuntu 24.04 LTS tutorials on the Tutorials Hub β
Browse all common problems & solutions on the Tutorials Hub.
References & Further Reading
Ubuntu cloud-init datasource and boot optimization documentation.
Need Expert Help?
If you cannot resolve this yourself, our team offers hands-on Server Management, Managed IT Services, and flexible Support Plans. Contact us today β we respond within one business day.