Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
CentOS 7 Linux Server Cookbook, Second Edition

You're reading from   CentOS 7 Linux Server Cookbook, Second Edition Get your CentOS server up and running with this collection of more than 80 recipes created for CentOS 7 - essential for Linux fans!

Arrow left icon
Product type Paperback
Published in Jan 2016
Publisher
ISBN-13 9781785887284
Length 326 pages
Edition 2nd Edition
Tools
Arrow right icon
Author (1):
Arrow left icon
Jonathan Hobson Jonathan Hobson
Author Profile Icon Jonathan Hobson
Jonathan Hobson
Arrow right icon
View More author details
Toc

Table of Contents (17) Chapters Close

Preface 1. Installing CentOS FREE CHAPTER 2. Configuring the System 3. Managing the System 4. Managing Packages with YUM 5. Administering the Filesystem 6. Providing Security 7. Building a Network 8. Working with FTP 9. Working with Domains 10. Working with Databases 11. Providing Mail Services 12. Providing Web Services 13. Operating System-Level Virtualization 14. Working with SELinux 15. Monitoring IT Infrastructure Index

Troubleshooting SELinux

In this recipe, you will learn how to troubleshoot SELinux policies, which is most often needed when access to some SELinux objects has been denied and you need to find out the reasons for it. In this recipe, we will show you how to work with the sealert tool, which will create human-readable and understandable error messages to work with.

Getting ready

To complete this recipe, you will require a working installation of the CentOS 7 operating system with root privileges. It is assumed that you are working through this chapter recipe by recipe, so by now you should have installed the SELinux tools and applied the Working with policies recipe in this chapter, as we will produce some SELinux denial events in order to show you how to use the log file tools.

How to do it...

  1. To begin, login as root and provoke a SELinux denial event:
    touch /var/www/html/test2.html
    semanage fcontext -a -t user_tmp_t /var/www/html/test2.html
    restorecon -v /var/www/html/test2.html
    curl http:/...
lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image