This question already has an answer here:

How to I achieve a GUI restart in ubuntu 18.04 using Gnome on the standard X Windows Server.

Seems like the old question doesn't apply anymore.

marked as duplicate by muru command-line Aug 1 '18 at 5:59

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • I updated the answer there. – muru Aug 1 '18 at 5:59