0

I am new to Linux. I have installed Arch Linux on a new machine.

Yesterday I tried to install GNOME (on top of Xorg). When I enabled gdm.service and then rebooted, I was met with a black screen. I think either I messed this up or because my machine has an NVIDIA card.

I have a bootable USB. I realize that I can simply chroot into my machine and then just use systemctl to disable gdm.service BUT I was wondering if I can edit my systemd files to disable it myself and learn a bit about service management in the meantime.

Is this feasible/a good idea? I found the gdm.service file in /lib/systemd/system. Can I change one of the variables or delete the file altogether to have the same effect? For example, there is a variable in this file, Restart=always. If I change this value will I prevent the service from being run during the boot process?

Are there any good resources which explain what is really going on when using systemctl commands? I'm guessing that enabled services have a larger footprint then just these files in the /lib/systemd/system directory.

start a service a at bootime in systemd states that systemctl enable creates symbolic links to the /lib/systemd/system files. Where are these symbolic links and can I edit them manually?

1 Answer 1

0

When systemd disables masks a service, it actually sets a symlink to /dev/null instead - see How to disable a service without using 'systemctl disable'

Additionally, don't edit the files in /lib/systemd/system/ - instead you make a copy in /etc/systemd/system/ and then edit your copy. That allows the other ones to be owned by your system's package manager, etc. See RHEL docs for more info. I know you said Arch, but systemd is systemd.

4
  • Thank you so much Aaron.
    – MagicGAT
    Apr 16, 2020 at 3:07
  • The first paragraph is contradicted by all of the answers that it then points to.
    – JdeBP
    Apr 16, 2020 at 11:00
  • @JdeBP maybe your problem was that I was using mask and disable interchangeably? I tweaked it. Apr 16, 2020 at 21:34
  • Your answer saying wrong things is your problem, not mine. (-: Now you aren't even talking about the thing that the question here asks about, or that the Q&A that you point to talk about.
    – JdeBP
    Apr 17, 2020 at 7:42

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .