Reference no: EM133218815
Implement system security and access control in Linux operating system. You could also describe how the processes are managed after you have implemented your script.
Using Ubuntu OS, write and implement ONE (1) bash shell script (only one script should be written for whole Question 3). You are to use the root account to execute the script. The script will implement a modified version of Shortest Process Next (SPN) scheduling algorithm. The bash shell script should have the following specifications:
Question 1. The script will prompt the user to enter a text file (.txt) in the current folder (Note: each line of the text file consists of arrival time and service time of a process). As an example, if there are six processes, and the processes arrival time are 0, 1, 4, 5, 6, 9, and the service time are 3, 5, 5, 1, 3, 1, then the text file will have 6 lines, and the content of the text file will be as follow (use colon as delimiter between arrival time and service time):
0:3
1:5
4:5
5:1
6:3
9:1
Question 2. It will check whether the text file exist in the current folder, and if the text file does NOT exist, it will ask the user to re-enter the text file (it will keep asking until the user enter a text file that exists).
Question 3. It will read in the values from the text file and display the number of processes on the screen.