API outputs bad status_message not reflecting current state

Bug #1836790 reported by Andres Rodriguez
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MAAS
Triaged
Low
Unassigned

Bug Description

I commissioned a machine several times, and this machine failed a few times. After it had failed, I also re-commissioned the machine and succeeded the last time.

However, the status_message still shows a message from a previous failure on a previous commissionning not reflecting reality:

        "status_message": "Node commissioning failure - 'cloudinit' running config-package-update-upgrade-install with frequency once-per-instance",

See that status_name is 'Ready' but status_message still shows 'Node commissioning failure'.

[
    {
        "swap_size": null,
        "system_id": "8crbdq",
        "pool": {
            "name": "default",
            "description": "Default pool",
            "id": 0,
            "resource_uri": "/MAAS/api/2.0/resourcepool/0/"
        },
        "physicalblockdevice_set": [
            {
                "firmware_version": "2.5+",
                "used_size": 21471690752,
                "uuid": null,
                "system_id": "8crbdq",
                "name": "sda",
                "storage_pool": null,
                "tags": [
                    "rotary"
                ],
                "model": "QEMU HARDDISK",
                "path": "/dev/disk/by-dname/sda",
                "id_path": "/dev/disk/by-id/ata-QEMU_HARDDISK_QM00001",
                "partitions": [
                    {
                        "uuid": "e6363d32-7c66-45ef-94ca-fee169c88e9f",
                        "size": 21466447872,
                        "bootable": false,
                        "tags": [],
                        "system_id": "8crbdq",
                        "device_id": 5,
                        "path": "/dev/disk/by-dname/sda-part1",
                        "used_for": "ext4 formatted filesystem mounted at /",
                        "type": "partition",
                        "filesystem": {
                            "fstype": "ext4",
                            "label": "root",
                            "uuid": "89216394-cf48-42bd-b049-d6befeda5be6",
                            "mount_point": "/",
                            "mount_options": null
                        },
                        "id": 2,
                        "resource_uri": "/MAAS/api/2.0/nodes/8crbdq/blockdevices/5/partition/2"
                    }
                ],
                "block_size": 4096,
                "size": 21474836480,
                "used_for": "MBR partitioned with 1 partition",
                "partition_table_type": "MBR",
                "type": "physical",
                "filesystem": null,
                "available_size": 0,
                "serial": "QM00001",
                "id": 5,
                "resource_uri": "/MAAS/api/2.0/nodes/8crbdq/blockdevices/5/"
            }
        ],
        "status": 4,
        "testing_status_name": "Passed",
        "hardware_uuid": "0FB1CAD2-8CA9-6C44-8367-F01EFEBB4C6C",
        "owner_data": {},
        "power_type": "virsh",
        "domain": {
            "authoritative": true,
            "ttl": null,
            "name": "maas",
            "is_default": true,
            "resource_record_count": 0,
            "id": 0,
            "resource_uri": "/MAAS/api/2.0/domains/0/"
        },
        "virtualblockdevice_set": [],
        "node_type": 0,
        "boot_interface": {
            "product": "Standard PC (i440FX + PIIX, 1996)",
            "firmware_version": null,
            "system_id": "8crbdq",
            "name": "ens3",
            "parents": [],
            "effective_mtu": 1500,
            "tags": [],
            "vendor": "QEMU",
            "params": "",
            "children": [],
            "mac_address": "52:54:00:93:81:22",
            "links": [
                {
                    "id": 20,
                    "mode": "auto",
                    "subnet": {
                        "name": "192.168.122.0/24",
                        "vlan": {
                            "vid": 0,
                            "mtu": 1500,
                            "dhcp_on": true,
                            "external_dhcp": null,
                            "relay_vlan": null,
                            "name": "untagged",
                            "space": "undefined",
                            "primary_rack": "qfwx7q",
                            "secondary_rack": null,
                            "fabric": "fabric-2",
                            "id": 5003,
                            "fabric_id": 2,
                            "resource_uri": "/MAAS/api/2.0/vlans/5003/"
                        },
                        "cidr": "192.168.122.0/24",
                        "rdns_mode": 2,
                        "gateway_ip": "192.168.122.1",
                        "dns_servers": [],
                        "allow_dns": true,
                        "allow_proxy": true,
                        "active_discovery": false,
                        "managed": true,
                        "space": "undefined",
                        "id": 2,
                        "resource_uri": "/MAAS/api/2.0/subnets/2/"
                    }
                }
            ],
            "discovered": [],
            "enabled": true,
            "type": "physical",
            "vlan": {
                "vid": 0,
                "mtu": 1500,
                "dhcp_on": true,
                "external_dhcp": null,
                "relay_vlan": null,
                "name": "untagged",
                "space": "undefined",
                "primary_rack": "qfwx7q",
                "secondary_rack": null,
                "fabric": "fabric-2",
                "id": 5003,
                "fabric_id": 2,
                "resource_uri": "/MAAS/api/2.0/vlans/5003/"
            },
            "id": 8,
            "resource_uri": "/MAAS/api/2.0/nodes/8crbdq/interfaces/8/"
        },
        "hardware_info": {
            "system_vendor": "QEMU",
            "system_product": "Standard PC (i440FX + PIIX, 1996)",
            "system_version": "pc-i440fx-bionic",
            "system_serial": "Unknown",
            "cpu_model": "Intel Core Processor (Skylake, IBRS)",
            "mainboard_vendor": "Unknown",
            "mainboard_product": "Unknown",
            "mainboard_firmware_version": "1.10.2-1ubuntu1",
            "mainboard_firmware_date": "04/01/2014"
        },
        "hwe_kernel": null,
        "bcaches": [],
        "current_installation_result_id": null,
        "commissioning_status": 2,
        "distro_series": "",
        "netboot": true,
        "disable_ipv4": false,
        "memory": 1024,
        "blockdevice_set": [
            {
                "id_path": "/dev/disk/by-id/ata-QEMU_HARDDISK_QM00001",
                "size": 21474836480,
                "block_size": 4096,
                "tags": [
                    "rotary"
                ],
                "used_size": 21471690752,
                "uuid": null,
                "system_id": "8crbdq",
                "name": "sda",
                "storage_pool": null,
                "model": "QEMU HARDDISK",
                "path": "/dev/disk/by-dname/sda",
                "partitions": [
                    {
                        "uuid": "e6363d32-7c66-45ef-94ca-fee169c88e9f",
                        "size": 21466447872,
                        "bootable": false,
                        "tags": [],
                        "system_id": "8crbdq",
                        "device_id": 5,
                        "path": "/dev/disk/by-dname/sda-part1",
                        "used_for": "ext4 formatted filesystem mounted at /",
                        "type": "partition",
                        "filesystem": {
                            "fstype": "ext4",
                            "label": "root",
                            "uuid": "89216394-cf48-42bd-b049-d6befeda5be6",
                            "mount_point": "/",
                            "mount_options": null
                        },
                        "id": 2,
                        "resource_uri": "/MAAS/api/2.0/nodes/8crbdq/blockdevices/5/partition/2"
                    }
                ],
                "used_for": "MBR partitioned with 1 partition",
                "partition_table_type": "MBR",
                "type": "physical",
                "filesystem": null,
                "available_size": 0,
                "serial": "QM00001",
                "id": 5,
                "resource_uri": "/MAAS/api/2.0/nodes/8crbdq/blockdevices/5/"
            }
        ],
        "tag_names": [
            "virtual",
            "pod-console-logging"
        ],
        "status_action": "modules-final/config-package-update-upgrade-install",
        "other_test_status": -1,
        "fqdn": "generic.maas",
        "architecture": "amd64/generic",
        "hostname": "generic",
        "cpu_speed": 2800,
        "volume_groups": [],
        "status_name": "Ready",
        "iscsiblockdevice_set": [],
        "locked": false,
        "pod": {
            "id": 2,
            "name": "brave-gator",
            "resource_uri": "/MAAS/api/2.0/pods/2/"
        },
        "testing_status": 2,
        "memory_test_status": -1,
        "other_test_status_name": "Unknown",
        "current_commissioning_result_id": 15,
        "boot_disk": {
            "firmware_version": "2.5+",
            "used_size": 21471690752,
            "uuid": null,
            "system_id": "8crbdq",
            "name": "sda",
            "storage_pool": null,
            "tags": [
                "rotary"
            ],
            "model": "QEMU HARDDISK",
            "path": "/dev/disk/by-dname/sda",
            "id_path": "/dev/disk/by-id/ata-QEMU_HARDDISK_QM00001",
            "partitions": [
                {
                    "uuid": "e6363d32-7c66-45ef-94ca-fee169c88e9f",
                    "size": 21466447872,
                    "bootable": false,
                    "tags": [],
                    "system_id": "8crbdq",
                    "device_id": 5,
                    "path": "/dev/disk/by-dname/sda-part1",
                    "used_for": "ext4 formatted filesystem mounted at /",
                    "type": "partition",
                    "filesystem": {
                        "fstype": "ext4",
                        "label": "root",
                        "uuid": "89216394-cf48-42bd-b049-d6befeda5be6",
                        "mount_point": "/",
                        "mount_options": null
                    },
                    "id": 2,
                    "resource_uri": "/MAAS/api/2.0/nodes/8crbdq/blockdevices/5/partition/2"
                }
            ],
            "block_size": 4096,
            "size": 21474836480,
            "used_for": "MBR partitioned with 1 partition",
            "partition_table_type": "MBR",
            "type": "physical",
            "filesystem": null,
            "available_size": 0,
            "serial": "QM00001",
            "id": 5,
            "resource_uri": "/MAAS/api/2.0/nodes/8crbdq/blockdevices/5/"
        },
        "cpu_test_status": -1,
        "power_state": "off",
        "osystem": "",
        "storage": 21474.83648,
        "raids": [],
        "commissioning_status_name": "Passed",
        "cpu_test_status_name": "Unknown",
        "interface_set": [
            {
                "product": "Standard PC (i440FX + PIIX, 1996)",
                "firmware_version": null,
                "system_id": "8crbdq",
                "name": "ens3",
                "parents": [],
                "effective_mtu": 1500,
                "tags": [],
                "vendor": "QEMU",
                "params": "",
                "children": [],
                "mac_address": "52:54:00:93:81:22",
                "links": [
                    {
                        "id": 20,
                        "mode": "auto",
                        "subnet": {
                            "name": "192.168.122.0/24",
                            "vlan": {
                                "vid": 0,
                                "mtu": 1500,
                                "dhcp_on": true,
                                "external_dhcp": null,
                                "relay_vlan": null,
                                "name": "untagged",
                                "space": "undefined",
                                "primary_rack": "qfwx7q",
                                "secondary_rack": null,
                                "fabric": "fabric-2",
                                "id": 5003,
                                "fabric_id": 2,
                                "resource_uri": "/MAAS/api/2.0/vlans/5003/"
                            },
                            "cidr": "192.168.122.0/24",
                            "rdns_mode": 2,
                            "gateway_ip": "192.168.122.1",
                            "dns_servers": [],
                            "allow_dns": true,
                            "allow_proxy": true,
                            "active_discovery": false,
                            "managed": true,
                            "space": "undefined",
                            "id": 2,
                            "resource_uri": "/MAAS/api/2.0/subnets/2/"
                        }
                    }
                ],
                "discovered": [],
                "enabled": true,
                "type": "physical",
                "vlan": {
                    "vid": 0,
                    "mtu": 1500,
                    "dhcp_on": true,
                    "external_dhcp": null,
                    "relay_vlan": null,
                    "name": "untagged",
                    "space": "undefined",
                    "primary_rack": "qfwx7q",
                    "secondary_rack": null,
                    "fabric": "fabric-2",
                    "id": 5003,
                    "fabric_id": 2,
                    "resource_uri": "/MAAS/api/2.0/vlans/5003/"
                },
                "id": 8,
                "resource_uri": "/MAAS/api/2.0/nodes/8crbdq/interfaces/8/"
            }
        ],
        "storage_test_status": 2,
        "zone": {
            "name": "default",
            "description": "",
            "id": 1,
            "resource_uri": "/MAAS/api/2.0/zones/default/"
        },
        "address_ttl": null,
        "node_type_name": "Machine",
        "special_filesystems": [],
        "default_gateways": {
            "ipv4": {
                "gateway_ip": "192.168.122.1",
                "link_id": null
            },
            "ipv6": {
                "gateway_ip": null,
                "link_id": null
            }
        },
        "memory_test_status_name": "Unknown",
        "description": "",
        "cpu_count": 1,
        "storage_test_status_name": "Passed",
        "current_testing_result_id": 17,
        "min_hwe_kernel": "",
        "status_message": "Node commissioning failure - 'cloudinit' running config-package-update-upgrade-install with frequency once-per-instance",
        "owner": null,
        "cache_sets": [],
        "ip_addresses": [],
        "resource_uri": "/MAAS/api/2.0/machines/8crbdq/"
    }
]

description: updated
summary: - [2.6] status_message has message even though it belongs to a previous
- state
+ [2.6] API outputs bad status_message not reflecting current state
Alberto Donato (ack)
summary: - [2.6] API outputs bad status_message not reflecting current state
+ API outputs bad status_message not reflecting current state
Changed in maas:
importance: Undecided → Medium
status: New → Triaged
Revision history for this message
Adam Collard (adam-collard) wrote :

Let's see if this still occurs - we should make sure we clear the status_message when we move to different statuses

Changed in maas:
importance: Medium → Low
milestone: none → 3.5.0
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.