<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Abraxas &#187; dar</title>
	<atom:link href="http://www.effinger.org/blog/tag/dar/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.effinger.org/blog</link>
	<description>a personal knowledge base</description>
	<lastBuildDate>Sun, 06 Jun 2010 17:41:45 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Backup eines Ubuntu-Computers mit DAR</title>
		<link>http://www.effinger.org/blog/2008/10/05/backup-eines-ubuntu-computers-mit-dar/</link>
		<comments>http://www.effinger.org/blog/2008/10/05/backup-eines-ubuntu-computers-mit-dar/#comments</comments>
		<pubDate>Sun, 05 Oct 2008 19:49:54 +0000</pubDate>
		<dc:creator>Markus Effinger</dc:creator>
				<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Backup]]></category>
		<category><![CDATA[dar]]></category>

		<guid isPermaLink="false">http://www.effinger.org/blog/?p=3</guid>
		<description><![CDATA[<p>Es gibt mittlerweile viele Anleitungen, wie man ein Backup unter Ubuntu erstellen kann.  Entweder ist deren Einrichtung jedoch sehr kompliziert oder sie benutzen das Archiv-Programm tar. Letzeres muss aber stets das ganze Archiv lesen, auch wenn man nur eine einzige Datei des Backups wiederherstellen möchte und ist daher nur eingeschränkt zu empfehlen. Deshalb verwende [...]]]></description>
			<content:encoded><![CDATA[<p>Es gibt mittlerweile viele Anleitungen, wie man ein Backup unter Ubuntu erstellen kann.  Entweder ist deren Einrichtung jedoch sehr kompliziert oder sie benutzen das Archiv-Programm tar. Letzeres muss aber stets das ganze Archiv lesen, auch wenn man nur eine einzige Datei des Backups wiederherstellen möchte und ist daher nur eingeschränkt zu empfehlen. Deshalb verwende ich mittlerweile <a href="http://dar.linux.free.fr/">DAR (Disk ARchive)</a> zum Erstellen eines Backups. Dazu gibt es mittlerweile auch eine grafische Benutzeroberfläche names <a href="http://dargui.sourceforge.net/">DarGUI</a>. Auf Sourceforge wird sogar ein Debian-Paket zur Verfügung gestellt, das sich problemlos unter Ubuntu installieren lässt. Die Anwendung findet man nach der Installation unter Anwendungen/Zubehör/DarGUI.</p>
<p>Mit Hilfe von DarGUI habe ich eine Konfigurationsdatei zum Backup meiner persönlichen Daten und eine zum Backup der restlichen Dateien erstellt.<br />
databackup.cfg:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># DAR batch file written by DarGUI</span>
<span style="color: #666666; font-style: italic;"># dar -c &quot;/backup/data_20081005&quot; -B &quot;/path/to/databackup.cfg&quot; -v -X data_20081005.*.dar</span>
<span style="color: #660033;">-R</span> <span style="color: #ff0000;">&quot;/&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Dry run: this archive will not be written to file unless the next option is removed</span>
<span style="color: #666666; font-style: italic;">#--empty</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Directories to include in archive</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;etc&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;home&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;root&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;usr/local&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;var&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Directories to exclude from archive</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;lost+found&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;proc&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;var/tmp&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;sys&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;backup&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;bin&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;boot&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;initrd&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;lib&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;opt&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;sbin&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;srv&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;usr&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;media&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;cdrom&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;dev&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Use bzip2 compression</span>
<span style="color: #660033;">--bzip2</span>=<span style="color: #000000;">6</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Do not compress these files</span>
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.zip
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.jpg
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.bz2
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.gz
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.tgz
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.gif
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.png
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.rar
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.deb
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.avi
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.mpg
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.mpeg
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.ape
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.flac
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.mp3
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.mov
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.ace
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.7z
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.mpc
&nbsp;
<span style="color: #666666; font-style: italic;"># Preserve ignored directory names</span>
<span style="color: #660033;">-D</span></pre></div></div>

<p>programsbackup.cfg:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># DAR batch file written by DarGUI</span>
<span style="color: #666666; font-style: italic;"># dar -c &quot;/backup/programs_20081005&quot; -B &quot;/path/to/programsbackup.cfg&quot; -v -X programs_20081005.*.dar</span>
<span style="color: #660033;">-R</span> <span style="color: #ff0000;">&quot;/&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Dry run: this archive will not be written to file unless the next option is removed</span>
<span style="color: #666666; font-style: italic;">#--empty</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Directories to include in archive</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;bin&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;boot&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;cdrom&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;dev&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;initrd&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;lib&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;opt&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;sbin&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;srv&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;usr&quot;</span>
<span style="color: #660033;">-g</span> <span style="color: #ff0000;">&quot;media&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Directories to exclude from archive</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;lost+found&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;proc&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;var/tmp&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;sys&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;backup&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;usr/local&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;etc&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;home&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;root&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;usr/local&quot;</span>
<span style="color: #660033;">-P</span> <span style="color: #ff0000;">&quot;var&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Use bzip2 compression</span>
<span style="color: #660033;">--bzip2</span>=<span style="color: #000000;">6</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Do not compress these files</span>
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.zip
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.jpg
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.bz2
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.gz
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.tgz
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.gif
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.png
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.rar
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.deb
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.avi
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.mpg
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.mpeg
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.ape
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.flac
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.mp3
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.mov
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.ace
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.7z
<span style="color: #660033;">-Z</span> <span style="color: #000000; font-weight: bold;">*</span>.mpc
&nbsp;
<span style="color: #666666; font-style: italic;"># Preserve ignored directory names</span>
<span style="color: #660033;">-D</span></pre></div></div>

<p>Aufgerufen werden die Dateien so:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">dar <span style="color: #660033;">-c</span> <span style="color: #ff0000;">&quot;/path/tobackup/backupfile_date&quot;</span> <span style="color: #660033;">-B</span> <span style="color: #ff0000;">&quot;/path/to/file.cfg&quot;</span> <span style="color: #660033;">-v</span> <span style="color: #660033;">-X</span> backupfile_date.<span style="color: #000000; font-weight: bold;">*</span>.dar</pre></div></div>

<p>Falls man nun Knoppix verwendet, das leider dar noch nicht standardmäßig enthält, kann man sich behelfen, indem man die aktuellste Version des Pakets <a href="http://packages.debian.org/stable/dar-static">dar-static aus den Debian Repositories</a> herunterlädt und mit</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">dpkg</span> <span style="color: #660033;">-i</span> <span style="color: #000000; font-weight: bold;">/</span>path<span style="color: #000000; font-weight: bold;">/</span>to<span style="color: #000000; font-weight: bold;">/</span>dar-static<span style="color: #000000; font-weight: bold;">*</span>.deb</pre></div></div>

<p>installiert. Aufrufen lässt sich dar dann mit &#8220;dar_static&#8221;.</p>
<p>Ein Backup lässt sich mit folgendem Befehl wieder einspielen:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> dar <span style="color: #660033;">-x</span> <span style="color: #000000; font-weight: bold;">/</span>path<span style="color: #000000; font-weight: bold;">/</span>to<span style="color: #000000; font-weight: bold;">/</span>backup.dar <span style="color: #660033;">-R</span> <span style="color: #000000; font-weight: bold;">/</span>path<span style="color: #000000; font-weight: bold;">/</span>to<span style="color: #000000; font-weight: bold;">/</span>restore</pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://www.effinger.org/blog/2008/10/05/backup-eines-ubuntu-computers-mit-dar/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
