Changes

Jump to: navigation, search

OPS235 Lab 4 - CentOS7

672 bytes added, 04:00, 29 April 2015
no edit summary
#* What is the default group name of a new user?
#* Add a new group named <b><code><span style="color:#3366CC;font-size:1.2em;">ops235</span></code></b> with a GID of <b><code><span style="color:#3366CC;font-size:1.2em;">600</span></code></b>.
#* You are angry The management at your organization have concerns regarding some irresponsible users on your system.#** Add a new group named idiots'''investigation'''.#** Look at '''/etc/group ''' and note the GID of idiotsgroup called '''investigation'''.#** What GID is given to a new group if if you do not specify it?#** Your anger In the file, add those users to the end of the concerned group (separate each user-name with a comma).#** Those individuals have explained their actions to management and the crisis has subsidedbeen resolved. Delete the <b><code><span style="color:#3366CC;font-size:1.2em;">idiots</span></code></b> '''investigation''' group.#** Look at '''/etc/group ''' again and note the change.
'''Answer the Part 3 observations / questions in your lab log book.'''
== Part 4: Deleting / Modifying Users ==
#Perform this part Remain in your '''centos1 ''' VMfor this section.# Read the man page for the <b><code><span style="color:#3366CC;font-size:1.2em;">'''userdel</span></code></b> ''' command. Note which option automatically removes the users home directory when that user is deleted. # Delete the user '''ops235_1 ''' using the command <b><code><span style="color:#3366CC;font-size:1.2em;">userdel ops235_1</span></code></b># Delete the user ops235_2 '''ops235'''_2 using the same command with the option which removes the home directory of the user.
# Check the contents of the /home directory. What do you notice?
# Check the contents of the <b><code><span style="color:#3366CC;font-size:1.2em;">/etc/group</span></code></b> file. What do you notice?
# Read the man page for the usermod command. Note which options change the user's full name, primary group, supplementary groups, and shell.
# Create a new user account called '''noobie''' for the employee: '''Really Green''' . Assign a password for that newly created user.# Management has indicated that this employee be on on probation for 3 months. Use the '''usermod''' command to set the account for noobie to expire in 3 months from this day as part of the security policy of this organization.
# Add each of your new users to the group ops235 (in other words, add ops235 to each user as a supplementary group).
# Examine <b><code><span style="color:#3366CC;font-size:1.2em;">/etc/group</span></code></b>. What has changed?
# Use the '''usermod ''' command to associate each change the full name of your pod matesthe user account '''noobie''' from '''Really Green''' full name to their user name'''Outstanding Employee'''. With each change, examine their entries Examine the result of running that command in the <b><code><span style="color:#3366CC;font-size:1.2em;">/etc/passwd</span></code></b> file. What has changed?# Use the '''usermod''' command to extend the use of their account for 5 years as of today.
# Be sure to record your observations in your lab notes.
13,420
edits

Navigation menu