Week3.3 Exercises (Groups)
Week3.3 Exercises (Groups)
1. Create two new user accounts (rocky and bullwinkle and make sure they have home directories.
2. Create two new groups, friends and bosses (with a GID of 490). Look at/etc/group. See what GID
was given to each new group. Did either fail to create?
3. Add rocky to both new groups. Add bullwinkle to group friends. Look in/etc/groupto see how it
changed.
4. Login as rocky. Create a directory called somedir and set the group ownership to bosses. (Using chgrp
which will be discussed in the next session.) (You will probably need to add execute privileges for all on
rocky’s home directory.)
5. Login as bullwinkle and try to create a file in/home/rocky/somedir calleds omefile using the touch
command.Can you do this? No, because of the group ownership and the chmod a+x on the directory.
6. Add bullwinklet o the bossesgroup and try again. Note you will have to log out and log back in again
for the newgroup membership to be effective.