0% found this document useful (0 votes)
13 views7 pages

Linux Module2 L2

This document outlines an assignment on Linux fundamentals, specifically focusing on creating files and directories as a root user and changing ownership to a new user. It provides step-by-step instructions for logging into an AWS EC2 Ubuntu Linux VM, creating a new user, and managing file permissions. The assignment was submitted by Wigglesworth on March 22, 2025, with a resubmission date to be determined.

Uploaded by

David Singham
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views7 pages

Linux Module2 L2

This document outlines an assignment on Linux fundamentals, specifically focusing on creating files and directories as a root user and changing ownership to a new user. It provides step-by-step instructions for logging into an AWS EC2 Ubuntu Linux VM, creating a new user, and managing file permissions. The assignment was submitted by Wigglesworth on March 22, 2025, with a resubmission date to be determined.

Uploaded by

David Singham
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

Module – 2

LINUX FUNDAMENTALS
ASSIGNMENT
Submitted by: Wigglesworth
Date of Submission: 22-03-2025
Date of Resubmission: TBD

2. L2 - As a Linux root user Create Files/Directory in the same


Instance and change the ownership to a new user
Step:1: Login to AWS Account and go into EC2 Webpage. We have
created an EC2 Ubuntu Linux VM.
Access the Linux VM via Putty Tool.

Step:2:
Switch to super user using sudo su command.
Create a new user called newuser and also provide a password.

Step:3:
As a root user create a new directory under /opt directory and create a file under
the newly created directory.

Step:4:
Using ls –ld and ls –l command we are able to see that the directory and the file
in the directory has been created by the root user and the group is also root

Now using chown -R <user_name> <directory> command , we change the


owner from root user to the newly created user newuser.
Note : In the above command , we use -R to change the permission of the files
And the sub-directories inside the mentioned directory.

Step:5:

Now exit as root user and switch to the newly created user newuser using
su - <user_name> command.

Verify that newuser is the owner of the file and the directory.

You might also like