- Lab
-
Libraries: If you want this lab, consider one of these libraries.
- Cloud

Managing File Ownership and Permissions
In this hands-on lab, we will practice managing Linux file and directory ownership and permissions. Having a solid understanding of ownership and permissions is a fundamental skill for Linux systems administration.

Lab Info
Table of Contents
-
Challenge
Lock Bill's, Susan's, and Juan’s Accounts
- Run the following command:
for i in bill susan juan; do sudo passwd -l $i; done
-
Challenge
Create Accounts for Nancy, Greg, and Jeremy
- Run the following commands:
sudo useradd -m nancy
sudo useradd -m greg
sudo useradd -m jeremy
-
Challenge
Remove Bill as a User and Transfer Ownership of his Home Directory
- Remove the user
bill
.
sudo userdel bill
- Change the ownership of Bill's home directory (recursively) to the user
nancy
and the groupjason
.
sudo chown -R nancy:jason /home/bill
- Change the mode of the directory to grant read and execute permissions to the group.
sudo chmod g+rx /home/bill
- Remove the user
-
Challenge
Remove Susan as a User and Transfer Ownership of her Home Directory
- Remove the user
susan
.
sudo userdel susan
- Change the ownership of Susan's home directory (recursively) to the user
greg
and the groupjason
.
sudo chown -R greg:jason /home/susan
- Change the mode of the directory to grant read and execute permissions to the group.
sudo chmod g+rx /home/susan
- Remove the user
-
Challenge
Remove Juan as a User and Transfer Ownership of His Home Directory
- Remove the user
juan
.
sudo userdel juan
- Change the ownership of Juan's home directory (recursively) to the user
jeremy
and the groupsally
.
sudo chown -R jeremy:sally /home/juan
- Change the mode of the directory to grant read and execute permissions to the group.
sudo chmod g+rx /home/juan
- Remove the user
About the author
Real skill practice before real-world application
Hands-on Labs are real environments created by industry experts to help you learn. These environments help you gain knowledge and experience, practice without compromising your system, test without risk, destroy without fear, and let you learn from your mistakes. Hands-on Labs: practice your skills before delivering in the real world.
Learn by doing
Engage hands-on with the tools and technologies you’re learning. You pick the skill, we provide the credentials and environment.
Follow your guide
All labs have detailed instructions and objectives, guiding you through the learning process and ensuring you understand every step.
Turn time into mastery
On average, you retain 75% more of your learning if you take time to practice. Hands-on labs set you up for success to make those skills stick.