[fde] Upgrading pc-kernel requires 2 reboots

Bug #2032951 reported by Jean-Baptiste Lallement
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
snapd (Ubuntu)
New
Undecided
Unassigned

Bug Description

I upgraded pc-kernel manually for testing purpose with the following command:

snap ack ./pc-kernel_1393.assert
snap install ./pc-kernel_1393.snap

It then requires two reboots. The upgrade first stops on:

```
2023-08-24T12:22:41Z INFO Task set to wait until a manual system restart allows to continue
WARNING: pressing ctrl-c will abort the running change.
```

At this stage, snap changes show:
```
ID Status Spawn Ready Summary
1 Done today at 14:18 CEST today at 14:19 CEST Initialize system state
2 Doing today at 14:19 CEST - Initialize device
3 Do today at 14:22 CEST - Install "pc-kernel" snap from file "pc-kernel_1393.snap"
```

$ snap change 3
```
Status Spawn Ready Summary
Done today at 14:22 CEST today at 14:22 CEST Ensure prerequisites for "pc-kernel" are available
Done today at 14:22 CEST today at 14:22 CEST Prepare snap "/var/lib/snapd/snaps/.local-install-4024362358" (1393)
Done today at 14:22 CEST today at 14:22 CEST Mount snap "pc-kernel" (1393)
Done today at 14:22 CEST today at 14:22 CEST Run pre-refresh hook of "pc-kernel" snap if present
Done today at 14:22 CEST today at 14:22 CEST Stop snap "pc-kernel" services
Done today at 14:22 CEST today at 14:22 CEST Remove aliases for snap "pc-kernel"
Done today at 14:22 CEST today at 14:22 CEST Make current revision for snap "pc-kernel" unavailable
Done today at 14:22 CEST today at 14:22 CEST Update assets from kernel "pc-kernel" (1393)
Done today at 14:22 CEST today at 14:22 CEST Copy snap "pc-kernel" data
Done today at 14:22 CEST today at 14:22 CEST Setup snap "pc-kernel" (1393) security profiles
Wait today at 14:22 CEST - Make snap "pc-kernel" (1393) available to the system
Do today at 14:22 CEST - Automatically connect eligible plugs and slots of snap "pc-kernel"
Do today at 14:22 CEST - Set automatic aliases for snap "pc-kernel"
Do today at 14:22 CEST - Setup snap "pc-kernel" aliases
Do today at 14:22 CEST - Run post-refresh hook of "pc-kernel" snap if present
Do today at 14:22 CEST - Start snap "pc-kernel" (1393) services
Do today at 14:22 CEST - Clean up "pc-kernel" (1393) install
Do today at 14:22 CEST - Run configure hook of "pc-kernel" snap if present
Do today at 14:22 CEST - Run health check of "pc-kernel" snap

......................................................................
Update assets from kernel "pc-kernel" (1393)

2023-08-24T12:22:34Z INFO No gadget assets update needed

......................................................................
Make snap "pc-kernel" (1393) available to the system

2023-08-24T12:22:41Z INFO Task set to wait until a manual system restart allows to continue
```

I rebooted which triggered the installation of the kernel. After first reboot.

```
snap changes

ID Status Spawn Ready Summary
1 Done today at 14:18 CEST today at 14:19 CEST Initialize system state
2 Doing today at 14:19 CEST - Initialize device
3 Done today at 14:22 CEST today at 14:25 CEST Install "pc-kernel" snap from file "pc-kernel_1393.snap"

```

```
snap change 3

Status Spawn Ready Summary
Done today at 14:22 CEST today at 14:22 CEST Ensure prerequisites for "pc-kernel" are available
Done today at 14:22 CEST today at 14:22 CEST Prepare snap "/var/lib/snapd/snaps/.local-install-4024362358" (1393)
Done today at 14:22 CEST today at 14:22 CEST Mount snap "pc-kernel" (1393)
Done today at 14:22 CEST today at 14:22 CEST Run pre-refresh hook of "pc-kernel" snap if present
Done today at 14:22 CEST today at 14:22 CEST Stop snap "pc-kernel" services
Done today at 14:22 CEST today at 14:22 CEST Remove aliases for snap "pc-kernel"
Done today at 14:22 CEST today at 14:22 CEST Make current revision for snap "pc-kernel" unavailable
Done today at 14:22 CEST today at 14:22 CEST Update assets from kernel "pc-kernel" (1393)
Done today at 14:22 CEST today at 14:22 CEST Copy snap "pc-kernel" data
Done today at 14:22 CEST today at 14:22 CEST Setup snap "pc-kernel" (1393) security profiles
Done today at 14:22 CEST today at 14:24 CEST Make snap "pc-kernel" (1393) available to the system
Done today at 14:22 CEST today at 14:25 CEST Automatically connect eligible plugs and slots of snap "pc-kernel"
Done today at 14:22 CEST today at 14:25 CEST Set automatic aliases for snap "pc-kernel"
Done today at 14:22 CEST today at 14:25 CEST Setup snap "pc-kernel" aliases
Done today at 14:22 CEST today at 14:25 CEST Run post-refresh hook of "pc-kernel" snap if present
Done today at 14:22 CEST today at 14:25 CEST Start snap "pc-kernel" (1393) services
Done today at 14:22 CEST today at 14:25 CEST Clean up "pc-kernel" (1393) install
Done today at 14:22 CEST today at 14:25 CEST Run configure hook of "pc-kernel" snap if present
Done today at 14:22 CEST today at 14:25 CEST Run health check of "pc-kernel" snap

......................................................................
Update assets from kernel "pc-kernel" (1393)

2023-08-24T12:22:34Z INFO No gadget assets update needed

......................................................................
Make snap "pc-kernel" (1393) available to the system

2023-08-24T12:22:41Z INFO Task set to wait until a manual system restart allows to continue
```

A second reboot is necessary to load the new kernel.

No notification has been displayed on the desktop.

Tags: fde
Revision history for this message
Alfonso Sanchez-Beato (alfonsosanchezbeato) wrote :

Why do you think that the second reboot is necessary? Afaiu the change shows that after the first reboot all tasks are Done and no further reboot is required. The new kernel should be the one running already after the first reboot.

Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

I still don't see the devices that were missing firmware after the first reboot and I've to reboot a second time to load the firmware.

Revision history for this message
Philip Meulengracht (the-meulengracht) wrote (last edit ):

Jean, can you confirm this is indeed a replicate of bug https://bugs.launchpad.net/snapd/+bug/2033138 ? Because this sounds like a different issue here?

And is this on Desktop or Core? (It looks like it's FDE desktop?)

Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

I tried an upgrade from 23.10/stable to 23.10/candidate and cannot reproduce the "boot twice" issue. Only the "hang during install" remains. I'm marking this bug as dup of 2033138

Revision history for this message
Philip Meulengracht (the-meulengracht) wrote :

I've been trying to reproduce your issue by upgrading to the 1393 pc-kernel on FDE desktop, unfortunately with no success so far.

Can I ask which source revision you were upgrading from?

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.