[root@docker ~]# yum grouplistLoaded plugins: fastestmirror, langpacks, product-id, search-disabled-repos, subscription-managerThis system is not registered with an entitlement server. You can use subscription-manager to register.There is no installed groups file.Maybe run: yum groups mark convert (see man yum)Loading mirror speeds from cached hostfile* base: mirrors.aliyun.com* extras: mirrors.aliyun.com* updates: mirrors.aliyun.comAvailable Environment Groups:Minimal InstallCompute NodeInfrastructure ServerFile and Print ServerBasic Web ServerVirtualization HostServer with GUIGNOME DesktopKDE Plasma WorkspacesDevelopment and Creative WorkstationAvailable Groups:Compatibility LibrariesConsole Internet ToolsDevelopment ToolsGraphical Administration ToolsLegacy UNIX CompatibilityScientific SupportSecurity ToolsSmart Card SupportSystem Administration ToolsSystem ManagementDone[root@docker ~]#
yum -y groupinstall "Server with GUI"
查看默认启动和设置启动级别
[root@docker ~]# systemctl get-defaultmulti-user.target[root@docker ~]# cat /etc/inittab# inittab is no longer used when using systemd.## ADDING CONFIGURATION HERE WILL HAVE NO EFFECT ON YOUR SYSTEM.## Ctrl-Alt-Delete is handled by /usr/lib/systemd/system/ctrl-alt-del.target## systemd uses 'targets' instead of runlevels. By default, there are two main targets:## multi-user.target: analogous to runlevel 3# graphical.target: analogous to runlevel 5## To view current default target, run:# systemctl get-default## To set a default target, run:# systemctl set-default TARGET.target#[root@docker ~]#
启动图形界面
startx
