Modulo7 Tese

Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

T E C N O L Ó G IC O D E E S T U D IO S S U P E R I O R E S D E E C A T E P E C

IN GENIERÍA INFORMÁTICA
ASIGNATURA: SISTEMAS OPERATIVOS II SEMESTRE: QUINTO
PRÁCTICA: Using Basic File Permissions
UNIX Essentials Featuring the Solaris Operating System
M. en C. Claudia Morán Sánchez

Objectives: View file and directory permissions, determine file or directory access, change the permissions and modify the default
permissions.

Tasks
To view permissions on files and change permissions, complete the following steps:
1. Perform the following commands in your home directory.
#mkdir perm
#cd /etc
#ls –l group motd shadow vfstab
#cp group motd shadow vfstab /perm
When trying to copy the shadow file, the error message cp: cannot open shadow: Permission denied appears. Why?
____________________________________________________________________________________________________________

#ls –l /perm
#cd
#cp –r /etc/skel perm

2. Change to the perm directory, and list the contents of the directory
#cd perm
#ls –l

Fill in the permission set for each file in table, and write the three-digit octal number that represents the combined set of
permissions.

Permissions
File or directory Octal Value
Owner Group Other
group
motd
skel
vfstab

3. Create a new file and a new directory


a. What are the default permissions given to the new file?

b. What are the default permissions give to the new directory?

_____________________________________________________________________________________________________

4. Distinguish between the symbolic mode and the octal mode

5. Using the symbolic mode, add write permission for the group to the motd file

6. Using the octal mode, change the permissions on the motd file to –rwxr-----

7. Using the octal mode, add write permission for other on the file named group.
8. Identify the GID and UID for the motd file. Which command did you use?

9. Create a new file called memo in your dir4 directory.

10. Remove the read permission for the owner from the memo file in the dir4 directory. Use either the symbolic mode or the octal
mode.

a. What happens when you try to use the cat command to view the memo file?

b. What happens when you try to copy the memo file?

11. What is the function of the umask utility? What is the default umask that exists on your system?

12. Change the umask to 027. Which command did you perform?

13. Create a new file and a new directory. Record the access permissions. Which command did you perform?

14. Change the umask back to 022

15. Create a new file test3file and a new directory test3dir

16. Record the access permissions.

test3file
test3dir

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy