CertGrid CertGrid
Hands-on Lab·Red Hat Certified System Administrator

Privileged Access with sudo

One objective, asked constantly. Everything here is done with files in `/etc/sudoers.d` rather than by editing `/etc/sudoers`, and the guide ends by breaking a rule on purpose - which turns out not to fail the way anyone expects.

Users and Groups Guide 20 of 67 Intermediate

Written against the versions above. Files in `/etc/sudoers.d` must be mode **0440** and owned by root. sudo ignores a world-writable file, and - captured below - warns about it rather than failing, so the symptom is a rule that silently does not apply.

Every command on this page runs on RHCSA-A01.
Server NameIP AddressOSRolesCPURAMHDD
RHCSA-A01192.168.0.31RHEL 10.0 (Coughlan)Practice node (graded) - spare /dev/sda2 Core4 GB50 GB + 15 GB

Before you start

  1. How sudo is granted on Red Hat

  2. A user with no privileges

  3. Granting access with a drop-in file

  4. Granting only specific commands

  5. A typo does not fail safe

  6. Group rules, and file permissions that void them

Official sources