%% $Header: /cvsroot/lcdp/lpic/general-linux-1/slides/gl1.101.4.slides.tex,v 1.2 2003/05/30 04:57:57 waratah Exp $


\input{gl1.slide-header.tex}
\usepackage{epsfig}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%----10->|-----20->|-----30->|-----40->|-----50->|-----60->|-----70->|-----80->
\begin{slide} %================================================================
\begin{center} \LARGE \textsf{-- General Linux 1 -- \\
Setup SCSI Devices [2]} \\[2mm]
\large  \textsf{(Linux Professional Institute Certification)}\\[1mm]

\normalsize\end{center}

\footnote{Copyright \copyright\ 2002 Geoffrey Robertson. Permission is granted to make and distribute verbatim copies or modified versions of this document provided that this copyright notice and this permission notice are preserved on all copies under the terms of the GNU General Public License as published by the Free Software Foundation---either version 2 of the License or (at your option) any later version.}
 
\scriptsize
\begin{verbatim} 
   .~.    
   /V\     by: geoffrey robertson        
  // \\        geoffrey@zip.com.au
  @._.@ 
\end{verbatim} 
\tiny
\begin{verbatim}
$Id: gl1.101.4.slides.tex,v 1.2 2003/05/30 04:57:57 waratah Exp $ 
\end{verbatim} 
\normalsize  
\vfill \end{slide} %-----------------------------------------------------------
%----10->|-----20->|-----30->|-----40->|-----50->|-----60->|-----70->|-----80->

%==============================================================================
%\begin{slide}{} %ghr 
%\Slidecontents
%\vfill \end{slide} %-----------------------------------------------------------

%==============================================================================
%==============================================================================
\begin{slide} %ghr
\slideheading{Setup SCSI Devices [2]}
\slidesubheading{(1.1) 101 Hardware \& Architecture [11]}
\begin{description}
  \item[1.101.1] Configure BIOS Fundamental Settings [3]
  \item[1.101.3] Configure Modem and Sound Cards [2]
  \item[1.101.4] Setup SCSI Devices [2]
  \item[1.101.5] Set Up Different PC Expansion Cards [2]
  \item[1.101.6] Configure Communication Devices [2]
  \item[1.101.7] Set Up USB devices [2]
\end{description}
\vfill \end{slide} %-----------------------------------------------------------
  

%==============================================================================
%==============================================================================
\begin{slide} %ghr
\slideheading{Setup SCSI Devices [2] }
\slidesubheading{Objective} 

Candidates should be able to configure SCSI devices using the SCSI
BIOS as well as the necessary Linux tools.

They also should be able to differentiate between the various types of
SCSI.

This objective includes manipulating the SCSI BIOS to detect used and
available SCSI IDs and setting the correct ID number for different
devices especially the boot device.

It also includes managing the settings in the computer's BIOS to
determine the desired boot sequence if both SCSI and IDE drives are
used.

\vfill \end{slide} %-----------------------------------------------------------
 
%==============================================================================
\begin{slide} %ghr
\slideheading{Setup SCSI Devices}
\slidesubheading{Key files, terms, and utilities}
\begin{alltt}

SCSI ID
/proc/scsi/
scsi_info
\end{alltt}
\vfill \end{slide} %-----------------------------------------------------------
 
%==============================================================================
\begin{slide} %ghr
\slideheading{}
\slidesubheading{Resources of interest}
\begin{description} 
\item[SCSI-2.4 HOWTO]: 
\end{description}
\vfill \end{slide} %-----------------------------------------------------------
 
%==============================================================================
%\begin{slide}} %ghr
%\Slidecontents
%\vfill \end{slide} %-----------------------------------------------------------

%==============================================================================
\begin{slide} %Andrew Eager
  \slideheading{SCSI Devices}
\begin{itemize}
\item SCSI - Small Computer Systems Interface
\item SCSI can support a range of devices 

\begin{itemize}
\item Hard disks
\item Tape drives
\item Scanners
\end{itemize}
\item There are many different types of SCSI based on: 

\begin{itemize}
\item \noindent Bus Width
\item \noindent Bus Speed 
\item \noindent Max no of devices
\end{itemize}
\end{itemize}
\vfill
\end{slide}

%==============================================================================
\begin{slide} %Andrew Eager
\slideheading{SCSI TYPES}
\small
\begin{tabular}{|c|c|c|c|}
\hline 
\textbf{Name}&
\textbf{Bus Width (bits)}&
\textbf{Bus Speed (MB/s)}&
\textbf{Max Devices}\\
\hline
\hline 
SCSI-1&
8 &
5 &
8\\
\hline 
Fast SCSI&
8&
10&
8\\
\hline 
Ultra SCSI&
8&
20&
8\\
\hline 
Ultra2 SCSI&
8&
40&
8\\
\hline 
Fast Wide SCSI&
16&
20&
16\\
\hline 
Wide Ultra SCSI&
16&
40&
16\\
\hline 
Wide Ultra2 SCSI&
16&
80&
16\\
\hline 
Ultra3 SCSI&
16&
160&
16\\
\hline 
Ultra320 SCSI&
16&
320&
16\\
\hline
\end{tabular}
\vfill
\end{slide}

