\documentclass[english,serif,mathserif,xcolor=pdftex,dvipsnames,table]{beamer}
\usepackage[utf8]{inputenc}
%\usepackage[T1]{fontenc}
\usepackage{babel}
\usepackage{fixltx2e}
\usepackage{graphicx}
\usepackage{colortbl}%
  %\newcommand{\cellcolor}[2]{\multicolumn{1}{>{\columncolor{#1}}c}{#2}}
\usepackage{longtable}
\usepackage{multirow}
\usepackage{float}
\usepackage{wrapfig}
\usepackage{soul}
\usepackage{textcomp}
\usepackage{tikz}%
  \usetikzlibrary{arrows,shapes}%
  % For every picture that defines or uses external nodes, you'll have to
  % apply the 'remember picture' style. To avoid some typing, we'll apply
  % the style to all pictures.
  \tikzstyle{every picture}+=[remember picture]%
\usepackage{marvosym}
\usepackage{wasysym}
\usepackage{latexsym}
\usepackage{amssymb}
\usepackage{hyperref}
\tolerance=1000
\providecommand{\alert}[1]{\textbf{#1}}

\usetheme{uzhneu-en-informal}


%% Use `\largeskip` to get a larger vertical white space between two
%% lines/paragraphs:
\newcommand{\largeskip}{\vspace{1em}}
\def\+{\largeskip}
\setlength{\parsep}{1.0em}

% \begin{document}

\title[Large Scale Computing Infrastructures]{%
  \textbf{Large Scale Computing Infrastructures}\\
  \text{(MINF 4526 HS2011)}
}

\author[S.\ Maffioletti]
       {Sergio Maffioletti \\ \texttt{<sergio.maffioletti@gc3.uzh.ch>}}
       \institute[GC3, Univ. of Zurich]% will appear on the bottom line
       {\href{http://www.gc3.uzh.ch/}{Grid Computing Competence Centre}, 
       \href{http://www.uzh.ch/}{University of Zurich}
       \\ \url{http://www.gc3.uzh.ch/}}
 
\begin{document}

 \maketitle
                 
                 
% Intro
\begin{frame}
  
  \frametitle{Overview of the course}
  \begin{itemize}
  \item \textbf{Theme 1:} from {\it local execution} to {\it distributed computing} through {\it clouds}
  \item \textbf{Theme 2:} Overview of large scale infrastructures for scientific computing (grids and clouds)
  \item \textbf{Theme 3:} Scientific application's challenges 
  \item \textbf{Theme 4:} Security
  \item \textbf{Theme 5:} Python basic (yes, you need it)
  \item \textbf{Theme 6:} {\it Data handling} and {\it information processing}
  \item \textbf{Theme 7:} Let's put everything together and solve some real problems
  \end{itemize}
  \label{sec:1}
  
\end{frame}

% Generic statement about the objective of the course
\begin{frame}

  \frametitle{What will you learn here?}
  \begin{itemize}
  \item What characterize a scale computing infrastructure ?
  \item Why such an infrastructure could be beneficial for scientific research ?
  \item Why scientific research has a demand for large amount of computing resources ?
  \item How do we map a scientific usecase in terms of infrastructure requirements ?
  \item What are the challenges that need to be addressed when porting a scientific usecase on a large scale infrastructure ?
  \end{itemize}

\end{frame}

\begin{frame}

  \frametitle{Practical information}
  \begin{itemize}
  \item{{\bf Dates and location}:} \\ Wednesday 12:00 - 14:00. Room BIN-2.A.10
  \item{{\bf Exercises}:} \\ Thursday 16:00 - 18:00. Room BIN-1.D.12
  \item{{\bf Course web link}:} \url{http://www.vorlesungen.uzh.ch/HS11/suche/e-50544812.details.html}
  \item{{\bf Individual projects}:} \\ During the course, each attenders will develop an individual project centered around one of the thematics we will discuss throughout the course
  \item{{\bf Exam}:} {\it still to define dates and modalities}
  \item{{\bf Learning material}:} \\ At the end of each class we will provide pointers to online documentation
  \end{itemize}

\end{frame}


%%%%%%%%%%%%%%%%%%% Lecture 1 %%%%%%%%%%%%%%%%%%%

% Detail on lecture 1
\begin{frame}
  \frametitle{Lecture 1: from Local computing to Distributed systems through Clouds}
  \label{sec:2}
  Let's look at the application's execution profile
  \begin{enumerate}
  \item \textbf{Local systems}
  \item \textbf{Cluster systems}
  \item \textbf{Distributed systems}
  \end{enumerate}

{\small Slides available for download from: 
    \url{http://www.gc3.uzh.ch/teaching/lsci2011/lecture01.pdf}}
\end{frame}

  
\begin{frame}
  \frametitle{Local System}
  \label{sec:3}

  Execute an application on your personal computer.
  
  \begin{itemize}
  \item{} Everything locally available: {\bf Application}, {\bf input data} and {\bf results}
  \item{} {\bf Dedicated} system (most of the times, user has 100\% control)
  \item{} {\bf Performance} depends on local machine
  \item{} {\bf Reliability} depends on Application
  \item{} {\bf Sequential} execution mode
  \item{} No {\bf scalability} issues (provided one has time to wait until all data are processed sequentially)
  \item{} {\bf Access} exclusive (own account): 1 username + 1 password
  \end{itemize}

\end{frame}

\begin{frame}
  \frametitle{Local System}
  \label{sec:3a}

  \begin{itemize}
  \item{} {\it Single} Resource
  \item{} {\it Single} Owner
  \item{} No particular security requirements nor access {\it policies}
  \item{} {\it Reliable} environment (you know your laptop!)
  \item{} Resource is {\it homogeneous}
  \item{} {\it Local} resource (you're sitting in front of it!)
  \item{} No resource {\it management} policies
  \item{} No specific {\it network} connectivity
  \end{itemize}
  
\end{frame}

\begin{frame}
  \frametitle{Question 1}
  \label{sec:4}
  Given a single thread application and 10 input files to analyze (1 application execution per input file).\\
  Given a 4 cores machine with a single SATA disk.\\
  How can we reduce the overall execution time ?
\end{frame}

\begin{frame}
  \frametitle{Question 2}
  \label{sec:4a}
  If each application execution generates an I/O throughput of 50MB/s r \textbar w (and assuming disk access performance is 100MB/s r \textbar w)\\
  How shall we distribute the load to optimize the throughput ?\\
  {\it Note}: this exercise can be made also considering memory bandwidth
\end{frame}

\begin{frame}
  \frametitle{What do we learn here?}
  \label{sec:4b}
  % We learn that we need to profile an application execution as well as the entire experiment (e.g. the 10 input files to analyze) against the available platforms, to understand what best {\it High Throughput Computing} (HTC) solution we can implement.
  From these exercises we learn that we need to profile the application as well as the entire experiment (e.g. the 10 input files to analyze) according to the available platform to understand what HTC approach to follow. This can also be applied the other way round; the more we understand the application and experiment behaviours, the better we can plan the computing and data infrastructure.
\end{frame}


\begin{frame}
  \frametitle{Cluster System}
  \label{sec:5}
  What is Cluster ?
  \begin{itemize}
  \item{} a collection of {\it parallel} and {\it distributed processing} system that are {\it interconnected} by a high-speed network
  \item{} work as a {\it single integrated} computing resource
  \end{itemize}
\end{frame}

\begin{frame}
  \frametitle{Cluster System}
  \label{sec:5a}
  \includegraphics[height=0.8\textheight]{lecture01/cluster.pdf}
\end{frame}

\begin{frame}
  \frametitle{Example of PBS structure}
  \label{sec:5b}
  \includegraphics[height=0.8\textheight]{lecture01/structure.png}
\end{frame}

\begin{frame}
  \frametitle{Cluster System}
  \label{sec:5c}

  \begin{itemize}
  \item{} Most of the time data available on the cluster: {\bf Application}, {\bf input data} and {\bf results}
  \item{} {\bf Minimal} control on the system
  \item{} Network {\bf File Server} involved (NFS, Lustre, GPFS, \dots)
  \item{} {\bf Execution} needs to be described (i.e. {\it Resource requirements})
  \item{} {\bf Performance} can be tuned by adapting execution to hosting environments (e.g. local storage vs Network file server)
  \end{itemize}
  
\end{frame}

\begin{frame}
  \frametitle{Cluster System, cont.}
  \label{sec:5d}
  \begin{itemize}
  \item{} {\bf Shared access}. Own account (configured by a system administrator). 1 username + 1 password (equal on each node of the cluster)
  \item{} {\bf Reliability I} depends also on how the application behaves during the execution.
  \item{} {\bf Reliability II} may be affected by reliabiity of the execution node(s)
  \item{} {\bf Asynchronous} execution (controlled by a Local Resource Management System)
  \item{} {\bf Parallel} execution (having more nodes at disposal)
  \item{} {\bf Scalability} is measured against the entire system
  \end{itemize}
  
\end{frame}

\begin{frame}
  \frametitle{Cluster System}
  \label{sec:5e}

  \begin{itemize}
  \item{} {\it Multiple} Resources
  \item{} Owned by a {\it single institution}
  \item{} Single security and access {\it policies}
  \item{} {\it Volatile} environment (It is always better to check before start executing)
  \item{} Resources are {\it homogeneous}
  \item{} Resources are within your {\it institution's campus}
  \item{} Single resource {\it management} policies
  \item{} May have {\it structured} network connectivity within university campus and on the Internet
  \end{itemize}
  
\end{frame}

\begin{frame}
  \frametitle{Goals of a batch management system}
  \label{sec:6}
  \begin{itemize}
  \item{{\bf Administrative goals}}
    \begin{itemize}
    \item{} Maximize utilization and cluster responsiveness
    \item{} Tune fairness policies and workload distribution
    \item{} Automate time-consuming tasks
    \item{} Trouble-shoot job and resource failures
    \item{} Integrate new hardware and cluster services into the batch system
    \end{itemize}
  \item{{\bf User goals}}
    \begin{itemize}
    \item{} Manage current workload
    \item{} Identify available resources
    \item{} Minimize workload response time
    \item{} Track historical usage
    \item{} Identify effectiveness of prior submissions
    \end{itemize}
  \end{itemize}
\end{frame}

\begin{frame}
  \frametitle{Example of Resource requirements}
  \label{sec:7}
  \begin{itemize}
  \item{} {\bf cput}: max CPU time used by all processes in the job
  \item{} {\bf pcput}: max CPU time used by any single process in the job
  \item{} {\bf mem}: max amount of physical memory used by the job
  \item{} {\bf pmem}: max amount of physical memory used by any process of the job
  \item{} {\bf vmem}: max amount of virtual memory used by the job
  \item{} {\bf pvmem}: max amount of virtual memory used by any process of the job
  \end{itemize}
\end{frame}

\begin{frame}
  \frametitle{Example of Resource requirements cont.}
  \label{sec:7a}
  \begin{itemize}
  \item{} {\bf walltime}: wall clock time running
  \item{} {\bf file}: the largest size of any single file that may be created by the job
  \item{} {\bf host}: name of the host on which job should be run
  \item{} {\bf nodes}: number and/or type of nodes to be reserved for exclusive use by the job
  \end{itemize}
\end{frame}


\begin{frame}
  \frametitle{Question 1}
  \label{sec:8a}
  Provided an homogeneous cluster with {\it 4 nodes} (4 cores per node); pre-installed application binary. \\
  {\it 100 input files} to analyze (1 application run per input file) \\
  How do we distribute the load ?
\end{frame}

\begin{frame}
  \frametitle{Question 2}
  \label{sec:8b}
  If application and data are available on a {\it Network Filesystem} (let's say NFS) and each execution node has a {\it local disk} large enough to contain 4 input files, how can we improve the overall performance ?
\end{frame}

\end{document}

