Ravindra BagaleCourses & study guides मराठी Track your progress

Ravi Sir's Cyber Security Cards › Revision Cards

Everyday Management Commands and SELinux Basics

Everyday Management Commands and SELinux Basics Daily commands to test, reload and restart a web server. SELinux is a Linux security layer that limits what each program can touch. reload re-reads the config without dropping visitors. restart stops and starts. Safe habit: sudo nginx -t && sudo system

Everyday Management Commands and SELinux Basics Daily commands to test, reload and restart a web server. SELinux is a Linux security layer that limits what each program can touch. reload re-reads the config without dropping visitors. restart stops and starts. Safe habit: sudo nginx -t && sudo system
Everyday Management Commands and SELinux Basics · Download PNG
Read card text

What this card says

What it is

Daily commands to test, reload and restart a web server.

SELinux is a Linux security layer that limits what each program can touch.

Restart vs reload

reload re-reads the config without dropping visitors. restart stops and starts.

Safe habit: sudo nginx -t && sudo systemctl reload nginx. If the test fails, no reload happens.

Why it matters for security

Turning SELinux off to “fix” an error removes a real defence.

Fix the file label instead.

TaskNginxApache (AL2023/CentOS)
Test configsudo nginx -tsudo apachectl configtest
Reload (no downtime)sudo service nginx reloadsudo service httpd reload
Restartsudo service nginx restartsudo service httpd restart
Error logsudo tail -f /var/log/nginx/error.logsudo tail -f /var/log/httpd/error_log
Access log/var/log/nginx/access.log/var/log/httpd/access_log

Learn more in the lesson: 7.7 Everyday Management Commands and SELinux Basics

See all Ravi Sir's Cyber Security Cards