1
0
mirror of https://github.com/systemd/systemd.git synced 2025-01-11 09:18:07 +03:00
Commit Graph

75317 Commits

Author SHA1 Message Date
Jeffrey Bosboom
f7fa632682 docs/CONTROL_GROUP_INTERFACE.md: document accounting information available via D-Bus 2024-07-25 11:46:18 +01:00
Luca Boccassi
3bf483fc4f
Merge pull request #33727 from intelfx/work/analyze-capability-masks
analyze: capability: add support for decoding capability masks
2024-07-25 11:08:21 +01:00
Mike Yuan
268f58076f basic/log: do not treat all negative errnos as synthetic
Currently, IS_SYNTHETIC_ERRNO() evaluates to true for all negative errnos,
because of the two's-complement negative value representation.
Subsequently, ERRNO= is not logged for most of our own code.
Let's fix this, by formatting all synthetic errnos as positive.
Then, treat all negative values as non-synthetic.

While at it, mark the evaluation order explicitly, and remove
unneeded comment.

Fixes #33800
2024-07-25 12:03:59 +02:00
Ivan Shapovalov
3e7a029c28 analyze: capability: add support for decoding capability masks
This adds support in `systemd-analyze capability` for decoding
capability masks (sets), e.g.:

```console
$ systemd-analyze capability --mask 0000000000003c00
NAME                 NUMBER
cap_net_bind_service     10
cap_net_broadcast        11
cap_net_admin            12
cap_net_raw              13
```

This is intended as a convenience tool for pretty-printing capability
values as found in e.g. `/proc/$PID/status`.
2024-07-24 17:25:47 +02:00
Luca Boccassi
11d5e2b5fb mkosi: update debian commit reference
* c7138e0b87 Configure default DNS servers for upstream CI builds
* bc5d1afe1e Drop out-of-tree localed patch and use D-Bus policy instead
* b5f8ababde autopkgtest: set Release= in mkosi.local.conf to distinguish testing vs unstable
* 323afafd80 autopkgtest: add allow-stderr to timedated test
* 0291f361e3 Install valrinkctl zsh completion file
* f40b9eba02 d/t/control: add Depends: lib{systemd,udev}-dev for upstream
* 3def595de3 d/t/upstream: ensure correct ubuntu codename is used
* 531bb6817e d/t/boot-and-services: fix a couple python sytax warnings
* 963ac13b7d d/t/boot-and-services: skip test_tmp_cleanup if tmp.mount is overridden
2024-07-24 11:38:55 +01:00
MkKvcs
af5195f7a6 hwdb: add axis range corrections for the Lenovo Thinkpad E16 2024-07-24 08:24:36 +01:00
Luca Boccassi
acf0851dcf
Merge pull request #33823 from YHNdnzj/varlink-deserialize-again
core: reliably check if varlink socket has been deserialized; switch varlink server to pidref
2024-07-24 08:23:36 +01:00
vdovhanych
2cf425ec57 add udev rules for trezor hw wallet devices 2024-07-24 08:22:44 +01:00
Ronan Pigott
ddec353749 resolved: report svc params as a json object
This representation is significantly more useful. The previous array
format omitted the svc param key, which is not very useful.
2024-07-24 08:18:47 +01:00
Luca Boccassi
0d45d0ec58
Merge pull request #33810 from YHNdnzj/find-executable-simplify
path-util: minor cleanup for find_executable()
2024-07-23 23:08:19 +01:00
Luca Boccassi
3ac19d384d
Merge pull request #33809 from YHNdnzj/pidref-namespace
namespace-util: introduce pidref_namespace_open() and use it where appropriate; clean up mount-util a bit along the way
2024-07-23 23:03:26 +01:00
Luca Boccassi
8da8d6ce30
Merge pull request #33535 from neighbourhoodie/tests/dns-cache
Tests for DnsCache functions
2024-07-23 19:01:23 +01:00
Luca Boccassi
5aaf33ec96
Merge pull request #33534 from neighbourhoodie/tests/dns-query
Tests for DnsQuery functions
2024-07-23 18:47:14 +01:00
Mike Yuan
b4ff314ea0
core-varlink: switch to PidRef + manager_get_unit_by_pidref() 2024-07-23 19:38:58 +02:00
Mike Yuan
3ff91850a5
core-varlink: do not log about ENOENT if oomd isn't available
This is simply too noisy, since every invocation of
manager_varlink_send_managed_oom_update() would try to
connect to oomd if not already.
2024-07-23 19:38:58 +02:00
Mike Yuan
16d8249ae4
core-varlink: add missing runtime_scope check for manager_varlink_init_user() 2024-07-23 19:38:57 +02:00
Mike Yuan
d4e5c66ed4
core: reliably check if varlink socket has been deserialized
Follow-up for 6906c028e8

The mentioned commit uses access() to check if varlink socket
already exists in the filesystem, but that isn't sufficient.

> Varlink sockets are not serialized until v252, so upgrading from
> v251 or older means we will not listen anymore on the varlink sockets.
>
> See https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1074789
> for more details as this was found when updating from Debian Bullseye to a new version.

After this commit, the set up of varlink_server is effectively
split into two steps. manager_varlink_init_system(), which is
called after deserialization, would no longer skip listening
even if Manager.varlink_server is in place, but actually
check if we're listening on desired sockets.
Then, manager_deserialize() can be switched back to using
manager_setup_varlink_server().

