G53OPS - Operating Systems

This course is run at the The University of Nottingham within the School of Computer Science & IT. The course is run by Graham Kendall (EMAIL : gxk@cs.nott.ac.uk)


Answers and Further Reading

Question 1

The main problem with variable length records is that you have to have some way of knowing where one record ends and another starts. There are two common methods of doing this. You can either have a separator between each field. This obviously has to be a character that does not appear elsewhere in the file.

Alternatively, you can have a counter before each field that defines how long the field is.

Question 2

You could choose an allowable character (let's say '\', we are assuming this is an allowed character within filenames) and then you create filenames that are split using this character. For example 'account\week1', accounts\week2', 'project\intro', 'project\conclusions' and 'project\programs\test'.

This gives the illusion of a directory structure and commands such as DIR, COPY etc. can be effectively used using wildcards such as '*' and '?'.

Question 3

The dot entry refers to the current directory. The dotdot directory refers to the parent directory.

Examples of use (using MS-DOS). Assume the current working directory is 'C:\WINDOWS\SYSTEM32' at the start of each example.

· If you type 'CD .' the current working directory will stay the same as you are effectively issuing a 'CD C:\WINDOWS\SYSTEM32' command.
· If you type 'CD ..' then the current working directory will become 'C:\WINDOWS'. That is the parent of C:\WINDOWS\SYSTEM32.
· If you typed 'DIR ..\..\TEMP' this will display the contents of the temp directory, which is a sub-directory of the root directory. The effect of the two dotdot's was to take us back to the root. If we had typed 'DIR ..\TEMP' this would display the contents of the TEMP directory within WINDOWS (assuming one exists).

Further Reading

Quotas (Tanenbaum, 1992), pages 172 - 173.

Bad Block Management (Tanenbaum, 1992), pages 174 - 1174.

File System Consistency (Tanenbaum, 1992), pages 175 - 177.

File System Performance (Tanenbaum, 1992), pages 178 - 180.

References

· Mullender, S.J. and Tanenbaum, A.S. 1984. Immediate Files. Software - Practice and Experience, Vol. 14, pp 365-368
· Tanenbaum, A.S. 1992. Modern Operating Systems. Prentice Hall.

Last Page Back to Main Index Next Page


 


 Last Updated : 23/01/2002