环境:
操作步骤:


再按 "ctrl+x" 使用修改的启动命令运行


mount -o remount,rw /sysroot
chroot /sysroot
passwd
touch /.autorelabel # 重点
exit
reboot
/.autorelabel
生成此文件,表示要SELinux重新标记其系统文件
一般是首次为SELinux标记文件系统或切换其设置策略时使用
对于各种应用服务,如果之前SELinux的状态不是启用时安装的,在启用了SELinux时,可能会导致无法启动的问题,这就需要此文件来重新标记