I am running Debian Jessie which uses SystemD. I have so far been unable to find a way to stop X11 from starting on bootup. The raspi-config setting apparently does not do anything.

Can anyone help?

  • Are you using systemd w/ jessie?
    – goldilocks
    Commented May 11, 2015 at 16:15
  • @goldilocks : systemd came free with jessie. I didn't specifically request it.
    – John Smith
    Commented May 11, 2015 at 16:16
  • All apologies -- I did not notice you mentioned systemd in the original question.
    – goldilocks
    Commented May 11, 2015 at 20:30
  • I just created a new SD card from the latest image ("2015-11-21" at the time) from the Raspberry Pi site. Modifying the 3 Boot Options setting in raspi-config to B1 Console worked fine for me on next reboot. They may have fixed an issue.
    – patridge
    Commented Dec 8, 2015 at 15:31

4 Answers 4


Systemd users "service bunlde" named target, to achieve different system states while booting the system. You need to change the desired state of the system, from graphical to multi-user.


systemctl get-default

Will show you


You could change it with

sudo systemctl set-default multi-user.target

I could recommend this article to understand how to work with systemd https://www.digitalocean.com/community/tutorials/how-to-use-systemctl-to-manage-systemd-services-and-units

  • Thank you, raspi-config wasn't working for me. This is exactly what I needed on Stretch.
    – mrswadge
    Commented May 20, 2019 at 23:06

The GUI login is lightdm (the dm is for display manager). This is started as an init service, and the init system on Jessie is systemd.

I believe the name of the service is also "lightdm". You can confirm that:

systemctl list-units | grep lightdm

The middle columns should say "loaded active" and the first one "lightdm.service". Presuming that's it, to disable on boot:

sudo systemctl disable lightdm
  • 1
    I have tried it, and lightdm still comes up on reboot.
    – John Smith
    Commented May 11, 2015 at 21:51
  • Go figure. Try update-rc.d lightdm disable as well; I haven't had much of a look at whatever transitional mess is involved in Debian switching to systemd. If all that doesn't work just uninstall the whole thing (apt-get remove lightdm), and if that doesn't work give up -- your system is haunted ;)
    – goldilocks
    Commented May 12, 2015 at 8:38
  • I even tried systemctl mask, and it still brings back lighted. Also I tried "systemctl disable graphical", and it also fails. I believe my machine is haunted.
    – John Smith
    Commented May 12, 2015 at 23:58
  • If you've tried both update-rc.d disable and systemctl disable, at this point it shouldn't be considered anything other than a screw-up by the Raspbian crew and you should report it as such (raspbian.org/RaspbianBugs). I have an upgraded-to-jessie pi, but lightdm was removed before the upgrade; there is no reason a GUI login should be inescapable on any GNU/Linux system. The easy way for you, if you don't care, should be just the apt-get remove; doing a bug report is more tedious, but if you are up to it, remember to give them a link to here in the report.
    – goldilocks
    Commented May 13, 2015 at 0:43

This worked on my Raspbian/Jessie:

sudo systemctl set-default multi-user.target

I can still manually start lightdm via

sudo service lightdm start


sudo lightdm

The Debian way to enable or disable services is to use update-rc.d. You can use

update-rc.d lightdm disable

if in fact lightdm is the display manager installed.

If you need to run it once, you can

service lightdm start

update the systemd way to do it is in fact to use systemctl disable like indicated in the other answer

  • "The Debian way" here is their twist/tweak on the SysV init way of doing things. Debian used SysV for ~20 years, up until Jessie, and the default is now systemd. They have (apparently) added functionality to update-rc.d to make it work with systemd for people used to doing it the old way, but if this is all new to you, you might as well learn the new way -- SysV is now pretty much dead on linux.
    – goldilocks
    Commented May 11, 2015 at 19:41
  • As you say it, update-rc still works with systemd so why not use it? Debian, as other distributions, has a lot of scripts to manage the system, I don't see a reason to not use them. But I'm willing to learn the systemd way of doing it if you know it.
    – daks
    Commented May 11, 2015 at 19:58
  • hum maybe the 'systemctl disable lightdm' you indicated in the answer is this way. I read it quickly and thought it was a command to disable it once and not forever.
    – daks
    Commented May 11, 2015 at 20:01
  • It's the same as sysv that way, there's stop and disable. WRT how you do it, if there's a way you are familiar and comfortable with that works then there's no harm in sticking with it (at least for a while), but if you are new to all this init service stuff (I'm presuming the OP is), then it would be a bit silly to start learning depreciated methodologies.
    – goldilocks
    Commented May 11, 2015 at 20:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.