Alternative to #33817

Co-authored-by: Luca Boccassi <bluca@debian.org>
2024-07-23 19:38:57 +02:00
Mike Yuan
e633e8627f
mount-util: reorder params for mount_in_userspace, clean up logging 2024-07-23 19:31:32 +02:00
Mike Yuan
974e34a018
mount-util: do not unnecessarily acquire mountns fd twice
This also enables us to use pidref_namespace_open().
2024-07-23 19:30:55 +02:00
Mike Yuan
706302897a
mount-util: clean up mount_exchange_graceful a bit, don't duplicate move_mount when fallback 2024-07-23 19:30:55 +02:00
Mike Yuan
ca13d3fc19
machine-dbus: use pidref_namespace_open() where appropriate 2024-07-23 19:30:55 +02:00
Mike Yuan
86a3c1fd95
namespace-util: introduce pidref_namespace_open() 2024-07-23 19:30:54 +02:00
Mike Yuan
30957ced45
namespace-util: explicitly specify namespace_info[]'s size
We do this already in all string lookup tables. This way
it's guaranteed that iterators which ends with _NAMESPACE_TYPE_MAX
wouldn't overrun the array.
2024-07-23 19:30:54 +02:00
Mike Yuan
0e7eda91f4
path-util: simplify final path for find_executable()
Currently, systemd-run ./test.sh would set Description=
to $PWD/./test.sh. This is quite ugly.
2024-07-23 18:48:15 +02:00
Mike Yuan
51b271ead7
path-util: trivial cleanup for find_executable_full() 2024-07-23 18:48:15 +02:00
Mike Yuan
7973f33e81 core: clean up Set/LoadCredential= parsers
Make logging consistent, plus introduce helper function
for adding creds to ExecContext.set_credential too.
2024-07-23 15:53:38 +01:00
Daan De Meyer
fffbfb4ed1 mkosi: Bump device timeout even more
I still manage to hit it in some cases so let's bump again.
2024-07-23 15:49:37 +01:00
Luca Boccassi
d111d76844 Merge pull request #33533 from neighbourhoodie/tests/dns-synthesize 2024-07-23 15:44:40 +01:00
James Coglan
5301548fbb resolved: tests for dns_synthesize_family() and dns_synthesize_protocol() 2024-07-23 15:44:07 +01:00
James Coglan
6fd7fc92cf resolved: tests for dns_synthesize_answer() 2024-07-23 15:44:07 +01:00
Mary Strodl
c73883143a sd-dhcp-server: persist hardware addresses in leases 2024-07-23 14:55:48 +01:00
James Coglan
538a3dc298 resolved: tests for dns_query_string() 2024-07-23 14:17:23 +01:00
James Coglan
c080825f14 resolved: tests for dns_query_go(); multiple search domains for dns_query_candidate_notify() 2024-07-23 14:17:23 +01:00
James Coglan
0a547aea96 resolved: refactor environment management in dns_query_go() tests 2024-07-23 14:17:23 +01:00
James Coglan
8501f44563 resolved: tests for dns_query_go() when configured with search domains 2024-07-23 14:17:23 +01:00
James Coglan
cc3bad9d70 resolved: tests for dns_query_go() when no scopes are available 2024-07-23 14:17:23 +01:00
James Coglan
5d5f86431f resolved: tests for dns_query_go() using a bypass query 2024-07-23 14:17:23 +01:00
James Coglan
16078b8172 resolved: tests for dns_query_go() -- with and without network link 2024-07-23 14:17:23 +01:00
James Coglan
7d5ad4f88e resolved: tests for dns_query_process_cname_one(); no match, DNAME, utf-8 handling 2024-07-23 14:17:23 +01:00
James Coglan
9add77fafb resolved: tests for dns_query_process_cname_many() 2024-07-23 14:17:23 +01:00
James Coglan
47eb7e0bf2 resolved: tests for common usage of dns_query_process_cname_one() 2024-07-23 14:17:23 +01:00
James Coglan
e5d246b488 resolved: tests for dns_query_make_auxiliary() 2024-07-23 14:17:22 +01:00
James Coglan
792a738625 resolved: tests for dns_query_new() 2024-07-23 14:17:21 +01:00
James Coglan
f5dd610978 resolved: tests for dns_cache_lookup() clamping the TTL 2024-07-23 14:08:31 +01:00
James Coglan
1074c9001d resolved: tests for dns_cache_put() for NXDOMAIN with no SOA 2024-07-23 14:08:31 +01:00
James Coglan
6b864ea813 resolved: test that pseudo classes and types are not cached 2024-07-23 14:08:31 +01:00
James Coglan
7137086fa0 resolves: tests for dns_cache_prune() 2024-07-23 14:08:31 +01:00
James Coglan
3f6ae4a062 resolved: tests for dns_cache_check_conflicts() 2024-07-23 14:08:31 +01:00
James Coglan
42547022fd resolved: tests for dns_cache_export_shared_to_packet() 2024-07-23 14:08:31 +01:00
James Coglan
5b61b34ad0 resolved: tests for dns_cache_lookup(); mDNS and multiple matching entries 2024-07-23 14:08:31 +01:00