Escalating user privilege with sudo

In this recipe we will learn how to provide nominated users or groups the ability to execute a variety of commands with elevated privileges.

In a previous recipe we discovered how to create an administrative user that enables them to invoke the su command. Given that this provides full access to root user functionalities, this may suit your needs, but for those who want a greater degree of flexibility, a solid audit trail, and the ability to provide a limited array of administrative capabilities to a select number of trusted users, you have come to the right place. It is the purpose of this recipe to show you how to activate and configure the sudo (or superuser do) command.

Getting ready

To complete this recipe ...

Get CentOS 6 Linux Server Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.