Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[Solved] Starting GDM on boot -- can't enable with systemctl

Graphical Environments, Managers, Multimedia & Desktop questions.
Post Reply
Message
Author
aselker
Posts: 8
Joined: 2018-06-07 04:03

[Solved] Starting GDM on boot -- can't enable with systemctl

#1 Post by aselker »

In the process of switching hardware and configuring things, I disabled GDM on boot via

Code: Select all

systemctl disable gdm
Now I want to re-enable it, but I can't.

Code: Select all

systemctl enable gdm
The unit files have no installation config (WantedBy, RequiredBy, Also, Alias
settings in the [Install] section, and DefaultInstance for template units).
This means they are not meant to be enabled using systemctl.
Possible reasons for having this kind of units are:
1) A unit may be statically enabled by being symlinked from another unit's
   .wants/ or .requires/ directory.
2) A unit's purpose may be to act as a helper for some other unit which has
   a requirement dependency on it.
3) A unit may be started when needed via activation (socket, path, timer,
   D-Bus, udev, scripted systemctl call, ...).
4) In case of template units, the unit is meant to be enabled with some
   instance name specified.
One forum post (I lost it, sorry...) suggested to make the symlink manually:

Code: Select all

sudo ln -s /lib/systemd/system/gdm.service /etc/systemd/system/display-manager.service
But that didn't help. I can still start it manually, via

Code: Select all

systemctl start gdm
, but this means entering my passphrase three times every boot (once to login, once for sudo, once to login to GDM).

Any ideas? Thank you!

EDIT: Solved with

Code: Select all

systemctl set-default graphical.target
. Thanks, Head_on_a_Stick!
Last edited by aselker on 2018-06-09 23:29, edited 1 time in total.

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 132 times

Re: Starting GDM on boot -- can't enable with systemctl

#2 Post by Head_on_a_Stick »

Please post the full output of

Code: Select all

ls -lR /etc/systemd/system
For future reference, to disable the display manager use

Code: Select all

# systemctl set-default multi-user.target
and to re-enable it again use

Code: Select all

# systemctl set-default graphical.target
deadbang

User avatar
debiman
Posts: 3063
Joined: 2013-03-12 07:18

Re: Starting GDM on boot -- can't enable with systemctl

#3 Post by debiman »

aselker wrote:and configuring things
could have sth to do with it?
maybe you can retrace your steps and find out what "things" might have influenced gdm or systemd?

have you tried reinstalling gdm?

aselker
Posts: 8
Joined: 2018-06-07 04:03

Re: Starting GDM on boot -- can't enable with systemctl

#4 Post by aselker »

Here's the output of ls -lR /etc/systemd/system.
https://paste.debian.net/1028598/

I don't think any of my configuration would have messed this up -- it was about filesystem mounting and graphics drivers.

I've tried reinstalling gdm3, and the gnome package.

User avatar
debiman
Posts: 3063
Joined: 2013-03-12 07:18

Re: Starting GDM on boot -- can't enable with systemctl

#5 Post by debiman »

god, there's some cruft in there. snaps... and why sshd???
and all those vbox services? i mean i use virtualbox, but i have nothing in /etc/systemd...

Wheelerof4te
Posts: 1454
Joined: 2015-08-30 20:14

Re: Starting GDM on boot -- can't enable with systemctl

#6 Post by Wheelerof4te »

aselker wrote:I don't think any of my configuration would have messed this up -- it was about filesystem mounting and graphics drivers.
Well...I do :mrgreen:
What did you do? Messing with drivers is not really recommended, unless you need to fix something, and you know what to look for. H_o_a_S's advice should help, if it doesn't, reinstall is your best option.
there's some cruft in there. snaps.
Snaps are cancer :D

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 132 times

Re: Starting GDM on boot -- can't enable with systemctl

#7 Post by Head_on_a_Stick »

aselker wrote:Here's the output of ls -lR /etc/systemd/system.
https://paste.debian.net/1028598/
It's a long shot but try

Code: Select all

# ln -sf /lib/systemd/system/gdm.service /etc/systemd/system/display-manager.service
And of course

Code: Select all

# aptitude reinstall gdm3
deadbang

aselker
Posts: 8
Joined: 2018-06-07 04:03

Re: Starting GDM on boot -- can't enable with systemctl

#8 Post by aselker »

Solved! I ran

Code: Select all

systemctl set-default graphical.target
and that fixed it. Thanks!

User avatar
debiman
Posts: 3063
Joined: 2013-03-12 07:18

Re: [Solved] Starting GDM on boot -- can't enable with syste

#9 Post by debiman »

^ which was mentioned in post #2 already.

Post Reply