-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Networking does not work with New Arch Installation #17
Comments
I have noticed this too, some Arch Linux upgrade broke something. |
@Andrei-Pozolotin any ideas? |
@CarstenFeuls Are you adding these to the rootfs or the initramfs? |
@ShapeShifter499 |
On my system the dynamic users 'systemd-resolve' and 'systemd-network' appear to be defined in the unit files themselves. http://0pointer.net/blog/dynamic-users-with-systemd.html |
@CarstenFeuls Why does this even work?
mkinitcpio-systemd-tool/initrd-build.sh Line 19 in 1e90560
My issue is that my system no longer gets a IP after power on, I cannot ssh in to remotely unlock my device with the scripts in mkinitcpio-systemd-tool. If adding users /etc/passwd and /etc/group work, I'm not sure why. I do know something is working because I can access the serial and it does get to the 'secret>' prompt for unlocking the rootfs encryption. |
Ok I completely removed the mkinitcpio-systemd-tool package and it's included files THEN I installed it again. I made some edits to the package that I now see was stupid. It is working for me as is again, no edits to /etc/passwd were necessary for my system. |
@ShapeShifter499 Long story short: There is no issue with it? |
@ml- Did upgrading the server fix the issue for you? |
@vauvenal5 You got me wrong. I didn't have this issue, but was afraid of upgrading the server because of it. (Info: my server was offline for a long time before) I just did a full pacman upgrade, everything worked fine after the reboot. I could enter the secret as usual. |
@ml- no issues here. Everything is working fine for me, glad it's also working for you too. |
I had the same behaviour like reported by @CarstenFeuls. More precisely the systemd-networkd and systemd-resolved services did not start because of the missing users. After manually adding them like suggested above everything worked fine. |
@vauvenal5 On Arch Linux? I just noticed that my /etc/passwd already has the below users. It doesn't include every user mentioned by @CarstenFeuls but it seems to just work. I'm wondering if there isn't maybe a bug somewhere in a package that left some users from being properly added in Arch Linux.
|
Yes on a fresh Arch Linux install. I only added the two users that where mentioned in the logs namely systemd-network and systemd-resolve and the according groups. After this it worked. I mean if it is not considered to be a bug it should maybe be mentioned somewhere that adding those users might be necessary. When known it is not a big deal to add them manually. |
@vauvenal5 I still don't quite understand why this works though. Isn't the scripts setup by mkinitcpio-systemd-tool removing 'systemd' users from /etc/passwd when the file is added to initramfs? |
I just installed a fresh Arch on a remote system so I can't really see what is going wrong without a remote KVM but adding the two missing users manually to the rootfs passwd solved the network issues for me. At least the network is up, the ssh server rejects my key "Permission denied (publickey)" but that must be a config error on my side :) EDIT: Found the reason about ssh: ed25519 keys are NOT supported. |
@ShapeShifter499 sry for the late reply. To be honest I haven't looked further into it yet, due to working fix and time constraints. |
Playing with a minimal (console only) ArchLinux fresh install in a VM, I encountered the same issue:
There seem to be issues with dynamic users in systemd as mentioned in systemd ticket #9503 pointing to debian ticket #902971. Apparently next systemd release should revert to creating those users again, at least until dynamic users work properly. As for other people here, to make it work I had to manually create the two users (and groups) mentioned in the logs. |
I moved away from Arch Linux ARM to a x86_64 Arch Linux system and I had to make the aforementioned modifications to '/etc/passwd' and '/etc/group'. Does it matter what user and group ID I used for the 'systemd-network' and 'systemd-resolve' users and groups? It would seem that it doesn't as long as I didn't make them the same as a any other user or group ID. |
@ShapeShifter499 As far as I know, what matters is indeed that the chosen IDs are not already used. |
It may not be really the case.
|
@suiryc nope, that didn't work. I tried changing "-----BEGIN OPENSSH PRIVATE KEY-----" to "-----BEGIN RSA PRIVATE KEY-----" AND "-----END OPENSSH PRIVATE KEY-----" to "-----END RSA PRIVATE KEY-----" I got the below error.
|
@suiryc Going forward, it would seem the only options for me would be. To shoehorn OpenSSH in place of Dropbear for the remote decryption. Or generate separate ssh host keys and have OpenSSH and Dropbear listening on different ports so that my local SSH client won't complain about mismatching host keys. |
I was seeing errors in my systemd units, specifically with shadow.service. The fix for the errors below is to run 'pwconv' and 'grpconv' to update the added entries from above made in '/etc/passwd' and '/etc/group' to the shadow files '/etc/shadow' and '/etc/gshadow'
|
By default openssh keys are in “RFC4716” format. To convert your openssh keys, you need to generate them in the PEM format.
You can now convert them with dropbearconvert |
@alkahan is PEM format insecure? |
PEM is not more or less secure than RFC4716. This is just another way to store the data (private or public keys). The is no security question here. |
please confirm if there are still issues at v17 |
Seems resolved for me here. But I'm not sure what others think. |
assume resolved |
I have got a Problem with a new Arch Installation.
The Network does not start at boot.
The Solution for me was to add this users to /etc/passwd.
systemd-journal-gateway:x:191:191:systemd-journal-gateway:/:/usr/bin/nologin
systemd-timesync:x:192:192:systemd-timesync:/:/usr/bin/nologin
systemd-network:x:193:193:systemd-network:/:/usr/bin/nologin
systemd-bus-proxy:x:194:194:systemd-bus-proxy:/:/usr/bin/nologin
systemd-resolve:x:195:195:systemd-resolve:/:/usr/bin/nologin
and the depending group also to /etc/group.
Before this doing the users are Dynamic user.
systemd-resolve::61662:61662:Dynamic User:/:/sbin/nologin
systemd-network::63822:63822:Dynamic User:/:/sbin/nologin
I dont know where this users are defined.
I think we need to include the file were the dynamic user are defined into the Initialramdisk.
The text was updated successfully, but these errors were encountered: