Comment 6 for bug 1871021

Revision history for this message
Felipe Alencastro (falencastro) wrote :

After marking a machine as broken this was what I had to do in order to restore it to it's previous state:

update maasserver_node set owner_id=5, osystem='ubuntu', distro_series='jammy', hwe_kernel='hwe-22.04', agent_name='37e6a200-908d-464d-85bb-fcc7cf12d6e8', netboot='f', current_installation_script_set_id=1538, enable_hw_sync='t' where system_id='ru3chp';
insert into maasserver_filesystem ("created", "updated", "uuid", "fstype", "label", "mount_point", "acquired", "partition_id", "block_device_id", "filesystem_group_id", "create_params", "cache_set_id", "mount_options", "node_config_id") values ('2024-02-21 19:02:52.970848+00', '2024-02-21 19:02:52.970848+00', 'e01f283f-0c3e-4724-98d6-233470798bcc', 'fat32', 'efi', '/boot/efi', 't', 737, NULL, NULL, NULL, NULL, NULL, 218);
insert into maasserver_filesystem ("created", "updated", "uuid", "fstype", "label", "mount_point", "acquired", "partition_id", "block_device_id", "filesystem_group_id", "create_params", "cache_set_id", "mount_options", "node_config_id") values ('2024-02-21 19:02:53.024758+00', '2024-02-21 19:02:53.024758+00', '99f89676-a456-48c6-a4c0-d4a4df7745b2', 'ext4', 'root', '/', 't', NULL, 578, NULL, NULL, NULL, NULL, 218);
update maasserver_staticipaddress set ip='192.168.0.120' where id=13179;
insert into maasserver_interface_ip_addresses ("interface_id", "staticipaddress_id") values (5982, 13179);

The last two have to be done for each ip address the machine has.