TapeSessions.tex 1.23 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19

\chapter{Tape Sessions and other sub-processes}

\section{Introduction}

The program {\tt cta-taped} is a daemon managing the tape drive and transferring data from tape to drive. The daemon is split in two levels of processes: the daemon process, which is a single threaded sub-process manager, which does not have any external connectivity. The sub-processes can be multi-threaded, and implement external connectivity. Two types of sub-processes implement different kinds of functionality.

\section{Drive sub-process}
The main sub-process is the drive sub-process. One such sub-process will be launched per drive in the tape server. The drive process executes one mount and then exits. The daemon then restarts a new instance of it, passing the previous instances exit status. Based on this status of the previous run, the session could either become a cleaning session, where any potentially still mounted tape is removed from the drive, or start scheduling. Scheduling can lead to archive, retrieve or label sessions.

The tape session types and state changes are shown in figure \ref{statediag}.

\begin{figure}[h]
\begin{center}
\includegraphics{CTA_tape_session_states}
\end{center}
\caption{\label{statediag}Tape sessions state diagram}
\end{figure}