Commit Graph
68568 Commits
Author SHA1 Message Date
Lennart Poettering 758d14767d kernel-install: make "inspect" work more like "add" regarding omission of parameters
This makes "kernel-install inspect" work more "kernel-install add": if
the version or kernel image is specified as "-" or omitted we'll make it
up.
2023-11-07 16:07:57 +01:00
Lennart Poettering ec1399f567 kernel-install: add add-all verb 2023-11-07 16:07:55 +01:00
Lennart Poettering 9d9e99a8f0 kernel-install: make version/kernel image parameters optional for "add"
Let's make kernel-install a bit easier to use:

If the kernel version is not specified, let's imply "uname -r", so that
we regnerate the entries for the current kernel.

If the kernel image is not specified let's imply using
/usr/lib/modules/$version/vmlinuz, i.e. the location distros like Fedora
drop the kernel into, which we generally recommend people to use.

If the kernel is not found there, don't try to automatically pick the
kernel path, and fail, as before.
2023-11-07 16:07:25 +01:00
Lennart Poettering 658e6cc4ae kernel-install: add command to list installed kernels
This simply dumps the dirs in /usr/lib/modules/ and whether they contain
a vmlinuz binary.
2023-11-07 16:07:05 +01:00
Lennart Poettering 6a20a9d286 string-util: add strdup_or_null() helper 2023-11-07 12:23:27 +01:00
Antonio Alvarez Feijoo 14ac242d50 bootspec: fix typo 2023-11-07 11:17:12 +00:00
Diego Viola b3e199cec8 TODO: fix more typos 2023-11-07 10:49:58 +01:00
Diego Viola 3a9e659a0e TODO: fix typos 2023-11-07 17:26:31 +09:00
Mike Yuan e592bf5d11 Merge pull request #29879 from Flowdalic/cgroup-memory-peak
cgroup: add support for memory.peak
2023-11-07 09:53:57 +08:00
Luca Boccassi 58a2ab5e9d Merge pull request #29888 from mrc0mmand/network-generator
test: add a couple of tests for systemd-network-generator
2023-11-07 00:10:43 +00:00
Daan De Meyer 04a8c2ce30 kernel-install: Add --root, --image and --image-policy
Currently only supported for the "inspect" verb as "add" and "remove"
require figuring out what to do with plugins.
2023-11-06 22:29:36 +01:00
Tad Fisher 4ca7c94e16 resolve: use exact-match domain as routing domain for single-labels
With ResolveUnicastSingleLabel=yes, a scope's search domains are affixed to the
query even when a routing domain matches the single-label query name,
preventing the use of dotless single-label domains entirely.

This changes dns_scope_name_wants_search_domain() to return false when the
scope contains an exact match of the single-label name in the query, allowing
lookups for dotless domains with ResolveUnicastSingleLabel enabled.
2023-11-06 22:27:12 +01:00
Luca Boccassi 4a5bf4896f Merge pull request #29882 from keszybz/documentation-cleanup
Documentation cleanup
2023-11-06 21:24:08 +00:00
Frantisek Sumsal 4457a2e0ee test: wait for the "latest" systemd-bsod message
Let's wait for the "latest" message systemd-bsod prints to the console
to appear, otherwise we might be too fast and take a console snapshot
before it contains all the information:

