Optional X Desktop / Disable X

It’s been a while since I disabled the X org services etc.

I need to boot my TK1 into “console” mode only. No X, Unity etc.

Maybe make X optional? StartX?

If you can show what what to murder I’d appreciate it!


The most simplest way on the board is leave the HDMI port unplugged.

I found this worked for me:

from a root shell

echo “manual” > /etc/init/failsafe-x.override
echo “manual” > /etc/init/lightdm.override

On reboot, X will not be started.

Can stop it with

$ sudo systemctl stop lightdm.service

Can prevent it from starting at boot with

$ sudo systemctl mask lightdm.service

Re-enable start at boot with

$ sudo systemctl unmask lightdm.service

The method suggested by @richc2 does work but is harder to revert and isn’t really part of systemd. It seems better to use regular systemd commands.
More info at https://www.freedesktop.org/software/systemd/man/systemctl.html#mask%20UNIT…
and https://www.digitalocean.com/community/tutorials/how-to-use-systemctl-to-manage-systemd-services-and-units#unit-management

Thanks for sharing.