From cafdf365c0d4b39768ccd02b34f19bd8e637616a Mon Sep 17 00:00:00 2001 From: Stefan Junker Date: Wed, 5 Apr 2017 15:32:36 +0200 Subject: [PATCH] thesis: init latex file structure and bibliography --- .gitignore | 22 ++- src/docs/abstract.tex | 26 ++++ src/docs/glossary.tex | 192 +++++++++++++++++++++++++++ src/docs/parts/context/context.tex | 40 ++++++ src/docs/parts/research/research.tex | 4 + src/docs/thesis.bib | 1 + src/docs/thesis.md | 154 +++++++++++++++++++++ src/docs/thesis.tex | 147 ++++++++++++++++++++ src/docs/thesis.tex.latexmain | 0 src/docs/title.tex | 30 +++++ 10 files changed, 615 insertions(+), 1 deletion(-) create mode 100644 src/docs/abstract.tex create mode 100644 src/docs/glossary.tex create mode 100644 src/docs/parts/context/context.tex create mode 100644 src/docs/parts/research/research.tex create mode 120000 src/docs/thesis.bib create mode 100644 src/docs/thesis.md create mode 100644 src/docs/thesis.tex create mode 100644 src/docs/thesis.tex.latexmain create mode 100644 src/docs/title.tex diff --git a/.gitignore b/.gitignore index a188e06..2b671be 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,21 @@ -docs/* +*.swp +*.swo +*.aux +*.fdb_latexmk +*.fls +*.lof +*.log +*.lot +*.synctex.gz +*.toc +src/docs/*.pdf +*.dvi +*.glo +*.ist +*.xdy +.dot/* +*.out +*.bbl +*.blg + +docs/ diff --git a/src/docs/abstract.tex b/src/docs/abstract.tex new file mode 100644 index 0000000..1e5f7ca --- /dev/null +++ b/src/docs/abstract.tex @@ -0,0 +1,26 @@ +\begin{center} +{\Large \textbf{Abstract}} +\end{center} + +\bigskip + +\begin{center} + \begin{tabular}{p{2.8cm}p{10cm}} + Topic: & \topic\\ + & \\ + Applicant: & \authorOne \\ + & \\ + Supervisors: & \supervisorOne \\[.5ex] + & \supervisorTwo\\ + & \\ + Submition: & \submitdate \\ + & \\ + Buzzwords: & \buzzwords \\ + & \\ + \end{tabular} +\end{center} + +\bigskip + +\noindent +TODO: abstract goes here diff --git a/src/docs/glossary.tex b/src/docs/glossary.tex new file mode 100644 index 0000000..e0d379c --- /dev/null +++ b/src/docs/glossary.tex @@ -0,0 +1,192 @@ +% // vim: set ft=tex: + +\newglossaryentry{API}{ + name = API, + description = { + Application Programming Interface + }, +} + +\newglossaryentry{OS}{ + name = Operating System, + description = { + The software that manages the system's hardware ressources. + Other \glspl{app} can access the ressources only through the interface provided by the \gls{OS}. + }, +} + +\newglossaryentry{fs}{ + name = filesystem, + description = { + TODO + }, +} + +\newglossaryentry{virt}{ + name = virtualization, + description = { + TODO + }, +} + +\newglossaryentry{OSS}{ + name = Open-Source Software, + description = { + TODO + }, +} + +\newglossaryentry{osvirt}{ + name = Operating System-Level Virtualization, + description = { + TODO + }, +} + +\newglossaryentry{hypervisor}{ + name = Hypervisor, + description = { + TODO + }, +} + +\newglossaryentry{VM}{ + name = Virtual Machine, + description = { + TODO + }, +} + +\newglossaryentry{Linux}{ + name = Linux, + description = { + is a generic term referring to the family of Unix-like + computer operating systems that use the Linux kernel + }, + plural=Linuces +} + +\newglossaryentry{rootfs}{ + name = RootFS, + description = { + % TODO + }, +} + +\newglossaryentry{lxns}{ + name = Linux Namespace, + description = { + entitiy that holds a specific set of process attributes and can be set per process + }, +} + +\newglossaryentry{lxcap}{ + name = Linux Capability, + description = { + entitiy that holds a specific set of process attributes and can be set per process, mainly to establish a relationship between processes and \gls{OS} resources + }, + plural = Linux Capabilities, +} + +\newglossaryentry{lxvfs}{ + name = Linux VFS, + description = { + Virtual Filesystem Switch, a filesystem abstraction layer in \gls{Linux}. + }, +} + +\newglossaryentry{BSD}{ + name = BSD, + description = { + TODO + } +} + +\newglossaryentry{computer}{ + name = Computer, + description = { + is a programmable machine that receives input, + stores and manipulates data, and provides + output in a useful format + } +} + +\newglossaryentry{app}{ + name=software-application, + description={ + TODO + } +} + +\newglossaryentry{pm}{ + name=package manager, + description={ + TODO + } +} + +\newglossaryentry{sac}{ + name=Software Application Container, + description={ + The broad term for the technology used to build, package, distribute and run an application program in isolation from the underlying and co-existing systems, wherein the level or technique of isolation can be different depending on the \gls{sacr}. + The term is nuanced from \gls{appc} defined by the \gls{appcorg}. + The \gls{appcorg} is a community driven effort to create an open, standardized specification for developers and users of \gls{sac} technology. + Such independent standards are required to form interoperability between \gls{sac} implementations made by independent parties. + Some implementations will be subject to more detailed examination in Part \ref{part:research}. + } +} +\newglossaryentry{saci}{ + name=Software Application Container Image, + description={ + An archive file that contains all of the necessary binaries that are needed to execute an application and a manifest file that that contains metadata about the application. Alternatively to containing all the required binary files, the manifest file can declare dependencies to other application container images, which must then be available at runtime to execute the contained application. + } +} + +\newglossaryentry{sacr}{ + name=Software Application Container Runtime, + description={ + An application program (suite) that understands how to run the software inside an \gls{saci}. + } +} + +\newglossaryentry{LXC}{ + name=LXC, + description={ + TODO + } +} + +\newglossaryentry{Docker}{ + name=Docker, + description={ + A very popular \gls{sac} platform and application suite, providing functionality to build and deploy Docker specific \glspl{saci}. + } +} + +\newglossaryentry{systemd-nspawn}{ + name=systemd-nspawn, + description={ + TODO + } +} + +\newglossaryentry{rkt}{ + name=rkt, + description={ + TODO + } +} + +\newglossaryentry{appcorg}{ + name=App Container Organisation, + description={ + Organisation for the App Container specification, including the schema and associated tooling. + } +} + +\newglossaryentry{appc}{ + name=App Container, + description={ + Specific variant of an \gls{sac} defined by the \gls{appcorg}. + } +} diff --git a/src/docs/parts/context/context.tex b/src/docs/parts/context/context.tex new file mode 100644 index 0000000..5475720 --- /dev/null +++ b/src/docs/parts/context/context.tex @@ -0,0 +1,40 @@ +% // vim: set ft=tex: +\chapter{Introduction} + +\section{Purpose of the Study} +% Purpose of the Study +%The Purpose of the Study is a statement contained within one or two paragraphs that identifies the research design, such as qualitative, quantitative, mixed methods, ethnographic, or another design. The research variables, if a quantitative study, are identified, for instance, independent, dependent, comparisons, relationships, or other variables. The population that will be used is identified, whether it will be randomly or purposively chosen, and the location of the study is summarized. Most of these factors will be discussed in detail in Chapter 3. + +\section{Significance of the Study} +% Significance of the Study +% The significance is a statement of why it is important to determine the answer to the gap in the knowledge, and is related to improving the human condition. The contribution to the body of knowledge is described, and summarizes who will be able to use the knowledge to make better decisions, improve policy, advance science, or other uses of the new information. The “new” data is the information used to fill the gap in the knowledge. + +\section{Primary Research Questions} +% Primary Research Questions +% The primary research question is the basis for data collection and arises from the Purpose of the Study. There may be one, or there may be several. When the research is finished, the contribution to the knowledge will be the answer to these questions. Do not confuse the primary research questions with interview questions in a qualitative study, or survey questions in a quantitative study. The research questions in a qualitative study are followed by both a null and an alternate hypothesis. + +\section{Hypotheses} +% Hypotheses +% A hypothesis is a testable prediction for an observed phenomenon, namely, the gap in the knowledge. Each research question will have both a null and an alternative hypothesis in a quantitative study. Qualitative studies do not have hypotheses. The two hypotheses should follow the research question upon which they are based. Hypotheses are testable predictions to the gap in the knowledge. In a qualitative study the hypotheses are replaced with the primary research questions. + +\section{Research Design} +% In Chapter 1 this is a summary of the methodology and contains a brief outline of three things: (a) the participants in a qualitative study or the subjects of a quantitative study (human participants are referred tyo as participants, non-human subjects are referred to as subjects), (b) the instrumentation used to collect data, and (c) the procedure that will be followed. All of these elements will be reported in detail in Chapter 3. In a quantitative study, the instrumentation will be validated in Chapter 3 in detail. In a qualitative study, if it is a researcher-created questionnaire, validating the correctness of the interview protocol is usually accomplished with a pilot study. For either a quantitative or a qualitative study, using an already validated survey instrument is easier to defend and does not require a pilot study; however, Chapter 3 must contain a careful review of the instrument and how it was validated by the creator. +% In a qualitative study, which usually involves interviews, the instrumentation is an interview protocol – a pre-determined set of questions that every participant is asked that are based on the primary research questions. A qualitative interview should contain no less than 10 open-ended questions and take no less than 1 hour to administer to qualify as “robust” research. +% In the humanities, a demographic survey should be circulated with most quantitative and qualitative studies to establish the parameters of the participant pool. Demographic surveys are nearly identical in most dissertations. In the sciences, a demographic survey is rarely needed. + +\section{Theoretical Framework} +% The theoretical framework is the foundational theory that is used to provide a perspective upon which the study is based. There are hundreds of theories in the literature. For instance, if a study in the social sciences is about stress that may be causing teachers to quit, Apple’s Intensification Theory could be cited as the theory was that stress is cumulative and the result of continuing overlapping, progressively stringent responsibilities for teachers that eventually leads to the desire to quit. In the sciences, research about new species that may have evolved from older, extinct species would be based on the theory of evolution pioneered by Darwin. +% Some departments put the theoretical framework explanation in Chapter 1; some put it in Chapter 2. + +\section{Assumptions, Limitations, and Scope (Delimitations)} +% Assumptions are self-evident truths. In a qualitative study, it may be assumed that participants be highly qualified in the study is about administrators. It can be assumed that participants will answer truthfully and accurately to the interview questions based on their personal experience, and that participants will respond honestly and to the best of their individual abilities. +% Limitations of a study are those things over which the research has no control. Evident limitations are potential weaknesses of a study. Researcher biases and perceptual misrepresentations are potential limitations in a qualitative study; in a quantitative study, a limitation may be the capability of an instrument to accurately record data. + +% Scope is the extent of the study and contains measurements. In a qualitative study this would include the number of participants, the geographical location, and other pertinent numerical data. In a quantitative study the size of the elements of the experiment are cited. The generalizability of the study may be cited. The word generalizability, which is not in the Word 2007 dictionary, means the extent to which the data are applicable in places other than where the study took place, or under what conditions the study took place. +% Delimitations are limitations on the research design imposed deliberately by the researcher. Delimitations in a social sciences study would be such things as the specific school district where a study took place, or in a scientific study, the number of repetitions. + +\section{Definition of Terms} +% The definition of terms is written for knowledgeable peers, not people from other disciplines As such, it is not the place to fill pages with definitions that knowledgeable peers would know at a glance. Instead, define terms that may have more than one meaning among knowledgeable peers. + +\section{Summary} +% Summarize the content of Chapter 1 and preview of content of Chapter 2. diff --git a/src/docs/parts/research/research.tex b/src/docs/parts/research/research.tex new file mode 100644 index 0000000..d92e451 --- /dev/null +++ b/src/docs/parts/research/research.tex @@ -0,0 +1,4 @@ +% // vim: set ft=tex: +\chapter{Topic Refinement} + +\chapter{Criteria} diff --git a/src/docs/thesis.bib b/src/docs/thesis.bib new file mode 120000 index 0000000..9a0ca81 --- /dev/null +++ b/src/docs/thesis.bib @@ -0,0 +1 @@ +/home/steveej/src/mendeley/Static-Code-Analysis-Kernel-Memory-Saftey.bib \ No newline at end of file diff --git a/src/docs/thesis.md b/src/docs/thesis.md new file mode 100644 index 0000000..4cdad50 --- /dev/null +++ b/src/docs/thesis.md @@ -0,0 +1,154 @@ +% From Declarative Source-Package Management to Application Container Deployment +% Stefan Junker +% Wintersemester 2016/2017 + +* Source-Based Build System for Application Containers +* From Declarative Source-Package Management to Application Container Deployment +* Container Build System using Source-Package Management +* Using A Declarative And Deterministic Source-Package Manager to Build Application Container Images + +# Introduction To Topic And The Underlying Problem +(...) + +## Basic Terms and Relations +Before solving the underlying problem, I want to give a brief summary of what I'm referring to as packages, containers, application and their source. Further enlarging upon the definitions will follow in succeeding chapters when more detailed knowledge will be required. + +### Application +In the context of computers and their operating systems, an application consists of a unique set of files that are required to execute that specific application on the running operating system. +The operating system understands how to execute the application's files, which are binary translations from the application source code. + +For reasons that will be discussed in a later chapter, almost every application is written to depend on library functions that are not part of the application itself, but need to be properly installed on the operating system for the applications to find and use it. + +### Package +In order to install an run application and library files on different systems, their set of files are packed into single files. +These are called packages, and can be transferred to other computers and installed there via the operating systems package manager. + +### Application Container +If an application and all it's needed library function files are instead packed together into one file it can be called an application container image. + +TODO: explain the different understandings of what a container is and what is relevant for this thesis + +#### Chroot +On Linux, the syscall _chroot()_ will change the effective root directory for the current process. +TODO + +#### Namespaces +TODO + +#### Cgroup + +## Ideology versus Reality +In the ideal case it would be possible to install an application and its required shared library files in every possible combination on the same computer, which as an example could mean to install many different applications, multiple versions of the same application and libraries and of course a combination. +It would also not cause a conflict or side effects if the shared libraries, that are required by different applications, have to be installed in multiple different versions. + +Unsurprisingly the reality is not ideal, at least not for many popular operating systems and their included package management systems. + + +### Classical (Non Container) Attempts +Developers of operating systems and package managers have been trying to achieve this ideal situation for a long time. +The most widely spread Operating Systems and their package managers still suffer from the described problem + +* TODO: statistics about OSs in use + +* TODO bare-metal OS installations +* TODO packages installed and run in the top OS layer +* TODO Application and dependency deployment +* TODO Pick up on explain package conflict. +* TODO Application life cycle management +* TODO explain how application containers provide an interface between the system and the application +* TODO container life cycle management + +* TODO: the thesis does not cover isolation requirements for improved security + +## Human Roles and Interaction +* TODO: operating system developer +* TODO: system administrator +* TODO: system architect +* TODO: application developer +* TODO: application packager +* TODO: interfaces and interactions + * OS configuration -> application agnostic? + * Network topology management -> isolation of networking? + +* TODO rewrite: + Typically the system administrator doesn't necessarily think about the work-flow of an application developer and vise versa. + The system architect unfortunately isn't oftentimes involved in the decision making of the administrator and application developer. + This circumstance can and eventually will lead to applications running on systems that have undergone severe workarounds to make it work at all. + The DevOps movement, which is a modern term and attempt to combine the three aforementioned three roles, has been trying to solve the described problem with tools for automatic system configuration. + +## Personal Role Experiences +I've been able to collect first-hand experience in multiple of the aforementioned roles, which allowed me to create a very broad view of use-cases and their respective requirements in which containers can be used to improve the overall situation. + +The most recent project that I want to name is called [embEDUx][embEDUx], and it aims to provide a flexible solution for creating and deploying a customized Linux distribution for embedded systems in an educational context. +My main part within that project was to design the overall architecture of the build system and to develop the specification for the system archive and the method of processing it to a complete system archive. +Additional experience in this area comes from my work on projects for customers that consulted me to advise and administer their IT small-business infrastructure. + +## Intention +* TODO: evaluate the existing build systems, their design choices and resulting features and methodologies. +The intention for customizing and adapting each one of them to make them suitable for two types of users, system administrators and application developers. + +# Design Specification +## Scope +* Package format +* Creating +* Package selection +* Post-Install commands + + +# Pre-Evaluation +* TODO: explain and mention 12-factor apps + +## Criteria +* Usability +* Correctness + +## Automated System Administration +* puppet +* chef +* ansible + +## Build Systems +* Package Mangers + * Portage + * Nix (and NixOS) +* Embedded Targeted + * embEDUx' buildrootfs routine + * baserock + * yocto + * openembedded + * buildroot +* Distribution Release tools + * Debian - https://wiki.debian.org/ReproducibleBuilds + * Nix + * ChromeOS/CoreOS SDK + * Gentoo Catalyst +* Docker related + * docker build (Dockerfile) +* ACI related + * acbuild + +## Runtimes + +* Docker +* rkt + +## Deployment + +### Nix + rkt + + +# Discussion +* Distributing +* Discovering +* Running + +# Terminology + +* Application: TODO +* Container: TODO +* Application Container: TODO +* Application Container Image: TODO +* DevOps: TODO + +# References +[embEDUx]: https://embedux.github.io/documentation diff --git a/src/docs/thesis.tex b/src/docs/thesis.tex new file mode 100644 index 0000000..6fdaf4c --- /dev/null +++ b/src/docs/thesis.tex @@ -0,0 +1,147 @@ +\documentclass[12pt,a4paper]{report} + +\usepackage[utf8]{inputenc} + +\usepackage{titlesec} % titleformat +\usepackage{blindtext,color,fancyhdr} + +\usepackage{geometry} +\geometry{a4paper, top=25mm, left=30mm, right=35mm, bottom=35mm, headsep=10mm, footskip=12mm} + +%\usepackage{multirow,tabularx,tabu} +\usepackage{ctable,multirow} + +\usepackage{cite} +\bibliographystyle{plain} + +\usepackage[hyphens]{url} +\Urlmuskip = 0mu plus 1mu + +\usepackage[numberedsection,toc,numberline,nopostdot]{glossaries} +\makenoidxglossaries + +\newcommand{\topic}{Leveraging Static Code Analysis To Improve The Memory Safety For Kernel Tasks} + +\newcommand{\authorOne}{Stefan Junker} +\newcommand{\authorOneInit}{SJ} +\newcommand{\authorOnestreet}{Alemannenstr. 7} +\newcommand{\authorOnezip}{78467} +\newcommand{\authorOnecity}{Konstanz} +\newcommand{\authorOneCountry}{Germany} +\newcommand{\authorOneId}{283751} +\newcommand{\supervisorOne}{Prof. Dr. Michael Mächtel} +\newcommand{\supervisorTwo}{?} +\newcommand{\studies}{TODO studies} +\newcommand{\startdate}{2017/3/1} +\newcommand{\submitdate}{2017/7/30} +\newcommand{\buzzwords}{TODO buzzwords} + +% Numbered Subsubsections +\setcounter{secnumdepth}{3} + +\date{Summersemester 2017} +\title{\topic} + +\author{authorOne} + +\usepackage{etoolbox} +\patchcmd{\part}{\thispagestyle{plain}}{\thispagestyle{empty}} + {}{\errmessage{Cannot patch \string\part}} + +\fancypagestyle{empty}{% + \renewcommand{\headrulewidth}{0pt} + \renewcommand{\footrulewidth}{0pt} + \fancyhf{} +} + +\fancypagestyle{front}{% + \pagenumbering{roman} + \renewcommand{\headrulewidth}{0pt} + \renewcommand{\footrulewidth}{0pt} + \fancyhf{} +} + +\fancypagestyle{preamble}{% + \pagenumbering{roman} + \renewcommand{\headrulewidth}{0pt} + \renewcommand{\footrulewidth}{0pt} + \fancyhf{} + \fancyfoot[R]{\thepage{}} +} + +\fancypagestyle{main}{% + \pagenumbering{arabic} + \renewcommand{\headrulewidth}{0.25pt} + \renewcommand{\footrulewidth}{0.25pt} + \fancyhf{} + \addtolength{\headwidth}{\marginparsep} + \headheight=15pt + \fancyhead[L]{\footnotesize\nouppercase{\leftmark}} + \fancyhead[C]{} + \fancyhead[R]{} + \fancyfoot[R]{\thepage{}} +} + +\titlespacing*{\chapter}{0cm}{-1cm}{0.75cm} +\titleformat{\chapter}[hang]{\normalfont\Large\bfseries}{\thechapter}{0.5cm}{} + +\makeatletter + +%\renewcommand\paragraph{\startsection{paragraph}{4}{\z}% +% {-3.25ex\plus -1ex \minus -.2ex}% +% {0.0001pt \plus 0.2ex}% +% {\normalfont\normalsize\bfseries}} +\renewcommand\subparagraph{\startsection{subparagraph}{5}{\z}% + {-3.25ex\plus -1ex \minus -.2ex}% + {0.0001pt \plus 0.2ex}% + {\normalfont\normalsize\bfseries}} +\makeatother +\include{glossary} + +\overfullrule=1cm + +\begin{document} + + %TODO: \include{cover} +\pagestyle{front} + \include{title} + +\pagestyle{preamble} + \include{abstract} + %TODO: \include{affidavit} + \cleardoublepage + \newcounter{roman_pagenumbers} % save page number + \setcounter{roman_pagenumbers}{\value{page}} + +\pagestyle{main} + %TODO \include{acknowledgments} + + \chapter*{Preface} + This thesis is original, unpublished, independent work by the author, \authorOne. + I strongly believe in openness and collaboration in the development of new technology, therefore the development will be based solely on Open-Source software. + The results of this project will be freely available on my personal Github site\footnote{https://github.com/steveeJ/msc-thesis} once the academic process of this project is complete. + + + \tableofcontents + + \part{Context} + + \printnoidxglossary + + \include{parts/context/context} + + \part{Research} + \label{part:research} + \include{parts/research/research} + + \part{Development} + \part{Conclusion} + + \newpage + %TODO \listofmyequations + \listoftables + %TODO \lstlistoflistings + \listoffigures + \bibliography{thesis} + +\end{document} diff --git a/src/docs/thesis.tex.latexmain b/src/docs/thesis.tex.latexmain new file mode 100644 index 0000000..e69de29 diff --git a/src/docs/title.tex b/src/docs/title.tex new file mode 100644 index 0000000..979a79c --- /dev/null +++ b/src/docs/title.tex @@ -0,0 +1,30 @@ +{ + \setlength{\parskip}{0.5cm} + \begin{center} + \textbf{\huge Master's Thesis} + + \textbf{for achieving the academic degree} + + \textbf{\Large Master of Science (M. Sc.)}\\ + [10ex] + + \textsf{\huge University Of Applied Sciences, Constance}\\ + [10ex] + + \textsf{\Large Faculty For Information Technology}\\ + Studies \studies + \end{center} +} + +\begin{center} + \vspace*{2cm} + \begin{tabular}{p{3cm}p{10cm}} + Topic: & \textbf{\large \topic} \\[10ex] + Applicant: & \authorOne, \authorOnestreet, \authorOnezip$ $ \authorOnecity, \authorOneCountry \\ + & Student Identification Number: \authorOneId\\[10ex] + 1st Supervisor: & \supervisorOne\\ + 2nd Supervisor: & \supervisorTwo\\[10ex] + Start Date: & \startdate\\ + Submit Date: & \submitdate\\ + \end{tabular} +\end{center}