[   44.237788] testsuite-04.sh[1744]: + setterm --term linux --dump --file /tmp/console.dump
[   44.246089] systemd-bsod[1858]: QR code could not be printed, ignoring: Operation not supported
[   44.305692] testsuite-04.sh[1744]: + grep -aq 'The current boot has failed' /tmp/console.dump
[   44.308047] testsuite-04.sh[1744]: + grep -aq 'Service emergency message' /tmp/console.dump
[   44.311200] testsuite-04.sh[1744]: + grep -aq 'Press any key to exit' /tmp/console.dump
[   44.314359] testsuite-04.sh[1744]: + at_exit
[   44.315087] testsuite-04.sh[1744]: + local EC=1
[   44.315945] testsuite-04.sh[1744]: + [[ 1 -ne 0 ]]
[   44.316647] testsuite-04.sh[1744]: + [[ -e /tmp/console.dump ]]
[   44.318305] testsuite-04.sh[1744]: + cat /tmp/console.dump
[   44.319320] testsuite-04.sh[1871]:    The current boot has failed!
[   44.319970] testsuite-04.sh[1871]:    Service emergency message
2023-11-06 21:01:24 +00:00
Yu Watanabe d377949085 test-network: test MultiPathRoute= via another interface
Prompted by https://github.com/systemd/systemd/pull/14194#issuecomment-1795489641.
2023-11-06 20:59:49 +00:00
Frantisek Sumsal 6bc5de53e8 test: add a couple of tests for systemd-network-generator
Only for ip= stuff, for now.
2023-11-06 21:38:14 +01:00
Luca Boccassi 8691613c68 Merge pull request #29894 from bluca/typo
udev/man typos
2023-11-06 20:29:16 +00:00
Zbigniew Jędrzejewski-Szmek 0155b0657d man/systemd-stub: split and simplify a wall'o'text paragraph 2023-11-06 20:16:34 +01:00
Zbigniew Jędrzejewski-Szmek cae4ad367d man/networkctl,systemd-soft-reboot: capitalize and add periods
We added version information, so now each bullet point contains multiple
paragraphs, so we need proper sentences.
2023-11-06 20:16:34 +01:00
Zbigniew Jędrzejewski-Szmek de6d05d78d man: "Documentation" is not part of the title
<ulinks> contents are used to generate a SEE ALSO section at the
bottom of a man page, so we need to include the title, without additional
words, in the content.
2023-11-06 20:16:34 +01:00
Zbigniew Jędrzejewski-Szmek bf63dadbc6 man: more hyperlinks and other fixes
Closes https://github.com/systemd/systemd/issues/29814.
2023-11-06 20:16:34 +01:00
Zbigniew Jędrzejewski-Szmek 55e40b0be8 tree-wide: s/life-cycle/lifecycle/g 2023-11-06 20:16:34 +01:00
Zbigniew Jędrzejewski-Szmek f04aac3d5a docs: fix title levels, remove unneded words
The title applies to the whole page, not just the first section.
And there should be just one title ('# foo') in a given document.
2023-11-06 20:16:34 +01:00
Zbigniew Jędrzejewski-Szmek c8cd6d7bab man: use meaningful titles for <ulink>s
As pointed out in https://github.com/systemd/systemd/issues/29814, we need to
use phrases are are meaningful on their own, because the man page formatter
creates a list at the bottom. With <ulink>see docs</ulink>, we end up with:
  NOTES:
    1. see docs
       https://some.url/page
    2. see docs
       https://some.url/page2
