Switch between GUI and CUI on CentOS6.

less than 1 minute read

operation

  • For CUI, execute the following command.
  • For GUI (GNOME Desktop), start “Application » Terminal” and execute it.

Command (for CUI)

#Switch to privileged user
su -
#Check the execution mode of the current OS. (3:CUI, 5:GUI)
runlevel
# CUI/Switch GUI. (3:CUI, 5:GUI)
telinit 5
#Reconfirm the execution mode of the current OS.
runlevel
#Return to original user
exit

Additional investigation

Details of the current OS execution mode (runlevel)

Switching in CentOS 7

  • [Management of CentOS 7 by systemd Think IT](https://thinkit.co.jp/story/2014/12/11/5388)

reference

  • [telinit command Linux command](https://www.linuxmaster.jp/linux_skill/2010/06/133telinit.html)

Remarks

This article is a migration article from the blog “Technical Notes for Chores Engineers”. The previous blog will be deleted.