Assignment 2
Assignment 2
Assignment 2
KELAS: SSK2
a. Fill in the blanks with correct filename extension for below file type:
b. Give four file operations in file management system and define the definition on each
operations.
1. Read – Reading from a file.
2. Write – Writing or rewriting the file.
3. Execute – Loading the file and after loading the execution process starts.
4. Delete – Deleting the file which is of no use and using its space for other data.
The file ‘mail’ in the following figure starts from the block 19 with length =
6 blocks. Therefore, it occupies 19, 20, 21, 22, 23, 24 blocks.
ii. Linked List Allocation.
- In this scheme, each file is a linked list of disk blocks which don’t have to
be contiguous. The disk blocks can be scattered anywhere on the disk.
The directory entry contains a pointer to the starting and the ending file
block. Each block contains a pointer to the next block occupied by the file.
The file ‘jeep’ in the following image shows how the blocks are randomly
distributed. The last block (25) contains -1 indicating a null pointer and
does not point to any other block.
QUESTION 2
a. Explain what the objective of file protection?
- In computer systems, a lot of user’s information is stored, the objective of
the operating system is to keep safe the data of the user from the
improper access to the system. Such as hacking, and other cyber attacks
or even from physical damage to the storage device.
b. There are 6 types of access protection file in operating system. Explain the following
type of access protection file:
i. Read – Allows or denies viewing of the attributes of a file or folder, such as
read-only and hidden.
ii. Write – Allows or denies changing of the attributes of a file or folder, such as
read-only or hidden
iii. Execute – Allows or denies running program files. (applies to files only)
iv. Append – Allows or denies making changes to the end of the file but not
changing, deleting, or overwriting existing data. (applies to files only)
v. Delete – Allows or denies deleting subfolders and files, even if the Delete
permission has not been granted on the subfolder or file. (applies to folders
and files)
vi. Updating – Updates files so it always remains up to date.
Type Description
- Cannot do anything to file
Rwx Can read, write and execute file
Rw- Can read and write file
r-- Can only read file
e. Do capture screen as below instruction in file properties on your computer:
i. Show permission (administrator and everyone) for operating system.
g. Classify the following table into correct capability list for the following details:
1. File 1:
Ali can read, write and execute File 1.
Bala can only read File 1.
Carol can only read File 1.
David cannot do anything to File 1.
2. File 2:
Ali can only read File 2.
Bala can read, write and execute File 2.
Carol cannot do anything to File 2.
David can only read File 2.
3. File 3:
Ali can only read File 3.
Bala can only read File 3.
Carol can read, write and execute File 3.
David can only read File 3.
4. File 4:
Ali cannot do anything to File 4.
Bala can read, write and execute File 4.
Carol can read, write and execute File 4.
David can only read File 4.