%==============================================================================
\begin{slide} %Andrew Eager
\slideheading{SCSI Key Points}

\begin{itemize}
\item All devices on the SCSI bus are are numbered from 0 to N (7 or 15)
\item The SCSI controller is usually numbered 7 or 15
\item The higher the device number, the higher its priority
\item To boot from a SCSI disk, it must be device 0
\item The SCSI bus must be terminated at both ends
\item SCSI controllers need a kernel module to make them work
\end{itemize}
\vfill \end{slide} %-----------------------------------------------------------


%==============================================================================
\begin{slide}{} %Andrew Eager
  \slideheading{SCSI Addressing}

  SCSI devices are addressed according to:
  \begin{itemize}
  \item SCSI adapter number (host)
  \item channel number (bus)
  \item id number (target)
  \item lun (lun)
  \end{itemize}
  
\vfill \end{slide} %----------------------------------------------------------

%==============================================================================
\begin{slide}{} %Andrew Eager
  \slideheading{SCSI Driver Layers}

  There are three layers to the SCSI subsystem:
  \begin{itemize}
  \item Low level driver - Controller specific
  \item Mid level driver - SCSI unifying layer
  \item Upper level driver - Device specific
    
  \end{itemize}
\vfill \end{slide} %-----------------------------------------------------------


%==============================================================================
\begin{slide} %Andrew Eager
  \slideheading{SCSI Driver Layers}
  \fbox{\epsfig{file=../images/scsi.eps,width=0.7\textwidth}}
  
\vfill \end{slide} %-----------------------------------------------------------



%==============================================================================
\begin{slide} %Andrew Eager
\slideheading{SCSI Driver Layers - Example}
 
Consider an SCSI hard disk as an example

\begin{itemize}
\item Low level - \texttt{aha1542.o}
\item Mid level - \texttt{scsi\_mod.o}
\item Upper level - \texttt{sd\_mod}
\end{itemize}

\vfill \end{slide} %-----------------------------------------------------------


%==============================================================================
\begin{slide}{} %Andrew Eager
  \slideheading{SCSI Upper Level Drivers}

  \begin{itemize}
  \item These drivers bind themselves to \texttt{/dev} entries.
  \item A non exhaustive, but pretty complete list:
    \begin{itemize}
    \item Disk driver (magnetic) - \texttt{sd.o}
    \item Disk driver (optical) - \texttt{sd\_mod.o}
    \item CDROM driver - \texttt{sr.o}
    \item Tape drivers - \texttt{st.o}
    \item Generic drivers - \texttt{sg.o}
    \end{itemize}
  \end{itemize}
  \vfill 
\end{slide} %-----------------------------------------------------------


%==============================================================================
\begin{slide} %Andrew Eager
\slideheading{SCSI \& the Kernel}

 \begin{itemize}
\item To get SCSI working, you first need to load the appropriate
  module for your SCSI controller.

\item For example: An Adaptec 1542 controller with an attached hard
  disk you would:
\begin{alltt}
\rootcmd{insmod aha1542}   
\end{alltt}

\item Then load the mid level driver:
\begin{alltt}
\rootcmd{insmod scsi\_mod}
\end{alltt}

\item Finally, load the upper level driver:
\begin{alltt}
\rootcmd{insmod sd}
\end{alltt}
\end{itemize}

\vfill \end{slide} %-----------------------------------------------------------


%==============================================================================
\begin{slide}{} %Andrew Eager
\slideheading{/proc/scsi}

\begin{itemize}
\item To see what devices have been found (at the mid level layer), have a look in \texttt{/proc/scsi}:
\end{itemize}
\begin{alltt}
\rootcmd{cat /proc/scsi/scsi}
Attached devices:
Host: scsi0 Channel: 00 Id: 00 Lun: 00
  Vendor: CREATIVE Model: CD5233E    Rev: 1.00
  Type:   CD-ROM            ANSI SCSI revision: 02
Host: scsi0 Channel: 00 Id: 01 Lun: 00
  Vendor: SONY     Model: CD-RW  CRX145E Rev: 1.0b
  Type:   CD-ROM            ANSI SCSI revision: 02
\end{alltt}
\vfill
\end{slide} %-----------------------------------------------------------



%==============================================================================
\end{document}%================================================================
%==============================================================================

