Ask a question from expert

Ask now

Assignment | account management

Create a new VM, install Fedora OS, perform post installation tasks, download and unpack a zipped file, create a virtual hard disk, create partitions, format partitions, configure Linux VM, run a checking script, and submit an information file for grading.

18 Pages4010 Words24 Views

Added on  2022-10-09

Assignment | account management

Create a new VM, install Fedora OS, perform post installation tasks, download and unpack a zipped file, create a virtual hard disk, create partitions, format partitions, configure Linux VM, run a checking script, and submit an information file for grading.

   Added on 2022-10-09

BookmarkShareRelated Documents
SYST28296 Tutorial 3
In this tutorial, you will learn how to manage user accounts and
groups for your Kubuntu Linux VM. First, you will learn about the
/etc/passwd file. Then you will learn how to efficiently create user
accounts and have files automatically created on the behalf of the
user upon user account creation.
You will also perform additional user account management such as
removing user accounts, modifying user accounts and resetting user account passwords.
You will also learn how to create and manage temporary user accounts that will be locked after
a predetermined set date. You will also use shell scripts that can be used to automate the
creation of multiple user accounts.
Finally, you will be learning how to manage groups contained in the /etc/group file in order to
allow users to share resources such as files and directories for collaborative development
projects in your Kubuntu Linux VM. You will learn how to add, remove and append user
accounts to an existing group. You will also set permissions using the chmod command.
You can refer to the SUBMITTING TUTORIAL 3 section at the end of this document for a
check-list of the required files to submit for marks.
The /etc/passwd File
This is a database file that contains all usernames on your Linux system as well as other
important information related to each user account.
This file is accessed by root to verify and load user
account defaults when the user logs into their
computer system. The file separates user accounts
(system vs regular users) by account number.
Throughout this tutorial, you will be asked some
questions relating to this week’s notes. These
questions will appear as a green coloured box,
where you will be required to type the answer to the
questions within the area provided. You should save
your MS Word document frequently.
In the right-hand textbox, list the fields that are
contained in the /etc/passwd file in order of
Usually, regular users have uid’s (user account IDs)
1000 and above.
Fields Contained in /etc/passwd:
1. Root: Account username.
2. x: Placeholder for password information.
3. 0: User ID
4. 0: Group ID
5. root: Comment field
6. /root: Home directory.
7. /bin/bash: User shell.
Assignment | account management_1
SYST28296 Tutorial 3
Perform the following Steps:
1. Start up your Kubuntu-VM1 virtual machine and log-in using your regular user and password.
2. Open your Bash Shell and switch to the root account.
Although the sysadmin (root) account can directly edit the /etc/passwd file, it is NOT recommended
that you edit that file since it could create errors and/or corrupt that important database file.
Instead, there are sysadmin commands that can be issued that will consistently and safely modify
the /etc/passwd file.
3. Issue the command: users
How many unique user accounts do you see?
1 users [malhar]
4. Issue the following Linux command: useradd test1
List the contents of the /home directory, what do you see? Is there a folder for test1?
No folder for test1
5. Issue the following Linux command: useradd -m test2
List the contents of just the /home directory, what do you notice? What does this indicate
regarding the use of the -m option with this command?
-m option facilitates the creation of a home directory for a new user
6. Issue a command to view the contents of the /etc/passwd file to view the records for
those newly-created accounts. What do you notice about their account numbers?
details of users test1 and test2 exist in the file their user id are
7. Issue the following command to add a third account: useradd -m -u 1005 test3
View the contents of the /etc/passwd file. What do you notice about the user ID for this
newly-created account? test3 created and details added to file with user id 1005
You have created new accounts, but you haven’t set a password for those users to be able
to login. Although there is an option with the useradd command to set the password, you
Assignment | account management_2
SYST28296 Tutorial 3
can also set the password after the account has been created using the passwd command.
8. Issue the following commands to set an appropriate password for the following accounts
(select an appropriate password to assign and write it down – use the same one for all):
passwd test1
passwd test2
passwd test3
9. Test-out logging into those new accounts by issuing the following commands:
login test1
What do you notice when you logged into this account?
What is your default home directory?
Default directory is /
10. Issue the command whoami to verify which account you are currently located.
Assignment | account management_3
SYST28296 Tutorial 3
11. When finished verifying that you can login to that account, return to your root account
by issuing the following command: exit
12. Perform the same operations in steps 9 to 11, but for the user account test2, and make
certain you have switched back to your root account afterwards.
13. Issue the following Linux commands to remove the user called test2: userdel test2
14. Confirm that the test2 account was removed from the /etc/passwd file.
User test2 was removed
15. List the contents of your /home directory. Was the home directory for user2 removed?
If not, why?

Home directory not removed; the folder may have not been empty
therefore preventing complete deletion
16. Issue the following command to remove the test2’s home directory: rm -rf /home/test2
Verify that the directory has been removed. What is the purpose of the -rf option?
The directory was removed with –r option; this option recursively removes
files, while the -f option forces the deletion.
Assignment | account management_4

End of preview

Want to access all the pages? Upload your documents or become a member.

Related Documents

Basic Linux Security | Assignment

Computer Security System Investigation

Server Administration: Linux and Server

Linux Assignment 7

Server Administration: Automated Account Management, File System Design, ZFS on Linux, File System Management with Scripts