Affected versions: Ubuntu 22.04 LTS

πŸ“– ~1 min read

Table of contents
  1. Symptom & Impact
  2. Environment & Reproduction
  3. Root Cause Analysis
  4. Quick Triage
  5. Step-by-Step Diagnosis
  6. Solution – Primary Fix
  7. Solution – Alternative Approaches
  8. Verification & Acceptance Criteria
  9. Rollback Plan
  10. Prevention & Hardening
  11. Related Errors & Cross-Refs
  12. References & Further Reading

Symptom & Impact

Manual network settings revert after reboot, causing IP drift and service interruptions.

Environment & Reproduction

Typical on cloud images where cloud-init remains active after conversion to long-lived servers.

Root Cause Analysis

cloud-init datasource metadata applies boot-time network templates that override local netplan customizations.

Quick Triage

Identify whether active netplan file is cloud-init generated.

Step-by-Step Diagnosis

Review cloud-init logs and datasource state to verify repeated network rendering.

Illustrative mockup for ubuntu-22-04-lts β€” network_config
cloud-init rewrites netplan during boot β€” Illustrative mockup β€” Progressive Robot

Solution – Primary Fix

Disable cloud-init network rendering and apply controlled netplan configuration.

Still having issues? Our IT Solutions & Services team can diagnose and resolve this for you. Get in touch for a free consultation.

Illustrative mockup for ubuntu-22-04-lts β€” log_or_config
Disabling cloud-init network config and pinning netplan β€” Illustrative mockup β€” Progressive Robot

Solution – Alternative Approaches

Keep cloud-init but provide explicit datasource network config that matches desired static settings.

Verification & Acceptance Criteria

Reboots preserve intended netplan state and cloud-init no longer rewrites network files.

Rollback Plan

Remove disable file and rerun cloud-init clean/init if reverting to cloud-managed lifecycle.

Prevention & Hardening

Decide ownership of network config early in image lifecycle and enforce via provisioning policy.

Related to DNS regressions, interface renaming issues, and boot-time route loss.

Related tutorial: View the step-by-step tutorial for Ubuntu 22.04 LTS.

View all Ubuntu 22.04 LTS tutorials on the Tutorials Hub β†’

Browse all common problems & solutions on the Tutorials Hub.

References & Further Reading

cloud-init and Ubuntu netplan documentation for persistent network configuration.

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.