Comments (9)
- RE:
a lot of things around DNS resolution
Requires=systemd-resolved.service
is used (historically) to help with initial setup / network config debug
- RE:
the service keep running even after initrd
-
initrd-network.service (and its hard dependencies) should not be enabled outside of
initrd
mode due toConditionPathExists=/etc/initrd-release
stanza -
this is likely an issue specific to your setup, please try to trace dependencies more carefully
-
for example, one could use
systemd-analyze
:
https://www.freedesktop.org/software/systemd/man/systemd-analyze.html
systemd-analyze dot systemd-resolved* | dot -T png > systemd-resolved.png
systemd-analyze dot initrd* | dot -T png > systemd-total.png
systemd-analyze dot --order initrd* | dot -T png > systemd-order.png
systemd-analyze dot --require initrd* | dot -T png > systemd-require.png
from mkinitcpio-systemd-tool.
Not sure if I was clear, but resolved is started during initrd, and never stopped. Anyway, here are the pictures.
from mkinitcpio-systemd-tool.
resolved is started during initrd, and never stopped
ok, then:
- if you comment out
Requires=systemd-resolved.service
ininitrd-network.service
- is
systemd-resolved.service
still active afterinitrd
?
from mkinitcpio-systemd-tool.
If I comment out this line, systemd-resolved
is never started, and thus is not active after initrd
(nor during it).
from mkinitcpio-systemd-tool.
ok, thinking
from mkinitcpio-systemd-tool.
please verify the following workaround:
https://www.freedesktop.org/software/systemd/man/systemd.unit.html#StopWhenUnneeded=
- create service overrides
/etc/systemd/system/systemd-networkd.service.d/override.conf
[Unit]
StopWhenUnneeded=yes
/etc/systemd/system/systemd-resolved.service.d/override.conf
[Unit]
StopWhenUnneeded=yes
- remove service autostart
systemctl disable systemd-networkd.service
systemctl disable systemd-resolved.service
- refresh service cache
systemctl daemon-reload
- perform image rebuild and system reboot
mkinitcpio -p linux
systemctl reboot
- confirm that both services are active during
initrd
and inactive duringrootfs
from mkinitcpio-systemd-tool.
there seems no elegant way to make this any more simple,
so will treat this use case and the workaround as a "feature" not a "bug"
from mkinitcpio-systemd-tool.
The workaround works fine, thanks.
from mkinitcpio-systemd-tool.
Sorry for the long delay (for some reason both unbound and systemd-resolved were binding to :53 without issue, so my system happened to work even if I did not take care of this, but after recently upgrading with the tinyssh key changes I’ve remembered about this issue), but indeed the workaround works fine, and since I’m using systemd-networkd
I’ve only add the override for systemd-resolved
, and that was enough. Maybe this should be documented then?
from mkinitcpio-systemd-tool.
Related Issues (20)
- Instances of templated service units are currently not supported
- boot loop with systemd 253 HOT 1
- initrd-shell should not use /root/.ssh/authorized_keys HOT 1
- 38: InitrdPath for authorized_keys is not correct
- Custom authorized_keys implemented in #104 breaks existing installations HOT 2
- Error running initrd-shell.sh on boot
- update systemd/udev groups HOT 1
- Dropbear does not work on fresh installation HOT 2
- protect root user password hash
- Provide LUKS passphrase via SSH non-interactively HOT 4
- Wireless interface name not restored after initrd HOT 1
- Configuration permissions issue HOT 1
- Unlocking SED drives HOT 4
- [tinyssh-convert] command usage changed HOT 3
- Proposal to move upstream HOT 6
- Required dependencies HOT 2
- Get a remote key to open a luks device HOT 1
- Has this project been abandoned? HOT 2
- tpm2-tss libraries are not installed to the initrd. They are required for TPM unlock. HOT 1
- FIDO2 PIN input support
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mkinitcpio-systemd-tool.