<?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>Ronald! &#187; Ubuntu</title>
	<atom:link href="http://www.rchu.nl/tag/ubuntu/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.rchu.nl</link>
	<description>My own little corner of the world wide web</description>
	<lastBuildDate>Mon, 06 Feb 2012 20:00:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>My Ubuntu AFP server and the 1.5TB of Doom</title>
		<link>http://www.rchu.nl/2009/12/my-ubuntu-afp-server-and-the-1-5tb-of-doom/</link>
		<comments>http://www.rchu.nl/2009/12/my-ubuntu-afp-server-and-the-1-5tb-of-doom/#comments</comments>
		<pubDate>Wed, 16 Dec 2009 08:04:13 +0000</pubDate>
		<dc:creator>ronald</dc:creator>
				<category><![CDATA[Computing]]></category>
		<category><![CDATA[General]]></category>
		<category><![CDATA[AFP]]></category>
		<category><![CDATA[Time Machine]]></category>
		<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://www.rchu.nl/?p=407</guid>
		<description><![CDATA[The bad part about my girlfriend moving in with me is that my friend who was living with me left and took our local sever with him. We had combined our spare hardware to build us a server and used his old computer because he had 4 ATA controllers and I had only 2. So <a href='http://www.rchu.nl/2009/12/my-ubuntu-afp-server-and-the-1-5tb-of-doom/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.rchu.nl/wordpress/wp-content/uploads/hdd3.JPG"><img class="size-medium wp-image-436 alignright" title="Hard Disk" src="http://www.rchu.nl/wordpress/wp-content/uploads/hdd3-300x225.jpg" alt="Hard Disk" width="300" height="225" /></a></p>
<p>The bad part about my girlfriend moving in with me is that my friend who was living with me left and took our local sever with him. We had combined our spare hardware to build us a server and used his old computer because he had 4 ATA controllers and I had only 2. So now I had to configure my old PC to create a new server (&#8217;cause you just can&#8217;t live without one of those :) and bought an extra 1.5TB hard disk. That caused quite some trouble. Since the first wasn&#8217;t properly detected by my onboard SATA controller I returned it and the replacement seemed to work, only to be mounted as read-only after formatting it. After a while the disk wasn&#8217;t properly detected at all. I was surprised with two new disks having the exact same problem, fortunately so was the owner of the web shop where I bought it. He actually called me personally to discuss the situation and concluded that my SATA controller was probably to old to work properly with this big modern disk. So I bought an PCI eSATA controller which solved my problems.</p>
<p>Last weekend I took this card to my friend who also bought a new hard disk and was experiencing similar problems. After I put the card back my big disk wouldn&#8217;t mount anymore, though it worked fine when I booted the Ubuntu Live CD. Long story short (live cd: works, reinstall ubuntu: works, dist-upgrade: broken, reinstall: works, reboot: broken) there we suddenly some errors in the FS which fsck managed to fix.</p>
<p>Anyway, most of you aren&#8217;t at all interested in the above snipped of my life and want some technical information. Which you are going to get in the remaining part of this post. Hey, the benefit of people blogging technical stuff on their personal blog is that you have to read through the irrelevant stuff. Nothing is perfect, right?</p>
<p><span id="more-407"></span></p>
<h2>Setting up ubuntu as an file server</h2>
<p>I followed a<a href="http://www.kremalicious.com/2008/06/ubuntu-as-mac-file-server-and-time-machine-volume/"> great tutorial</a> to set up AFP on my server which was very easy and everything works like a charm. Well, almost everything.</p>
<h3>Permissions</h3>
<p>Since there are two users connecting to the machine there are files created by both that also need to be accessed by both users. Setting the setgid bit on the shares directories and adding both users to a common group is a start, unfortunately there doesn&#8217;t seem to be a way to set the umask for newly created files using netatalk, so in order for other users to be able to write/delete these files I just add the group write permission with a hourly cron job. It&#8217;s ugly, but it does the job.</p>
<h3>Time Machine</h3>
<p>After a short time of backing up with Time Machine I got the infamous <a href="http://discussions.apple.com/thread.jspa?threadID=2142747">error 109</a>.  Since this issue seems to have no solution and chances are slim Apple will do something about it since it they do not support it I decided to make only manual backups at night so they can run uninterrupted, and make backups of my time machine sparsebundle in case the backup gets broken. Yes, that does sound kind of redundant. It&#8217;s far from ideal, but a workable situation. I don&#8217;t need hourly backups anyway, I just want to have something in case of a hard disk crash or something like that.</p>
<p>Yesterday I read that <a href="http://netatalk.sourceforge.net/2.0/ReleaseNotes.html">netatalk 2.0.5 adds time machine support</a>! Since the current version of netatalk in the ubuntu repo is still 2.0.4 I removed it and downloaded the <a href="http://packages.debian.org/sid/netatalk">netatalk-2.0.5-2</a> (and <a href="http://packages.debian.org/sid/libdb4.8">libdb4.8</a> which it depends on and is also not yet in the ubuntu repo) packages from the debian site and installed them with <code>dpkg</code>. This was all much easier than I expected since people on the web were warning others that this is not the proper way to go and everything might get broken and so on. After some initial errors (removing the <code>.AppleDB</code> directories after error -5014 and removing the old sparsebundle as root after error 109 on an partially removed sparsebundle) it now seems to work just fine.</p>
<p>Interesting to note is that with this new time machine support I indeed do not have to create the sparsebundle by hand and that it is now named <code>Granny.sparsebundle</code> (Granny is my laptops name) without the MAC adres. Also interesting is that TM started to continue backing up in a copy of an old backup I made by hand named <code>Granny_macadres.copy.sparsebundle</code>. Apparently the name of the backup is much more flexible nowadays.</p>
<p>Now I&#8217;m just going to make backups wireless hourly without paying attention to it (and thus interrupting it when putting my laptop to sleep) as I used to with my old Time Capsule and see if the new version of netatalk solves the problems I had. For now I&#8217;ve interrupted the initial backup several times now and it is still running (and continuing every time where it was interrupted). So far so good, I can at least say that it works more reliable than with the previous version of netatalk.</p>
<p><strong>Update:</strong> after some initial success backing up to this AFP share is as unreliable as is was before, still getting a lot of 109 errors. Too bad. I decided to just buy an external USB/eSATA case and put the disk in that. It not expensive and works for sure, though I am deeply unhappy with the situation.</p>
<p class='fb-like'><iframe src='http://www.facebook.com/plugins/like.php?href=http://www.rchu.nl/2009/12/my-ubuntu-afp-server-and-the-1-5tb-of-doom/&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light' scrolling='no' frameborder='0' allowTransparency='true' style='border:none; overflow:hidden; width:450px; height:65px'></iframe></p>]]></content:encoded>
			<wfw:commentRss>http://www.rchu.nl/2009/12/my-ubuntu-afp-server-and-the-1-5tb-of-doom/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

