Repository navigation
resolved: add varlink API for resolving raw RRs - #31616
Merged
Merged
Conversation
poettering
force-pushed
the
resolved-varlink-resolve-record
branch
from
March 4, 2024 13:51
87a0052 to
e40d1c8
Compare
poettering
force-pushed
the
resolved-varlink-resolve-record
branch
from
March 4, 2024 15:21
e40d1c8 to
e021b96
Compare
poettering
force-pushed
the
resolved-varlink-resolve-record
branch
from
March 5, 2024 14:46
e021b96 to
e3f2ccb
Compare
…solve interface Let's define this in the generic interface and then import it into the Monitor interface too. This is preparation for adding an interface to resolve arbitrary RRs via Varlink, which means we want the type in both interfaces.
Now that we have an address, hostname, and service resolve, at the last kind of resovler we expose over D-Bus also to Varlink.
poettering
force-pushed
the
resolved-varlink-resolve-record
branch
from
March 6, 2024 18:02
e3f2ccb to
cf1c8cd
Compare
bluca
approved these changes
Mar 6, 2024
debarshiray
added a commit
to debarshiray/toolbox
that referenced
this pull request
Nov 17, 2026
Currently, the DNS test in Arch Linux containers fails on Ubuntu 22.04
hosts:
not ok 184 network: DNS inside Arch Linux in 715ms
# tags: arch-fedora runtime-environment
# (from function `assert_line' in file
test/system/libs/bats-assert/src/assert.bash, line 488,
# in test file test/system/203-network.bats, line 283)
# `assert_line --index 0 "$ipv4_addr"' failed
#
# -- line differs --
# index : 0
# expected : 193.0.14.129
# actual :
# --
#
This is because the underlying resolvectl(1) invocation fails:
$ resolvectl --legend false --no-pager --type A query
k.root-servers.net
k.root-servers.net: resolve call failed:
org.varlink.service.MethodNotFound
In systemd 262, resolvectl(1) was changed to communicate with
systemd-resolved(8) using Varlink APIs instead of their D-Bus
counterparts. One of them was the ResolveRecord method [1], known as
io.systemd.Resolve.ResolveRecord in the Varlink API and as
org.freedesktop.resolve1.Manager.ResolveRecord in the D-Bus variant.
However, the ResolveRecord method was only exposed through Varlink in
systemd 256 [2] and Ubuntu 22.04 only has systemd 249. This breaks the
compatibility between resolvectl(1) and systemd-resolved(8).
It seems that these days the arch-toolbox image includes python3(1),
which it originally didn't, and the nss-resolve(8) plugin for the GNU
Name Service Switch (or NSS) functionality of the GNU C Library doesn't
use ResolveRecord. Therefore, resolvectl(1) can be replaced by using
getaddrinfo(3), which is a front-end to nss-resolve(8), through
python3(1).
[1] systemd commit cfac7ec169892b38
systemd/systemd@cfac7ec169892b38
systemd/systemd#41840
[2] systemd commit cf1c8cdb87d4e2c1
systemd/systemd@cf1c8cdb87d4e2c1
systemd/systemd#31616
containers#1859
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This includes commits from #31580 and #31613, since this PR touches lines also included in those PR.
Those other PRs should be merged before this one hence.