A user reports that a Ubuntu Linux workstation boots to a command-line prompt instead of the graphical desktop after a recent package update. The technician wants to check which systemd target is currently active and switch to the graphical environment without rebooting. Which sequence of commands should the technician use?
Listing target units shows which targets are active, revealing whether the system is in multi-user.target rather than graphical.target. Isolating graphical.target then starts the display manager and desktop environment immediately in the running session, restoring the GUI without a reboot. The technician can subsequently set the default target if the change should persist.
Why this answer
Listing active targets identifies the current systemd state, and isolating graphical.target transitions the running system into the graphical environment right away. This satisfies the requirement to switch without rebooting, and the default target can be corrected separately if the change needs to survive a restart.
Exam trap
The trap here is confusing the persistent default target with the currently active target, where only isolate changes the running state immediately.