Investigate and Resolve SELinux Issues Flashcards

1
Q

What command is used to view contents of the /var/log/messages file?

A

less /var/log/messages

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What command verifies the SELinux context for the directory from where the httpd service serves the content by default, /var/www/html?

A

ls -ldZ /var/www/html

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What command is used to search the audit.log for messages and based on time?

A

ausearch -m AVC -ts today

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What command is used to resolve the context issue with an Apache server directory, and all files underneath?

A

semanage fcontext -a -t httpd_sys_content_t ‘/custom(/.*)?’

restorecon -Rv /custom

How well did you know this?
1
Not at all
2
3
4
5
Perfectly