I've been an Ubuntu user for a while, and at work we have many Ubuntu VM servers, all of which run
Ubuntu 14.04 LTS to deploy our web applications, databases, and other tools.
I'm currently studying
Ubuntu 16.04 LTS, desktop and server, to be able to upgrade our production servers in the near future without causing problems.
Since Ubuntu 15.04,
upstart have been replaced by
Systemd, so I'm studying Systemd too.
I noticed that my development computer running Ubuntu 16.04 Desktop edition has
graphical.target as the default systemd target, which is logical.
But then I noticed that the testing server running Ubuntu 16.04 Server edition also uses
graphical.target as the default systemd target.
$ systemctl get-default graphical.target
So I'm confused. The server doesn't have any graphical layer, so how it is that the default target is
Like Rinzwind suggested in the comments, I looked at the target to see whether it's active or not...
and the response is YES:
admin@server1604:~$ systemctl get-default graphical.target admin@server1604:~$ systemctl status graphical.target ● graphical.target - Graphical Interface Loaded: loaded (/lib/systemd/system/graphical.target; static; vendor preset: enabled) Active: active since jeu. 2016-10-13 16:03:18 CEST; 46min ago Docs: man:systemd.special(7) oct. 13 16:03:18 fdea systemd: Reached target Graphical Interface.
So I'm a bit more confused.
The Mark Stosberg's answer point the fact that
display-manager.service is part of the dependency tree of the
graphical.target on its own 16.04 server, and he adds that no display manager is installed or running on its machine. I looked at that too, and indeed, on my server this dependency is there:
admin@server1604:~$ systemctl list-dependencies graphical.target graphical.target ● ├─accounts-daemon.service ● ├─apache2.service ● ├─apport.service ● ├─display-manager.service ...
And this target has a red circle on the left, where most of the other dependencies have a green one.
And this time the result is consistent:
firstname.lastname@example.org:~$ systemctl status display-manager.service ● display-manager.service Loaded: not-found (Reason: No such file or directory) Active: inactive (dead)
But here is an other strange thing: on my desktop edition, the
display-manager.service is not a dependency of
email@example.com:~ $ systemctl list-dependencies graphical.target | grep display firstname.lastname@example.org:~ $
But I even found an alternative because I run
lightdm replacing the default window manager:
email@example.com:~ $ systemctl list-dependencies graphical.target | grep lightdm ● ├─lightdm.service