Disabling SELinux is not advised.
Only turn off SELinux if your regulatory framework permits you to omit some measures of security reporting and enforcement.
If SELinux is later turned on, files made while disabled will not have the proper labels.
If you decide to turn SELinux back on, you'll need to rename all of your files. It takes a long time to complete this task.
Temporarily switching SELinux to permissive mode can help with troubleshooting issues. Policies for SELinux will remain active.
Even though access attempts that do not comply with the policies will be logged, they will not be denied.
CentOS 9 / AlmaLinux 9
Install the grubby package if not already installed.
# dnf install grubby
# grubby --update-kernel ALL --args selinux=0
Reboot server.
# reboot
# grubby --update-kernel ALL --remove-args selinux
CentOS 6, 8, 7 / AlmaLinux 8
Edit the /etc/selinux/config file and change SELINUX=enforcing to SELINUX=disabled and then reboot server.
# reboot
# yum install grubby
# grubby --update-kernel ALL --args selinux=0
Reboot the server as follows.
# reboot