% Format: latex
\errorcontextlines=99
% Turn off special handling of vertical bars by lgrind, so tabular
% works properly.
%|-

\documentclass[%
   a4paper,%
   %11pt%
   12pt%
   ]{article}

\usepackage{%
   %a4,%
   %vmargin,%
   geometry,%
   prog,%
   acro,%
   booktabs,%
   nbox,%
   varioref,%
   multicol,%
   multirow,%
   fancyhdr,%
   float,%
   %fullpage,%
   emlines2,%
   %xr,%
   %lastpage,%
   amssymb,%
   psfrag,%
   amsmath,%
   graphicx,%
   amstext,%
   hhline,%
   cols,%
   %tabularx,%
   key,%
   ifthen,%
   mdwlist,%
   calc,%
   fancybox,%
   verbatim,%
   moreverb,%
   nick%
}



\usepackage[nolineno,noindent]{lgrind}

% \usepackage{subfigure}[1995/03/06]

\usepackage[nooneline,hang,bf]{caption2}
\renewcommand{\captionfont}{\raggedright}

\usepackage[pdfpagemode=None,
pdfauthor={Nick Urbanik},
pdfstartview=FitH,
pdfpagemode=FitWidth,
pdfkeywords={Operating Systems, Systems Integration},
pdftitle={Final Examination, 11 June 2002, Operating Systems
  and Systems Integration},
pdfsubject={Operating Systems and Systems Integration}
]{hyperref}

\geometry{left = 30mm, top = 15mm, right = 30mm, bottom = 14mm,
  headheight = 19pt, headsep = 8mm, footskip = 11mm}

\newlength{\ttWid}
\settowidth{\ttWid}{\texttt{\small{}m}}
\newcommand*{\threespace}{\underline{\hspace*{3\ttWid}}}
\newcommand*{\twospace}{\underline{\hspace*{2\ttWid}}}

\newenvironment{explanation}%
{%
   \begin{list}{}%
   {%
      \setlength{\parskip}{0.8em plus .2em minus .2em}
      \rightmargin \leftmargin
      \topsep 0pt%
   }%
   \small\item[]%
}%
{\end{list}}

