| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
Currently app_1.0.raw is refused if it contains extension-release.d/extension-release.app,
which stops one from using versioned images without using the force flag to disable
the check. Relax it so that only the actual name, and not the version, is compared, like
it already happens in other places.
|
|\
| |
| | |
network: several fixlets for PersistLeases=
|
| |
| |
| |
| |
| |
| | |
Follow-up for a3ed665a29ea9355c78a2a6b3a032b9504499dd6.
Fixes https://github.com/systemd/systemd/pull/31977#discussion_r1542196572.
|
| |
| |
| |
| | |
Follow-up for a3ed665a29ea9355c78a2a6b3a032b9504499dd6.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When an option is delegated from an upstream server, its lifetime
may be limited by a time. Such functionality will be used later by
sd-radv.
This also remove 'offset' argument from the option setter
ndisc_option_set_xyz(), and make it update existing option.
See comments in ndisc_option_add_link_layer_address() for more details.
|
| |
| |
| |
| |
| |
| | |
The function add_match_this_boot() calls sd_journal_add_conjunction(),
hence, we cannot specify multiple devices in the extra match arguments,
e.g., "journalctl /dev/sda /dev/sdb" shows no entry.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This fixes a race condition crash in homed that would happen in the
following sequence of events:
1. Client 1 takes a ref on the home area
2. Client 1 calls some method via dbus
3. Client 2 calls Release()
In homed, the Release() would check if a ref is still held (in this
case: yes it is) and returns an error. Except that is done through a
code-path that asserts that no operations are ongoing. In this case,
it's valid to have an ongoing operation, and so the assertion fails
causing homed to crash.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When sd-run connects to D-Bus rather than the private socket, it will
generate the transient unit name using the bus ID assigned by the D-Bus
broker/daemon. The issue is that this ID is only unique per D-Bus run,
if the broker/daemon restarts it starts again from 1, and it's a simple
incremental counter for each client.
So if a transient unit run-u6.service starts and fails, and it is not
collected (default on failure), and the system soft-reboots, any new
transient unit might conflict as the counter will restart:
Failed to start transient service unit: Unit run-u6.service was already loaded or has a fragment file.
Get the soft-reboot counter, and if it's greater than zero, append it
to the autogenerated unit name to avoid clashes.
|
|\ \
| |/
|/| |
journalctl-authenticate: several cleanups
|
| |
| |
| |
| | |
No functional change, just refactoring.
|
| |
| |
| |
| |
| |
| | |
This also
- use path_join(),
- rename variables to more descriptive names.
|
| |
| |
| |
| |
| |
| | |
Follow-up for 7560fffcd2531786b9c1ca657667a43e90331326.
Addresses https://github.com/systemd/systemd/pull/31879#discussion_r1539063239.
|
| |
| |
| |
| |
| |
| |
| | |
I am not sure it is explicitly documented that /var/log/journal should
be a directory, rather than a symlink to a directory, but the current
code of journald seems not to support symlinked directory well. Let's
refuse that at least here and now.
|
|/
|
|
| |
Follow-up for 3a51e31be9f626cf772733cb289ed64739fab0e4.
|
|
|
|
|
|
| |
Clamp times and start counting from when soft-reboot is started
to avoid creating a huge graph, like it's done for the user
instance.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The method returns prematurely (before jobs it triggers terminate). This
is externally visible because other methods may fail if jobs did not
finish.
Postpone the DBus method response until we collect all signals for
finished jobs.
systemd-timedated keeps track of in-flight DBus requests and answers
them all in unspecified order when jobs finish. The capacity of requests
in systemd-timedated is limited.
Fixes: #17739
|
|
|
|
| |
Requested at https://github.com/systemd/systemd/pull/31772#issuecomment-2000053357.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
```
[1237/2836] Compiling C object journalctl.p/src_journal_journalctl-show.c.o
FAILED: journalctl.p/src_journal_journalctl-show.c.o
cc -Ijournalctl.p -I. -I.. -Isrc/basic -I../src/basic -Isrc/fundamental -I../src/fundamental -Isrc/systemd -I../src/systemd -I../src/libsystemd/sd-bus -I../src/libsystemd/sd-device -I../src/libsystemd/sd-event -I../src/libsystemd/sd-hwdb -I../src/libsystemd/sd-id128 -I../src/libsystemd/sd-journal -I../src/libsystemd/sd-netlink -I../src/libsystemd/sd-network -I../src/libsystemd/sd-resolve -Isrc/shared -I../src/shared -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -std=gnu11 -O0 -g -Wno-missing-field-initializers -Wno-unused-parameter -Wno-nonnull-compare -Warray-bounds -Warray-bounds=2 -Wdate-time -Wendif-labels -Werror=format=2 -Werror=format-signedness -Werror=implicit-function-declaration -Werror=implicit-int -Werror=incompatible-pointer-types -Werror=int-conversion -Werror=missing-declarations -Werror=missing-prototypes -Werror=overflow -Werror=override-init -Werror=return-type -Werror=shift-count-overflow -Werror=shift-overflow=2 -Werror=undef -Wfloat-equal -Wimplicit-fallthrough=5 -Winit-self -Wlogical-op -Wmissing-include-dirs -Wmissing-noreturn -Wnested-externs -Wold-style-definition -Wpointer-arith -Wredundant-decls -Wshadow -Wstrict-aliasing=2 -Wstrict-prototypes -Wsuggest-attribute=noreturn -Wunused-function -Wwrite-strings -Wzero-length-bounds -fdiagnostics-show-option -fno-common -fstack-protector -fstack-protector-strong --param=ssp-buffer-size=4 -Wno-unused-result -Werror=shadow -fno-strict-aliasing -fvisibility=hidden -fno-omit-frame-pointer -include config.h -pthread -MD -MQ journalctl.p/src_journal_journalctl-show.c.o -MF journalctl.p/src_journal_journalctl-show.c.o.d -o journalctl.p/src_journal_journalctl-show.c.o -c ../src/journal/journalctl-show.c
../src/journal/journalctl-show.c: In function ‘setup_event’:
../src/journal/journalctl-show.c:330:38: error: ‘STDOUT_FILENO’ undeclared (first use in this function)
330 | r = sd_event_add_io(e, NULL, STDOUT_FILENO, EPOLLHUP|EPOLLERR, NULL, INT_TO_PTR(-ECANCELED));
| ^~~~~~~~~~~~~
../src/journal/journalctl-show.c:330:38: note: each undeclared identifier is reported only once for each function it appears in
[1238/2836] Compiling C object journalctl.p/src_journal_journalctl-util.c.o
FAILED: journalctl.p/src_journal_journalctl-util.c.o
cc -Ijournalctl.p -I. -I.. -Isrc/basic -I../src/basic -Isrc/fundamental -I../src/fundamental -Isrc/systemd -I../src/systemd -I../src/libsystemd/sd-bus -I../src/libsystemd/sd-device -I../src/libsystemd/sd-event -I../src/libsystemd/sd-hwdb -I../src/libsystemd/sd-id128 -I../src/libsystemd/sd-journal -I../src/libsystemd/sd-netlink -I../src/libsystemd/sd-network -I../src/libsystemd/sd-resolve -Isrc/shared -I../src/shared -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -std=gnu11 -O0 -g -Wno-missing-field-initializers -Wno-unused-parameter -Wno-nonnull-compare -Warray-bounds -Warray-bounds=2 -Wdate-time -Wendif-labels -Werror=format=2 -Werror=format-signedness -Werror=implicit-function-declaration -Werror=implicit-int -Werror=incompatible-pointer-types -Werror=int-conversion -Werror=missing-declarations -Werror=missing-prototypes -Werror=overflow -Werror=override-init -Werror=return-type -Werror=shift-count-overflow -Werror=shift-overflow=2 -Werror=undef -Wfloat-equal -Wimplicit-fallthrough=5 -Winit-self -Wlogical-op -Wmissing-include-dirs -Wmissing-noreturn -Wnested-externs -Wold-style-definition -Wpointer-arith -Wredundant-decls -Wshadow -Wstrict-aliasing=2 -Wstrict-prototypes -Wsuggest-attribute=noreturn -Wunused-function -Wwrite-strings -Wzero-length-bounds -fdiagnostics-show-option -fno-common -fstack-protector -fstack-protector-strong --param=ssp-buffer-size=4 -Wno-unused-result -Werror=shadow -fno-strict-aliasing -fvisibility=hidden -fno-omit-frame-pointer -include config.h -pthread -MD -MQ journalctl.p/src_journal_journalctl-util.c.o -MF journalctl.p/src_journal_journalctl-util.c.o.d -o journalctl.p/src_journal_journalctl-util.c.o -c ../src/journal/journalctl-util.c
../src/journal/journalctl-util.c: In function ‘acquire_journal’:
../src/journal/journalctl-util.c:36:60: error: ‘STDIN_FILENO’ undeclared (first use in this function)
36 | r = sd_journal_open_files_fd(&j, (int[]) { STDIN_FILENO }, 1, arg_journal_additional_open_flags);
| ^~~~~~~~~~~~
../src/journal/journalctl-util.c:36:60: note: each undeclared identifier is reported only once for each function it appears in
```
Fixes ade2db83fe7fa5011490f94fbeb5cf9263f26514
|
|
|
|
|
| |
Currently this is not used, but will be used later to modify the sender
address.
|
|
|
|
| |
Currently, these are not used, but will be used later in sd-radv.
|
|\
| |
| | |
logs-show: several cleanups
|
| |
| |
| |
| | |
No functional change, just refactoring.
|
| |
| |
| |
| |
| |
| |
| | |
And rename it to id128_get_boot_for_machine().
This also splits out id128_get_boot() from sd_id128_get_boot(), and
make id128_get_boot_for_machine() use it.
|
|\ \
| | |
| | | |
journalctl-filter: several cleanups
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
- split it into small pieces to reduce indentation,
- return earlier if no filter specified,
- use journal_add_matchf() and journal_add_match_pair(),
chase_and_stat(), is_symlink(), and sd_device_new_from_devname(),
- replace sd_device_get_devname() + stat() with sd_device_get_devnum(),
- refuse to install filter by path with --root, --image, or --machine
at least now, as previously it has not worked anyway.
|
| | |
| | |
| | |
| | |
| | | |
Otherwise, if --facility= is specified with extra matches with '+',
the facility filter will not be applied to the specified filter after '+'.
|
| | |
| | |
| | |
| | |
| | |
| | | |
- declare iterator in loop,
- use journal_add_match_pair() and journal_add_matchf(),
- log failures in the caller.
|
| |/
| |
| |
| |
| |
| |
| |
| |
| | |
- add missing assertions,
- use set_ensure_consume() and strv_consume(),
- use string_hash_ops_free and _cleanup_set_free_,
- use strv_fnmatch_full(),
- replace unused counter with a boolean flag,
- return earlier if no unit filtering is requested.
|
| |
| |
| |
| |
| | |
Allow to query via D-Bus how many times the current booted system has
been soft rebooted
|
| |
| |
| |
| |
| | |
The firmware/loader/kernel times are no longer relevant for the startup
sequence on soft-reboot, so use only the userspace timestamps
|
| |
| |
| |
| |
| | |
Will be useful to calculate how long it took to shut down the system before starting
in the new root
|
| |
| |
| |
| |
| |
| | |
Otherwise the de-serialization overwrites the timestamps taken after
soft-reboot (e.g.: userspace start/finish) and sd-analyze shows bogus
data
|
|\ \
| | |
| | | |
Pass socket FDs to all ExecXYZ= commands in socket unit but ExecStartPre=
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Today listen file descriptors created by socket unit don't get passed to
commands in Exec{Start,Stop}{Pre,Post}= socket options.
This prevents ExecXYZ= commands from accessing the created socket FDs to do
any kind of system setup which involves the socket but is not covered by
existing socket unit options.
One concrete example is to insert a socket FD into a BPF map capable of
holding socket references, such as BPF sockmap/sockhash [1] or
reuseport_sockarray [2]. Or, similarly, send the file descriptor with
SCM_RIGHTS to another process, which has access to a BPF map for storing
sockets.
To unblock this use case, pass ListenXYZ= file descriptors to ExecXYZ=
commands as listen FDs [4]. As an exception, ExecStartPre= command does not
inherit any file descriptors because it gets invoked before the listen FDs
are created.
This new behavior can potentially break existing configurations. Commands
invoked from ExecXYZ= might not expect to inherit file descriptors through
sd_listen_fds protocol.
To prevent breakage, add a new socket unit parameter,
PassFileDescriptorsToExec=, to control whether ExecXYZ= programs inherit
listen FDs.
[1] https://docs.kernel.org/bpf/map_sockmap.html
[2] https://lore.kernel.org/r/20180808075917.3009181-1-kafai@fb.com
[3] https://man.archlinux.org/man/socket.7#SO_INCOMING_CPU
[4] https://www.freedesktop.org/software/systemd/man/latest/sd_listen_fds.html
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
We normally expect sd-resolved only to return the validated subset of a
validated response. In some cases we give up on validating, because we
have enough information already to conclude the answer is bogus.
Let's be sure to always reply with only the validated subset in these
cases too, so that we don't return bogus answers and confuse primitive
clients that won't see the SERVFAIL rcode.
|
| | |
| | |
| | |
| | | |
Fixes: ce5b9d5b3c24 ("resolved: request DS with DNSKEY")
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Fixes a bug introduced in e44f06065bf20e8d0e4adacff61350ebd36f299e: it was
supposed to be a refactoring, but unfortunately FOREACH_ARRAY is implemented
using a for loop, so when the 'goto finish' was replaced by 'break', it only
broke the inner loop, leading to a infinite loop.
|
|/ /
| |
| |
| | |
Follow-up for 5ec87d577f92effe27a62e965e02a6f9a40f81cc.
|
|\ \
| | |
| | | |
resolved: support reloading configuration at runtime
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Drop connections and caches and reload config from files, to allow
for low-interruptions updates, and hook up to the usual SIGHUP and
ExecReload=. Mark servers and services configured directly via D-Bus
so that they can be kept around, and only the configuration file
settings are dropped and reloaded.
Fixes https://github.com/systemd/systemd/issues/17503
Fixes https://github.com/systemd/systemd/issues/20604
|
|\ \ \
| | | |
| | | | |
core/execute: check if EXEC_PASS_FDS is set if got exec_params.fds
|
| | | |
| | | |
| | | |
| | | |
| | | | |
Prompted by #31789 (specifically
https://github.com/systemd/systemd/pull/31789#discussion_r1525267612)
|
| | | |
| | | |
| | | |
| | | | |
SOCKET(u) returns NULL if the type doesn't match.
|
|\ \ \ \
| | | | |
| | | | | |
Some follow-ups for capsule
|
| | | | |
| | | | |
| | | | |
| | | | | |
Follow-up for ad963c3f5680796ccd094b81f35ff7aa20b57247
|
| | |/ /
| |/| |
| | | |
| | | |
| | | | |
Follow-up for 56cb74c3cd1358d7d0b3f613feaf2eeab601a6bd
and 00431b2b66cb59540deda4ea018170a289673585
|
| |_|/
|/| | |
|
|\ \ \
| | | |
| | | | |
journalctl: split journalctl.c into small pieces
|
| | | |
| | | |
| | | |
| | | | |
No functional change, just refactoring.
|
| | | |
| | | |
| | | |
| | | |
| | | | |
And introduces per-action functions.
No functional change, just refactoring.
|