1
0
mirror of https://github.com/systemd/systemd.git synced 2024-11-02 02:21:44 +03:00
Commit Graph

7 Commits

Author SHA1 Message Date
Frantisek Sumsal
f2ef6d98e6 test: fix partition check in TEST-58-REPART
Follow-up to 1c41c1dc34.
2021-05-07 21:17:22 +02:00
Zbigniew Jędrzejewski-Szmek
f89a20f1d4 TEST-58: exit immediately if systemd-repart is not available
Debian disables systemd-repart at config time.
2021-04-23 15:12:38 +02:00
Zbigniew Jędrzejewski-Szmek
b0f04bafe0 TEST-58: remove stale artifacts to not fail on repeated invocations
We would remove stuff only if successful, so repeated invocations would
trivially fail.

Also drop "-f", so that if we expect to remove something, it must be there.
2021-04-23 15:11:38 +02:00
Zbigniew Jędrzejewski-Szmek
30f56248f5 TEST-58: adjust whitespace and enable pipefail 2021-04-23 15:11:38 +02:00
Lennart Poettering
5a3b86404a test: add test for new repart features 2021-04-19 23:19:52 +02:00
Yu Watanabe
1ebcf47296 test: merge udev tests 2021-03-05 18:36:04 +09:00
Luca Boccassi
e26fe5f911 portable: add 'reattach' verb and DBUS interface
Add 'reattach' verb to portablectl, and corresponding DBUS interface
to systemd-portabled.
Takes the same parameters as 'attach', but it will do a 'detach' (and
it will refuse to proceed if it cannot be done) first, matching on
the unversioned prefix of the new image. Eg:

portablectl reattach /tmp/foo_2.raw

will cause foo_1.raw to be detached, and foo_2.raw to be attached.

The key difference with a manual 'detach old' plus 'attach new' is that
the running units are not disturbed until after the attach completed,
and if --now is passed they are then restarted.
A 'detach' is not allowed normally if the units are running.

By using a restart-after-deploy method, 'reattach' allows for minimal
interruption of service and also for features that only work on restart
(eg: file descriptor store) to work as intended.

The DBUS interface returns two lists: first the removals from the detach
that were not immediately re-added in the attach, so that the caller
can stop the relevant units, and then the list of additions that are
either new or updates, so that the caller can restart/enable the
relevant units. portablectl already implements this with the existing
--now/--enable switches.
2021-02-10 19:07:36 +00:00