cloud-init schema validation warnings - unexpected "id" property in network_config
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
curtin |
New
|
Undecided
|
Unassigned |
Bug Description
When deploying custom images in MAAS, based on RHEL (Rocky Linux), Curtin is
generating a network config that breaks the cloud-init schema validation.
These are the logs from a deployment:
cloud-init[1469]: start: cmd-install/
cloud-init[1469]: start: cmd-install/
cloud-init[1469]: start: cmd-install/
cloud-init[1469]: net-meta mode is 'custom'. devices=[]
cloud-init[1469]: writing to file /tmp/tmp8xr53mn
cloud-init[1469]: config:
cloud-init[1469]: - id: ens3
cloud-init[1469]: mac_address: 52:54:00:29:c0:c6
cloud-init[1469]: mtu: 1500
cloud-init[1469]: name: ens3
cloud-init[1469]: subnets:
cloud-init[1469]: - address: 192.168.50.12/24
cloud-init[1469]: dns_nameservers:
cloud-init[1469]: - 192.168.50.10
cloud-init[1469]: dns_search:
cloud-init[1469]: - maas
cloud-init[1469]: gateway: 192.168.50.1
cloud-init[1469]: type: static
cloud-init[1469]: type: physical
cloud-init[1469]: - address:
cloud-init[1469]: - 192.168.50.10
cloud-init[1469]: search:
cloud-init[1469]: - maas
cloud-init[1469]: type: nameserver
cloud-init[1469]: version: 1
Output of the schema validation from cloud-init:
# cloud-init schema --system
Found cloud-config data types: user-data, vendor-data, network-config
1. user-data at /var/lib/
Empty 'cloud-config' found at /var/lib/
2. vendor-data at /var/lib/
Valid schema vendor-data
3. network-config at /var/lib/
Invalid network-config /var/lib/
Error: Cloud config schema errors: config.0: Additional properties are not allowed ('id' was unexpected), config.0: {'id': 'ens3', 'mac_address': '52:54:
Error: Invalid schema: network-config
And in /var/log/
schema.py[WARNING]: Invalid network-config provided:
config.0: Additional properties are not allowed ('id' was unexpected)
config.0: {'id': 'ens3', 'mac_address': '52:54:
Although the schema warning is displayed, networking is successfully configured:
networking.
stages.py[DEBUG]: applying net config names for {'config': [{'id': 'ens3', 'mac_address': '52:54:
subp.py[DEBUG]: Running command ['ip', '-6', 'addr', 'show', 'permanent', 'scope', 'global'] with allowed return codes [0] (shell=False, capture=True)
subp.py[DEBUG]: Running command ['ip', '-4', 'addr', 'show'] with allowed return codes [0] (shell=False, capture=True)
__init__.py[DEBUG]: Detected interfaces {'ens3': {'downable': False, 'device_id': '0x0001', 'driver': 'virtio_net', 'mac': '52:54:
__init__.py[DEBUG]: no work necessary for renaming of [['52:54:
stages.py[INFO]: Applying network configuration from system_cfg bringup=True: {'config': [{'id': 'ens3', 'mac_address': '52:54:
__init__.py[DEBUG]: Selected renderer 'sysconfig' from priority list: ['sysconfig', 'eni', 'netplan', 'network-manager', 'networkd']
description: | updated |