which is not very useful :(

Also, the text inside the tag should not include punctuation.

Python helper:
  from xml_helper import xml_parse
  for p in glob.glob('../man/*.xml'):
       t = xml_parse(p)
       ulinks = t.iterfind('.//ulink')
       for ulink in ulinks:
           if ulink.text is None: continue
           text = ' '.join(ulink.text.split())
           print(f'{p}: {text}')
2023-11-06 20:16:34 +01:00
Daan De Meyer e94f0af168 Revert "mkosi: Use cache and build subdirectories"
We're not going ahead with the corresponding change in mkosi
after all so revert the preparatory change in systemd as well.

This reverts commit f756bcdf17.
2023-11-06 20:10:34 +01:00
Luca Boccassi 93c2d8d5c4 test: fix build without SBAT_DISTRO
Follow-up for c9bebec872
2023-11-06 19:05:47 +00:00
Luca Boccassi dfb4a66fd0 man: fix typo
allows to -> allows one to
2023-11-06 18:50:30 +00:00
Luca Boccassi a6b8ecf304 udev: ressize -> result_size
Lintian flags it as a typo of 'resize', so rename it and make it clearer too
2023-11-06 18:48:25 +00:00
Florian Schmaus 324ec6b5d2 run: include peak memory in output
Fixes #28542.

Signed-off-by: Florian Schmaus <flo@geekplace.eu>
2023-11-06 18:10:06 +01:00
Florian Schmaus 0531bded79 core: include peak memory in unit_log_resources()
Signed-off-by: Florian Schmaus <flo@geekplace.eu>
2023-11-06 18:08:33 +01:00
Florian Schmaus 6c71db763c cgroup: add support for memory.peak
Linux's Control Group v2 interfaces exposes memory.peak, which contains the
"max memory usage recorded for the cgroup and its descendants since the
creation of the cgroup."

This commit adds a new property "MemoryPeak" for units and makes "systemctl
show" display this value if it is available.

Fixes #29878.

Signed-off-by: Florian Schmaus <flo@geekplace.eu>
2023-11-06 18:08:33 +01:00
Frantisek Sumsal cc5244716b network-generator: allow specifying MAC address without MTU
Also, don't panic when both optional arguments are empty. This should
make the syntax compatible-ish with the dracut one from dracut.cmdline(7).

Resolves: #29855
2023-11-06 17:46:59 +01:00
Frantisek Sumsal 923599523c network-generator: correctly handle IPv6 DNS servers in ip=
IPv6 addresses in the ip= assignment need to be enclosed in [], which
was handled for all IP-related fields except for the two optional DNS
fields.
2023-11-06 17:45:57 +01:00
Peter Hutterer 351072ed71 login: switch an if condition to a switch statement
No functional changes but makes the code more readable once we expand
the list of device types.
2023-11-06 17:42:28 +01:00
Lennart Poettering 4685947138 update TODO 2023-11-06 17:42:28 +01:00
jjimbo137 b55ca26f5b tcrypt: try all entered passphrases instead of just the first one (#29837)
Previously only the first entered passphrase would be used.  Add the ability to check all the passwords entered by the user.  The total number of passwords entered is still limited by passphrase entry limit.
2023-11-06 16:39:01 +00:00
Antonio Alvarez Feijoo 4697ee9f43 bootctl: fix -q option
Follow up to 14e6e444dd
2023-11-06 16:36:38 +00:00
Antonio Alvarez Feijoo 1bc116a14a man/bootctl: fix --dry-run entry
Fixes 8702496bfb
2023-11-06 16:35:31 +00:00
Antonio Alvarez Feijoo 4e72e15647 man/measure: document --uname
Follow up to b6f2e68602
2023-11-06 16:35:18 +00:00
Yu Watanabe 3296b13b26 Merge pull request #29675 from DaanDeMeyer/kernel-install-json
kernel-install: Add --json option for inspect verb
2023-11-07 01:07:03 +09:00
Luca Boccassi 1e70a3c84f Merge pull request #29872 from yuwata/udevadm-trigger-receive-buffer-size
udevadm-trigger: extend receive buffer size
2023-11-06 14:43:23 +00:00
Lennart Poettering c5d77694eb pcrlock: show emojis for each PCR line
I am sorry, I totally forgot adding emojis reflecting the state of each
PCR. I hope I can do better in future, and hereby I'd like to rectify
the situation a bit.
2023-11-06 14:42:20 +00:00
Lennart Poettering 31a4796ee8 NEWS: drop left-over .md suffix 2023-11-06 15:18:40 +01:00
Daan De Meyer bdd36c003d kernel-install: Add --json option for inspect verb
In mkosi, we can't use kernel-install directly but we do want to
mimick its behavior as much as possible. Let's make that easier by
making it easy to fetch data from kernel-install as JSON.

To get all the necessary data, we extend the inspect verb to also
allow passing in a kernel version and initrds, to mimick the "add"
verb. The kernel version is used to determine the "Entry Directory",
and in absence of auto-detection of kernel version in kernel-install
we have to allow users to pass it.

We also add --no-pager while we're at it.
2023-11-06 14:43:09 +01:00
Daan De Meyer ad6216cbc7 boot-entry: Add boot_entry_token_type_to_string() 2023-11-06 14:39:01 +01:00
Daan De Meyer 30dd8e749b kernel-install: Fix doc whitespace 2023-11-06 14:39:01 +01:00
Luca Boccassi a9d942aeb0 NEWS: fix typo 2023-11-06 12:25:58 +00:00
Sam Leonard 4291f4461e vmspawn: extend kernel cmdline with extra args
This changes how the "extra" command line arguments passed to vmspawn
are handled.

Previously they were appended to the QEMU command line directly.
Now they are appended to the kernel command line using SMBIOS instead.
2023-11-06 11:46:38 +00:00
Luca Boccassi 12c8a7de12 Merge pull request #29875 from bluca/news
Update NEWS and hwdb
2023-11-06 11:43:21 +00:00
Yu Watanabe eba449fa81 sd-device-monitor: unconditionally increase buffer size by sd_device_monitor_new()
As suggested at https://github.com/systemd/systemd/pull/29872#discussion_r1382932633:
> socket memory is these days accounted to the process that owns a socket,
> hence we shouldn't be too concerned that this might waste memory.
2023-11-06 20:39:51 +09:00