From 1d13e674d7be4bf9aa69139deac6737bf60af17b Mon Sep 17 00:00:00 2001
From: Manuel Traut <manut@linutronix.de>
Date: Wed, 1 Jul 2015 16:12:36 +0200
Subject: rework elbe training stuff to match current elbe

also delete presentations that are completely outdated
and rename presentations to better identify their content

Signed-off-by: Manuel Traut <manut@linutronix.de>
---
 .../elbe-commands/pres_elbe-commands_en.tex        | 257 +++++++++++++++++++++
 1 file changed, 257 insertions(+)
 create mode 100644 distribution/elbe-commands/pres_elbe-commands_en.tex

(limited to 'distribution/elbe-commands/pres_elbe-commands_en.tex')

diff --git a/distribution/elbe-commands/pres_elbe-commands_en.tex b/distribution/elbe-commands/pres_elbe-commands_en.tex
new file mode 100644
index 0000000..4a91e4f
--- /dev/null
+++ b/distribution/elbe-commands/pres_elbe-commands_en.tex
@@ -0,0 +1,257 @@
+\input{configpres}
+
+\title{ELBE - subcommands}
+\maketitle
+
+\subsection{ELBE commands}
+
+\begin{frame}
+\frametitle{Documentation}
+\begin{itemize}
+\item Have a look at /usr/share/doc/elbe/
+\item Please read /usr/share/doc/elbe/elbeoverview-en.html
+\item There are man pages e.g. 'man elbe', 'man elbe-control', \dots
+\end{itemize}
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{create project}
+Create a new project:
+\begin{verbatim}
+$ elbe initvm create \
+	--directory /home/user/elbe-initvm
+\end{verbatim}
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{attach/start initvm}
+attach to running vm:
+\begin{verbatim}
+$ elbe initvm attach
+\end{verbatim}
+start the vm (e.g. after host PC reboot):
+\begin{verbatim}
+$ cd /home/user/elbe-initvm
+$ elbe initvm start
+\end{verbatim}
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{start build}
+\begin{verbatim}
+$ cp /usr/share/doc/elbe-doc/examples/bbb-jessie.xml.gz .
+$ gunzip bbb-jessie.xml.gz
+$ elbe initvm submit --build-bin --build-sources bbb-jessie.xml
+Build started, waiting till it finishes
+project still busy, waiting
+project still busy, waiting
+...
+\end{verbatim}
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{generated files}
+\begin{verbatim}
+$ ls elbe-build-$DATE
+bin-cdrom.iso
+elbe-report.txt
+log.txt
+licence.txt
+sdcard.img
+source.xml
+src-cdrom.iso
+validation.txt
+\end{verbatim}
+\end{frame}
+
+\begin{frame}
+\frametitle{bin-cdrom.iso}
+\begin{itemize}
+\item ISO image that contains all used binary debian packages
+\item it is only created if the --build-bin switch was provided at elbe initvm submit
+\item a rebuild of the initvm and target image can be done with this cdrom and
+	without a connection to a debian repository.
+\end{itemize}
+\end{frame}
+
+\begin{frame}
+\frametitle{elbe-report.txt}
+\begin{itemize}
+\item elbe report containing informations about used packages, finetuning, etc
+\item 'asciidoc elbe-report.txt' generates a html file
+\end{itemize}
+\end{frame}
+
+\begin{frame}
+\frametitle{log.txt}
+\begin{itemize}
+\item logfile from the image build process in asciidoc format
+\item 'asciidoc log.txt' generates a html file
+\end{itemize}
+\end{frame}
+
+\begin{frame}
+\frametitle{licence.txt}
+\begin{itemize}
+\item contains the licence text of all used debian packages
+\end{itemize}
+\end{frame}
+
+\begin{frame}
+\frametitle{sdcard.img}
+\begin{itemize}
+\item Images or archives containing the target RFS
+\item The 'target' section in the XML file describes which image and archive
+  files are created; the 'fstab' section describes their content.
+\end{itemize}
+\end{frame}
+
+\begin{frame}
+\frametitle{source.xml}
+\begin{itemize}
+\item based on the XML file given to 'elbe create'
+\item added a 'fullpkgs' section containing informations about all installed
+  packages and their version
+\item added a 'sources\_list' section that contains the used mirrors
+\item added a 'apt\_prefs' section that contains the pinning settings
+\item added a 'elbe\_version' section that contains the version number of
+  the elbe tool that generated the file
+\end{itemize}
+\end{frame}
+
+\begin{frame}
+\frametitle{src-cdrom.iso}
+\begin{itemize}
+\item ISO image that contains all used source debian packages
+\item it is only created if the --build-source switch was provided at elbe initvm submit
+\end{itemize}
+\end{frame}
+
+\begin{frame}
+\frametitle{validation.txt}
+\begin{itemize}
+\item if elbe create was called with a XML file containing a 'fullpkgs' section
+  the file contains informations if a package version differs
+\item if a package in the 'pkg-list' was not found on one of the mirrors this
+  will be logged in this file
+\end{itemize}
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{elbe-setsel usage}
+\begin{enumerate}
+\item Create package list:
+\begin{verbatim}
+# remove all pkgs not wanted on the target
+target$ dpkg --purge vim-nox libxml2-dev
+# export installed package list
+target$ dpkg --get-selections > selections.list
+# copy list to hostpc
+target$ scp selections.list YOURPC:/tmp
+\end{verbatim}
+\item Import the package list to your xml file:
+\begin{verbatim}
+hostpc$ elbe setsel rfs.xml /tmp/selections.list
+\end{verbatim}
+\end{enumerate}
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{initvm and target image build from a binary CDROM}
+\begin{verbatim}
+$ elbe initvm create --directory=elbe-from-cd \
+    elbe/elbe-build-$DATE/bin-cdrom.iso
+\end{verbatim}
+This command builds an initvm and the target image without using 'http'
+repositories.
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{elbe-chg\_archive}
+It is possible to include an archive into the xml file, that is unpacked into
+the target RFS before and after the finetuning step:
+\begin{verbatim}
+$ mkdir archive/testd
+$ cd archive
+$ echo 'port = 1234' > archive/testd/myconfig
+$ sudo tar cjf ../archive.tar.bz2 *
+$ cd ..
+$ elbe chg_archive <xmlfile> archive.tar.bz2
+\end{verbatim}
+NOTE: The file must be a bzip2 compressed tar (.tar.bz2)
+
+Take care on access right and owners of the files.
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{elbe-get\_archive}
+It is also possible to extract an archive from an XML file:
+\begin{verbatim}
+$ elbe get_archive <xmlfile> <archive>
+\end{verbatim}
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{elbe-show}
+The elbe show command prints out some textual information about an
+ELBE xml file:
+\begin{verbatim}
+$ elbe show --verbose arm-example.xml
+== arm-example.xml: ARMexample - version 08.15 ==
+Debian suite: wheezy/armel
+[...]
+\end{verbatim}
+The '--verbose' parameter shows more informations, like the complete package
+list.
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{elbe-checkupdates}
+Use a source.xml file to check if there are updates available for an existing
+image:
+\begin{verbatim}
+$ elbe check_updates source.xml
+checking /home/user/rfs/build-release/source.xml
+armel
+Reading package lists... Done
+Building dependency tree... Done
+Reading package lists... Done
+Building dependency tree... Done
+adduser 3.113+nmu1 != 3.113+nmu3
+1 updates required
+\end{verbatim}
+This can be used e.g. as cronjob to get notifications if updates are availabe.
+
+Than the person responsible for updates can decide what needs to be done.
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{elbe-diff}
+compares to RFS trees and suggests commands to update the archive tar and a
+'finetuning' section:
+\begin{verbatim}
+$ sudo elbe diff rfs rfs-modified
+suggesting:
+
+<rm>/etc/init.d/mountall-bootclean.sh</rm>
+<rm>/etc/init.d/bootmisc.sh</rm>
+tar rf archive.tar -C build/rfs /sbin/dhclient-script
+tar rf archive.tar -C build/rfs /etc/init.d/mountfstab.sh
+\end{verbatim}
+This can be used if a (nfsroot) filesystem was modified and these modifications
+should be included in an ELBE XML file.
+\end{frame}
+
+\begin{frame}[fragile]
+\frametitle{elbe-pkgdiff}
+compares to RFS trees and displays the difference of the installed packages
+\begin{verbatim}
+$ sudo elbe pkgdiff `pwd`/rfs `pwd`/rfs-modified
+-<pkg>firmware-ivtv</pkg>
+-<pkg>firmware-ipw2x00</pkg>
+\end{verbatim}
+This can be used if a (nfsroot) filesystem was modified and these modifications
+should be included in an ELBE XML file.
+\end{frame}
+
+\input{tailpres}
-- 
cgit v1.2.3