% p. 74 of LaTeX Companion:
\newcommand{\marginlabel}[1]
    {\mbox{}\marginpar{\raggedright\hspace{0pt}#1}}

\DeclareRobustCommand{\marksFont}[1]{{\small#1}}

\DeclareRobustCommand{\marks}[1]{%
   \ifthenelse{\equal{#1}{1} \or \equal{#1}{0.5}}%
   {\mbox{}\marginpar{\raggedright\hspace{0pt}{\marksFont{(#1 mark)}}}}%
   %{\marginpar{\small\textmedium{#1 mark}}}%
% else
   %{\marginpar{\small\textmedium{#1 marks}}}%
   {\mbox{}\marginpar{\raggedright\hspace{0pt}{\marksFont{(#1 marks)}}}}%
}

% Stolen from exam.dtx:
%@-
\makeatletter
%\providecommand\leftnote[1][-\baselineskip]{\@rlnote l{#1}}
%\providecommand\rightnote[1][-\baselineskip]{\@rlnote r{#1}}
%\providecommand\leftnote[1][-1.5\baslineskip]{\@rlnote l{#1}}
%\providecommand\rightnote[1][-1.5\baselineskip]{\@rlnote r{#1}}
\providecommand\leftnote[1][-0.75\baslineskip]{\@rlnote l{#1}}
\providecommand\rightnote[1][-0.75\baselineskip]{\@rlnote r{#1}}
%\providecommand\@rlnote[3]%
%{%
%   \noindent\vadjust%
%   {%
%      \vbox to\z@%
%      {%
%         \vskip#2\leftskip\z@skip\rightskip\z@skip\noindent
%         \if#1l%
%            \llap{#3\hskip\marginparsep}%
%         \else%
%            \hfill\rlap{\hskip\marginparsep#3}%
%         \fi%
%         \vss\vskip\z@skip%
%      }%
%   }%
%}

\providecommand\@rlnote[3]%
{%
   \noindent\vadjust%
   {%
      \vtop to\z@%
      {%
          \vskip-\baselineskip\leftskip\z@skip\rightskip\z@skip\noindent
          \if#1l%
             \llap{#3\hskip\marginparsep}%
          \else%
             \hfill\rlap{\hskip\marginparsep#3}%
          \fi%
          \vss\vskip\z@skip%
      }%
   }%
}

% Now try after looking at page 316 of the TeXbook:

%\def\strutdepth{\dp\strutbox}
%\providecommand\@rlnote[3]%
%{%
%   \noindent\vadjust%
%   {%
%      \vtop to\z@%
%      {%
%          \vskip#2\leftskip\z@skip\rightskip\z@skip\noindent
%          \if#1l%
%             \llap{#3\hskip\marginparsep}%
%          \else%
%             \hfill\rlap{\hskip\marginparsep#3}%
%          \fi%
%          \vss\vskip\z@skip%
%      }%
%   }%
%}

% This comes nowhere near working:

%\providecommand\@rlnote[3]%
%{%
%   \if#1l%
%       \llap{#3\hskip\marginparsep}%
%   \else%
%       \hfill\rlap{\hskip\marginparsep#3}%
%   \fi%
%}
\makeatother
%@+

%\DeclareRobustCommand{\marks}[1]{%
%   \ifthenelse{\equal{#1}{1}}%
%   {\mbox{}\rightnote{\raggedright\hspace{0pt}{\marksFont{#1 mark}}}}%
%% else
%   {\mbox{}\rightnote{\raggedright\hspace{0pt}{\marksFont{#1 marks}}}}%
%}

% Note that \topsep, \parsep, etc are set in size12.clo.
\newenvironment{question}{%
       \enumerate
%       \parskip 12pt plus 2pt minus 2pt%
%       \itemsep 15pt plus 7.5pt minus 3pt%
%       \topsep 30pt plus 12pt minus 12pt%
%       \parsep 12pt plus 2pt minus 2pt%
%       \partopsep 12pt plus 4pt minus 4pt\relax%
}{\endenumerate}

\newenvironment{subQuestion}{%
       \enumerate
%       \parskip 3pt plus 1pt minus 1pt%
%       \itemsep 5pt plus 2.5pt minus 1pt%
%       \topsep 7pt plus 2.5pt minus 1pt%
%       \parsep 3pt plus 1pt minus 1pt%
%       \partopsep 3pt plus 2pt minus 2pt\relax%
}{\endenumerate}

%@-
\makeatletter
\def\@listi{\leftmargin\leftmargini
       \partopsep 12pt plus 4pt minus 4pt%
       \parskip 12pt plus 2pt minus 2pt%
       \itemsep 15pt plus 7.5pt minus 3pt%
       \topsep 30pt plus 12pt minus 12pt%
       \parsep 12pt plus 2pt minus 2pt%
%            \parsep 5\p@  \@plus2.5\p@ \@minus\p@
%            \topsep 10\p@ \@plus4\p@   \@minus6\p@
%            \itemsep5\p@  \@plus2.5\p@ \@minus\p@%
}
\let\@listI\@listi
\@listi
\def\@listii {\leftmargin\leftmarginii
              \labelwidth\leftmarginii
              \advance\labelwidth-\labelsep
              \partopsep 3pt plus 2pt minus 2pt%
%              \topsep    5\p@   \@plus2.5\p@ \@minus\p@
              \topsep    2\p@   \@plus\p@ \@minus\p@
              \parsep    5\p@ \@plus2.5\p@    \@minus\p@
              \setlength{\parskip}{0.6em plus .2em minus .2em}
              \itemsep   \parsep}
\def\@listiii{\leftmargin\leftmarginiii
              \labelwidth\leftmarginiii
              \advance\labelwidth-\labelsep
              \topsep    2.5\p@\@plus\p@\@minus\p@
              \parsep    \z@
              \partopsep \p@ \@plus\z@ \@minus\p@
              \itemsep   \topsep}
\def\@listiv {\leftmargin\leftmarginiv
              \labelwidth\leftmarginiv
              \advance\labelwidth-\labelsep}
\makeatother
%@-

\renewcommand{\labelenumi}{\textbf{Question \theenumi.}}

% The following was the result of a major grepping and source viewing
% session.  I found the most helpful source to be ltxref.dtx, part of
% LaTeX2e.  The packages caption.dtx and caption2.dtx didn't help
% much.

% This works rather well; it could now be put into a package.
% Perhaps it would be appropriate to make it part of \caption, so that
% there is no special word required for each float type.

%@-
\makeatletter
\newcommand*{\newFigTag}[1]{%
       \def\fnum@figure{Figure #1}%
       \def\@currentlabel{#1}%
       \def\refstepcounter##1{}%
}
\newcommand*{\newTabTag}[1]{%
       \def\fnum@table{Table #1}%
       \def\@currentlabel{#1}%
       \def\refstepcounter##1{}%
}
%\newcommand{\newTabTag}[1]{%
%       \def\fnum@table{Table #1}%
%}
\newcommand*{\newProgTag}[1]{%
       \def\fnum@program{Program listing #1}%
%       \def\fnum@program{Figure #1}%
       \def\@currentlabel{#1}%
       \def\refstepcounter##1{}%
}
       \makeatother
%@+

\setlength{\marginparsep}{6mm}
\setlength{\marginparwidth}{20mm}
\newcommand*{\pinNumSize}{\scriptsize}

% See page 459--460 of the Companion:
% \newsavebox{\fminibox}%
% \newlength{\fminilength}%
% \newenvironment{fminipage}[1][\linewidth]%
% {\setlength{\fminilength}{#1-2\fboxsep-2\fboxrule}%
%   \begin{lrbox}{\fminibox}\begin{minipage}{\fminilength}}
% {\end{minipage}\end{lrbox}\noindent\fbox{\usebox{\fminibox}}}


\newcommand*{\subject}{Operating Systems and Systems Integration}
%\newcommand*{\dateofexam}{June sometime}
\newcommand*{\dateofexam}{11 June 2002}
\newcommand*{\subjectnumber}{CMT3321}

\newcommand*{\headerfontsize}{\footnotesize}
\newcommand*{\footerfontsize}{\scriptsize}

\newsavebox{\fminibox}%
\newlength{\fminilength}%
\setlength{\fminilength}{\textwidth-2\fboxsep-2\fboxrule}%
% \begin{lrbox}{\fminibox}%
%   \begin{minipage}{\fminilength}%
%   \subject\hfill Main Examination\hfill\dateofexam\\
%   (\subjectnumber)\hfill Year Two, 2000/2001\hfill\mbox{}
% \end{minipage}%
% \end{lrbox}

\begin{lrbox}{\fminibox}%
  \begin{minipage}{\fminilength}%
  \headerfontsize\upshape\subject{} (\subjectnumber)\hfill Main Examination 2001/2002}
\end{minipage}%
\end{lrbox}

\pagestyle{fancy}
\lhead{\headerfontsize\textbf{\upshape Department of Information and
    Communications Technology (Tsing Yi)\\
FT HDCSA (41300)}}
\rhead{\headerfontsize\textbf{\upshape page \thepage{} of
    \pageref{pag:lastpage}}}

%\rhead{\textbf{2503}}
% \lfoot{EE260}
% \rfoot{Supplementary 1999/2000}
% \renewcommand{\headrulewidth}{0pt}
% \lfoot{\begin{fminipage}%
%   \subject\fill Main Examination\fill\dateofexam\\
%   (\subjectnumber}\fill Year Two, 2000/2001\fill\mbox{}
% \end{fminipage}}
\lfoot{\noindent\fbox{\usebox{\fminibox}}}
%\cfoot{\headerfontsize\textbf{\upshape \mbox{}\\[-0.5\baselineskip]Main Examination
%    Year Two, 2000/2001}}
\cfoot{}

\renewcommand{\floatpagefraction}{0.75} % default is .5, to increase
% density.
\renewcommand*{\bottomfraction}{0.6} % default is 0.3
\renewcommand*{\topfraction}{0.85} % default is 0.7
\renewcommand*{\textfraction}{0.1} % default is 0.2

\setlength{\extrarowheight}{1pt}
\floatstyle{ruled}
\floatname{program}{Figure}
\newfloat{program}{tbh}{lop}

\providecommand*{\dc}{\textsf{\relsize{-1}X}\xspace} % dc = Don't care.

\providecommand{\ARQ}{\acro{ARQ}\xspace}
\providecommand{\ABM}{\acro{ABM}\xspace}
\providecommand{\BER}{\acro{BER}\xspace}
\providecommand{\UTP}{\acro{UTP}\xspace}
\providecommand{\PSTN}{\acro{PSTN}\xspace}
\providecommand{\HDLC}{\acro{HDLC}\xspace}
\providecommand{\QAM}{\acro{QAM}\xspace}
\providecommand{\ISP}{\acro{ISP}\xspace}
\providecommand{\PCM}{\acro{PCM}\xspace}


% why shouldn't a Linux server run X?

\begin{document}
\raggedright

  You are required to answer \textbf{ALL} questions in Section A.\\
  Answer ANY \textbf{\underline{THREE}} of the FIVE questions in
  Section B ONLY\@.\\
  Section A is worth a total of \textbf{FORTY} marks.  Each question
  in Section B is worth a total of \textbf{TWENTY} marks.

  %\vspace{1ex}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%                             SECTION A                             %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  
\begin{center}
  \textbf{Section A}\\[3ex]
  You are required to answer \textbf{ALL} questions.\\[3ex]
  You are advised to spend no more than \textbf{SEVENTY} minutes
  on this section.\\[3ex]
\end{center}

\renewcommand{\labelenumi}{\textbf{Question A-\theenumi.}}

\begin{question}
\item \marks{5}Linux is \emph{Free software} (as defined by Richard
  Stallman). List \emph{three} advantages of this.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  
\item \marks{5}A system administrator raised the priority of a
  long-running process to the maximum level, but during the following
  period, while it was running it still used only a small percentage
  of \CPU power.  Briefly explain how this could be so.

% AFTER EXAM: I SHOULD HAVE WORDED THIS AS:
% of \CPU processing power

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\item
  \begin{subQuestion}
  \item \marks{2}Briefly define the term \emph{process} in the context
    of operating systems.

  \item \marks{2}Briefly state one method for a system administrator
    to list \emph{all} processes in the Linux operating system.

  \item \marks{2}Briefly state one method for a system administrator
    to list \emph{all} processes in the Windows 2000 operating system.
  \end{subQuestion}
 
  
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  
\item \marks{5}Briefly explain the main difference between a
  \emph{Custom \IOsl interface} and a \emph{General-purpose \IOsl
    interface}.  Hint: an example of a general-purpose \IO interface
  is a \USB port.  An example of a custom interface is a keyboard
  interface.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  
\item
  \begin{subQuestion}
  \item \marks{2}Briefly define the term \emph{scheduler} in the
    context of any operating system.
  \item \marks{3}List three aims of the scheduler in any operating
    system.
  \end{subQuestion}
  
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% what are the main purposes of swapping? p. 457 of Understanding
% the Linux Kernel
  
\item \marks{5}Briefly explain the main difference between
  \emph{swapping} and \emph{paging} in memory management.

% NOTE AFTER THE EXAM:
% SHOULD HAVE BEEN WORDED AS:
% \emph{swapping} and \emph{paging} in the context of memory
% management.
% SINCE MANY STUDENTS THOUGHT THIS WAS ASKING ABOUT THE PHRASE
% ``PAGING IN'' RATHER THAN THE WORD ``PAGING''.
  
  \begin{flushright}
    \textbf{Section A is continued on the next page\ldots}
  \end{flushright}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\clearpage
  
\item \marks{5}Briefly explain the purpose of the \emph{memory
    management unit} (\acro{MMU}) in a computer.

% NOTE AFTER THE EXAM:
% I REALLY WANTED THEM TO SAY WHETHER THIS IS HARDWARE OR SOFTWARE,
% BUT THE QUESTION DOES NOT REALLY ASK THAT.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


  \begin{figure}[h]
    \centering%
    \includegraphics[width=0.5\linewidth]{process-states-q}
    \newFigTag{QA\ref{que:procStates}}
    \caption{Three states that a process may be in, and four ways
      that the state can change.}
    \label{fig:procStates}
  \end{figure}
  
\item \marks{4}\label{que:procStates}Figure~\vref{fig:procStates}
  shows the states that a process may have.  For each change of state,
  labeled A, B, C and D in figure~\vref{fig:procStates}, list one
  reason that may cause that change.
\end{question}

\clearpage
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%                             SECTION B                             %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\renewcommand{\labelenumi}{\textbf{Question B-\theenumi.}}

\begin{center}
  \textbf{Section B}\\[3ex]
  This section has FIVE questions.\\[3ex]
  You are required to answer ANY \textbf{\underline{THREE}} of the
  FIVE questions ONLY.\\[3ex]
  You are advised to spend no more than \textbf{THIRTY FIVE} minutes
  on any one question.
\end{center}

\begin{question}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%                            Question 1                             %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  
\item \label{que:question1}
  \begin{subQuestion}
    \item Briefly define the following terms, using diagrams where
      helpful:
      \begin{subQuestion}
      \item \marks{3}\emph{monolithic operating system}
        
      \item \marks{3}\emph{microkernel architecture}
      \end{subQuestion}
    \item 
      \begin{subQuestion}
      \item State:
        \begin{subQuestion} 
        \item \marks{1}one advantage, and
        \item \marks{1}\label{que:disadvantage-of-monolithic}one
          disadvantage
        \end{subQuestion}
        of monolithic operating systems compared with microkernel
        operating systems
        
      \item State:
        \begin{subQuestion} 
        \item \marks{1}one advantage, and
        \item \marks{1}\label{que:disadvantage-of-microkernel}one
          disadvantage
        \end{subQuestion}
        of microkernel operating systems compared with monolithic
        operating systems
      \end{subQuestion}
    \item \marks{5}Linux is an example of a monolithic operating
      system.  Explain why it does not suffer from the disadvantage
      you listed in your answer to question
      B-\ref{que:disadvantage-of-monolithic} above.
      
    \item \marks{5}Windows NT is an example of a microkernel operating
      systems.  Explain why it does not suffer from the disadvantage
      you listed in your answer to question
      B-\ref{que:disadvantage-of-microkernel} above.
    \end{subQuestion}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%                            Question 2                             %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\clearpage
\item \label{que:question2}
  \begin{subQuestion}
    \item This question is about three basic methods of \IO.

      Briefly define the following terms:
      \begin{subQuestion}
      \item \marks{3}\emph{polling}
      \item \marks{3}\emph{interrupt-driven \IOsl}
      \item \marks{3}\emph{direct memory access} (\acroSl{DMA})
      \end{subQuestion}
      
    \item \marks{5}Use a diagram to explain the difference between
      \IO-mapped \IO ports and memory-mapped \IO ports.
      
    \item Linux device drivers are packaged together with the
      kernel, while Windows device drivers are often provided together
      with the hardware in binary form, separate from the operating
      system.  List
      \begin{subQuestion}
      \item \marks{3}one advantage of the Windows method, and
      \item \marks{3}one advantage of the Linux method
      \end{subQuestion}
      of providing device drivers.
    \end{subQuestion}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%                            Question 3                             %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\vspace{4ex}

\item \label{que:question3}
  \begin{subQuestion}
  \item Briefly define each of the following terms in regard to the
    problem of deadlock in an operating system:
    \begin{subQuestion}
    %\item \marks{2}\emph{kernel control path}.
    % \item \marks{2}\emph{reentrant}
    \item \marks{2}\emph{mutual exclusion}

    \item \marks{2}\emph{preemption}

    \item \marks{2}\emph{circular wait}

    \item \marks{2}\emph{deadlock}
    \end{subQuestion}

  \item \marks{4}List \emph{four} conditions necessary for
    \emph{deadlock} to occur in an operating system.
    
  \item \marks{3}\label{que:example-deadlock}Describe an example where
    deadlock will occur in a computer system.

  \item \marks{5}Explain how deadlock can be avoided in a computer
    system, referring to the example you gave in the previous part
    (\ref{que:example-deadlock}).
  \end{subQuestion}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%                            Question 4                             %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\clearpage
\item \label{que:question4}
  \begin{subQuestion}
  \item \emph{Open}\acroSl{LDAP} is an open source implementation of the
    Lightweight Directory Access Protocol, standardised by the
    Internet Engineering Task Force.
    
    \emph{Active Directory} is a directory system developed by
    Microsoft which is based on \acro{LDAP}, and has many proprietary
    extensions and features.
    \begin{subQuestion}
    \item \marks{3}Give
      \begin{subQuestion}
      \item one advantage, and
      \item one disadvantage
      \end{subQuestion}
      of using \emph{Open}\acroSl{LDAP} to handle logins in a large
      tertiary educational institution.

    \item \marks{3}Give
      \begin{subQuestion}
      \item one advantage, and
      \item one disadvantage
      \end{subQuestion}
      of using \emph{Active Directory} to handle logins in a large
      tertiary educational institution.
    \end{subQuestion}


  \item
    \begin{subQuestion}
    \item \marks{2}What software can you use with Linux to share disk and
      printers to MacOS (Macintosh) computers?
      
    \item \marks{3}What software can you use with Linux to share disk
      and printers to Windows computers?  Under what conditions can
      this software be used as a primary domain controller for Windows
      2000?
      
    \item \marks{4}List at least two software packages that you would
      recommend to use at the same time so that Linux servers can
      share home directories to other Linux machines?
    \end{subQuestion}
    
  \item \marks{5}A computing department in a college has a large
    number of \PC{}s which dual boot using Linux and Windows 2000
    Professional.  There are also some old \acro{DEC} Alpha Unix
    machines, and a few Apple Macintoshes.  A server system is
    required that will provide the following features:
    \begin{itemize}
    \item A home directory that will be accessible when the user
      logs in either to Linux, Windows, Unix or Macintosh;
    \item A central printing system that should be accessible from all
      four platforms;
    \item All user's home directories contain their personal web site
      that is provided on the Internet through \acro{HTTP}
    \end{itemize}
    
    \textbf{Explain with the aid of diagrams a possible solution to
      this problem.}  Your answer should contain no more than half a
    page of writing.
  \end{subQuestion}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%                            Question 5                             %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\clearpage

\item \label{que:paging}
  \begin{subQuestion}
  \item
    \begin{subQuestion}
    \item \marks{2}List two important functions of a paging system in
      an operating system.

    \item \marks{2}Explain the term \emph{dirty page} in a paging system.
      
    \item \marks{1}Give one simple example the use of a read-only
      memory page.
      
    \item \marks{1}State one major difference between how a paging
      system deals with a read-only page compared with how it deals
      with a read-write page.
    \end{subQuestion}
    
    \begin{figure}[h]
    \centering%
    \includegraphics[width=0.5\linewidth]{paging-q}
    \newFigTag{QB\ref{que:paging}}
    \caption{A method of paging.}
    \label{fig:paging}
  \end{figure}
  \item Referring to figure~\ref{fig:paging}, briefly define the
    following terms:
    \begin{subQuestion}
    \item \marks{2}\emph{page}

    \item \marks{2}\emph{page table}
    \end{subQuestion}
  \item A computer system has four kilobyte pages and 32-bit address
    bus.  The three parts of this question refer to this computer
    system.
    \begin{subQuestion}
    \item \marks{3}Calculate the number of page table entries that are
      required.

    \item \marks{2}\label{que:problem-with-single-level-paging}Briefly
      list one major problem with the paging scheme shown in
      figure~\ref{fig:paging}.

    \item \marks{5}Explain with the aid of a diagram an alternative
      paging method that overcomes the problem you listed in the
      previous part \ref{que:problem-with-single-level-paging}.
    \end{subQuestion}
  \end{subQuestion}


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%                         End of Questions                          %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\end{question}

\vspace*{-2ex}

{
\newlength{\SA}
\newlength{\SB}
\newlength{\SC}
\newlength{\SD}
\newlength{\Se}
\newlength{\amount}
\settoheight{\SA}{\scriptsize $\star$}
\settoheight{\SB}{\footnotesize $\star$}
\settoheight{\SC}{\small $\star$}
\settoheight{\SD}{\normalsize $\star$}
\settoheight{\Se}{\large $\star$}

\setlength{\amount}{0.5\Se}

{
\centering

\raisebox{\amount-0.5\SA}[0pt][0pt]{\makebox{\scriptsize $\star$}}
\raisebox{\amount-0.5\SB}[0pt][0pt]{\makebox{\footnotesize $\star$}}
\raisebox{\amount-0.5\SC}[0pt][0pt]{\makebox{\small $\star$}}
\raisebox{\amount-0.5\SD}[0pt][0pt]{\makebox{\normalsize $\star$}}
\raisebox{\amount-0.5\Se}[0pt][0pt]{\makebox{\large $\star$}}
\hspace{1em}
\textbf{end of questions}\label{pag:lastpage}
\hspace{1em}
\raisebox{\amount-0.5\Se}[0pt][0pt]{\makebox{\large $\star$}}
\raisebox{\amount-0.5\SD}[0pt][0pt]{\makebox{\normalsize $\star$}}
\raisebox{\amount-0.5\SC}[0pt][0pt]{\makebox{\small $\star$}}
\raisebox{\amount-0.5\SB}[0pt][0pt]{\makebox{\footnotesize $\star$}}
\raisebox{\amount-0.5\SA}[0pt][0pt]{\makebox{\scriptsize $\star$}}

}}

% \appendix

% \section{Formulas}
% This appendix includes some formulas used in this subject.  Some of
% them may be used in this exam.

% \input{ee260formulas}
\end{document}





