Subject: Disable stock networking by editing a file

From: Liam Proven <[email-masked]>
Date: Sun, 3 Nov 2024 15:08:11 +0000

My first post _about_ Alpine _from_ Alpine.

(Not from the affected machine, obviously.)

I messed up a reinstall on one of my testbed boxes. It freezes, hard,
on the login screen.

I think it may be the situation described here:
https://bbs.archlinux.org/viewtopic.php?id=285972

I may well have installed Network Manager _before_ disabling the
standard DHCP client.

The machine has 5 OSes: XP64, OpenBSD, NetBSD, Alpine and
Crunchbang++. The boot manager is Grub provided by Crunchbang.

I can't easily boot into Alpine but I can simply mount the filesystem
and edit files.

So, I can't, for instance, do:

$ doas systemctl disable dhcpcd

How can I achieve the same result by editing a file from a different distro?

-- 
Liam Proven ~ Profile: https://about.me/liamproven
Email: [email-masked] ~ gMail/gTalk/FB: [email-masked]
Twitter/LinkedIn: lproven ~ Skype: liamproven
IoM: (+44) 7624 227612: UK: (+44) 7939-087884
Czech [+ WhatsApp/Telegram/Signal]: (+420) 702-829-053

---

From: "Sertonix" <[email-masked]>
Date: Sun, 03 Nov 2024 14:37:00 +0000

> How can I achieve the same result by editing a file from a different distro?

All the enabled services are specified inside of /etc/runlevels/.

I don't know what issue you are having but disabling a service can be done
like this:

$ doas unlink etc/runlevels/default/networkmanager

And enabling like this:

$ doas ln -s /etc/init.d/networkmanager etc/runlevels/default/

('default' is the runlevel. Some services have different runlevels but I
don't think the network related services.)

---

From: Ralf Mardorf <[email-masked]>
Date: Sun, 03 Nov 2024 16:52:39 +0100

On Sun, 2024-11-03 at 14:37 +0000, Sertonix wrote:
> On Sun, 2024-11-03 at 15:08 +0000, Liam Proven wrote:

Hi Liam,

Alpine's init isn't systemd ;).

> 
> I don't know what issue you are having but disabling a service can be
> done like this:
> 

Liam inadvertently didn't kept in mind that systemd doesn't matter. Btw.
if systemd had played a role, he for example could have run systemctl
from another Linux via systemd-nspawn.

Regards,
Ralf

---

From: Liam Proven <[email-masked]>
Date: Mon, 4 Nov 2024 18:06:09 +0000

> Alpine's init isn't systemd ;).

D'oh. Of course! How very stupid of me not to notice that.

I merely picked a random example of someone with a similar problem --
and I picked very poorly. Apologies.

---

From: Liam Proven <[email-masked]>
Date: Mon, 4 Nov 2024 18:04:52 +0000

> don't think the network related services.)

Excellent -- thanks, I will try that.