mirror of
https://pagure.io/fedora-kickstarts.git
synced 2024-11-09 23:50:07 +00:00
🚮 Truncate /etc/resolv.conf from kickstart
During the kickstart of the cloud image, NetworkManager writes an /etc/resolv.conf that contains `nameserver 192.168.122.1`. This causes boot delays with cloud-init since it does some early boot DNS redirection tests before talking to the cloud's metadata service. On some clouds/architectures, this delay is 15 seconds or more. Truncate the /etc/resolv.conf so it can be replaced properly by NetworkManager and cloud-init on the first boot. Signed-off-by: Major Hayden <major@redhat.com>
This commit is contained in:
parent
4282a656dd
commit
ed9fb2fc19
@ -139,6 +139,11 @@ btrfs filesystem sync /
|
||||
echo "Cleanup leftover networking configuration"
|
||||
rm -f /etc/NetworkManager/system-connections/*.nmconnection
|
||||
|
||||
# Truncate the /etc/resolv.conf left over from NetworkManager during the
|
||||
# kickstart. This causes delays in boot with cloud-init because the
|
||||
# 192.168.122.1 DNS server cannot be reached.
|
||||
truncate -s 0 /etc/resolv.conf
|
||||
|
||||
# Clear machine-id on pre generated images
|
||||
truncate -s 0 /etc/machine-id
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user