[systemd-devel] The best way to execute kexec via dbus

Tomáš Hnyk tomashnyk at gmail.com
Fri Aug 26 19:56:45 UTC 2022


On Friday 26. August 2022, 16:29:04 (+02:00), Andrei Borzenkov wrote:

> Please answer to the list, not me personally. You do it second time.
>
Sorry, most other mailing lists I am on have reply-to-list as default, I will pay attention to it.  


> On 26.08.2022 17:12, Tomáš Hnyk wrote:
> > On Friday 26. August 2022, 15:02:54 (+02:00), Andrei Borzenkov wrote:
> > Indeed, the above makes these two work (included when launched from the GUI), thanks!:
> > sudo systemctl start kexec.target --job-mode=replace-irreversibly --no-block
> > qdbus --system org.freedesktop.systemd1 /org/freedesktop/systemd1 org.freedesktop.systemd1.Manager.StartUnit kexec.target replace-irreversibly
> >
> > Is this a misconfiguration on my part or is that something that should be filled as a bug?
>
> This should be filed as a bug. It is expected to work (IMHO).
>

I will do that once I update distro to a recent systemd (should be in October), I am on 249 and only 250 and 251 are allowed for bugreports, as I just found out.
 

>
> > systemd-analyze gives "Startup finished in 8.467s (firmware) + 402ms (loader) + 3.001s (kernel) + 2.885s (userspace) = 14.756s"
> > Those eight seconds in firmware are why I am after kexec. Grub gives 4 seconds in loader, only systemd is this fast. I am not sure how to check if I booted useing systemd-boot otherwise.
>
> It does not really matter for this specific problem. What matters is
> that your have systemd-boot configuration where systemctl can find
> suitable boot entry. Of course, it you do not actually use systemd-boot
> this can be considered a bug as well, but do not mix two independent issues.
>
> > efibootmgr gives:
> >
> >
> > BootOrder: 0000,0001,0019,001A,001D,001E,0010,0011,0012,0013,0014,0015,0020,0022,0023,0024,001B,001C,001F,0003
> > Boot0000* Linux Boot Manager
> > Boot0001* ubuntu
> > Boot0003* Linux-Firmware-Updater
> >
> > So I do not understand why the kexec kernel is not loaded, should I remove grub completely?
> >
>
> I do not understand this last sentence.

I was asking if uninstalling grub might make kexec work, but as per your comment above, that is independent.

Thanks for your help!
Tomas


More information about the systemd-devel mailing list