<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
  	<atom:link href="http://unflyingobject.com/blog/rss.php" rel="self" type="application/rss+xml" />
    <title>unflyingobject.com - for the thrill of understanding</title>
  	<link>http://unflyingobject.com/blog/</link>
		<description>mac geekery</description>
		<language>en-us</language>
		<ttl>500</ttl>


	  <item>
	    <title>
  	    <![CDATA[pingraph]]>
    	</title>
   		<pubDate>Fri, 20 Aug 2010 01:41:00 +0300</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1050</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1050</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>I am troubleshooting some network issues and was trying to find an automated way to continuously monitor connectivity between a host and a server. On thing that sprang to mind was to run ping in the background, with a reasonable interval, in the hopes of perhaps narrowing down the network issues to a particular time frame. </p>

<p>This resulted a ping dump with over 30 000 "samples" which weren't that useful as such. So I wrote a little <a href="http://github.com/filipp/mtk/blob/master/pingraph.php">PHP script</a> to parse the ping output. The script (which is now part of <a href="http://github.com/filipp/mtk">MTK</a>) generates a CSV file with the first column being the timestamp and the second the ICMP ECHO delay. When I run <a href="http://www.gnuplot.info/">Gnuplot</a> on it, I get something that looks like this:</p>

<p style="text-align:center">
<img src="/tmp/pingraph_gnuplot.png" alt=""/>
</p>

<p>Which is actually pretty cool. I can see right away that during the 24 hours, the delay has never increased over 0.7 ms. There's also an interesting gap around 0.2 ms.</p>

<p>pingraph also has another "mode" of operation. If the number of samples is small (&lt;= 100), then it tells Keynote to draw the graph:</p>

<p style="text-align:center">
<img src="/tmp/pingraph_keynote.001.jpg" alt=""/>
</p>

<p>I found that anything above 100 data points chokes osascript.</p>

<p>Anyways, in a serious environment you'd probably have Nagios or some other nice tool to do this for you, but for my purposes this was good enough. Some day I'll try to add a simple method to filter the data set to specific timeframes...</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[A Script for Remote Desktop]]>
    	</title>
   		<pubDate>Wed, 18 Aug 2010 20:57:00 +0300</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1049</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1049</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>One silly feature omission in Apple Remote Desktop is the lack of a "Open SSH connection" command. To be able to open a Terminal window with a connection to the currently selected machine. Luckily we can create this ourselves pretty easily:</p>

<pre><code>tell application "Remote Desktop"
    set theIp to Internet address of selection
    set defaultUser to current user of selection
    set theUser to text returned of (display dialog "" default answer defaultUser)
    tell application "Terminal"
        activate
            do script "ssh -l " &amp; quoted form of theUser &amp; " " &amp; theIp
        end tell
end tell
</code></pre>

<p>Save that as a script with AppleScript Editor named "Open SSH connection" under ~/Library/Scripts/Applications/Remote Desktop and now you have way to do just that straight from the menu bar.</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Not Very Helpful]]>
    	</title>
   		<pubDate>Fri, 30 Jul 2010 23:38:00 +0300</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1048</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1048</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>This still cracks me up when I see it:</p>

<p style="text-align:center">
<img src="/tmp/2010073002.png" alt=""/>
</p>

<p><a href="http://whomwah.github.com/qlstephen/">this</a> makes it much more useful. Thanks to Robbie for the hint!</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Bug. Report. Can't.]]>
    	</title>
   		<pubDate>Wed, 28 Jul 2010 14:05:00 +0300</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1046</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1046</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p style="text-align:center">
<img src="/tmp/2010072701.png" alt=""/>
</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Toot That Horn!]]>
    	</title>
   		<pubDate>Wed, 23 Jun 2010 16:33:00 +0300</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1045</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1045</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>Some months ago I was helping out on a pretty big installation project. An office of about 60 Macs ,4 servers and 3 networks was basically rebuilt from scratch over the course of one weekend. One of the (many) problems we encountered was a total blackout of printing from any Apple app <em>if the user had admin rights</em>. The print dialog would come up, but the printer menu would be empty and none of the buttons would work, to the point that you had to force quit the app to cancel the print operation. One of the weirdest bugs I have ever come across.</p>

<p>After spending hours in the network closet, systematically unplugging each device to see if it had any effect on the issue, I finally found it - it was a printer who's Bonjour name was "Mörkö". The problem disappeared after renaming it to "Morko". So I filed <a href="http://openradar.appspot.com/radar?id=233401">a bug report</a>.</p>

<p>It turned out Apple saw this as a security issue and so they took it very seriously and I'm happy to report that <a href="http://support.apple.com/kb/HT4188">it's been resolved</a> in 10.6.4:</p>

<p style="text-align:center">
  <img src="/images/20100623.png" alt=""/>
</p>

<p>I think this might be the first time one of my bug reports has actually been fixed. It was really nice to see Apple take this as seriously as they did and it actually motivated me to keep reporting bugs in the future (I had kinda given up on that after all those "known issues"). Of course, having your and your <a href="http://www.mcare.fi/index_en.html">fledgling company's</a> name mentioned on apple.com never hurts either (even though probably 9 people in the world actually read the detailed contents of Security Updates). :-)</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Kannel Installer]]>
    	</title>
   		<pubDate>Mon, 21 Jun 2010 13:51:00 +0300</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1044</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1044</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p><a href="http://kannel.org/">Kannel</a> is a great platform for all things mobile. <a href="http://www.mcare.fi/index_en.html">We</a> use the SMS gateway feature with our service management system to notify customers when their machines are ready for pickup. All you basically need is a mobile phone which you can connect to your Mac via USB and Kannel.</p>

<p>Surprisingly, it's not available through MacPorts or Fink and compiling it from source has been rather tricky in the past.  Through some experimentation I found that the CVS version works better on 10.6 and was even able to build a universal binary of it. We've been running this version for months now on a Mac mini and an old Nokia phone.</p>

<p>You can download the installer <a href="/downloads/Kannel.zip">from here</a>. In addition to the application it also includes launchd jobs for <em>bearerbox</em> and <em>smsbox</em>. Check /etc/kannel.conf before loading them in. The full Kannel documentation is available <a href="http://kannel.org/download/1.3.2/userguide-1.3.2/userguide.html">here</a>.</p>

<p>I've only been able to test this with 10.6, let me know if you have problems on 10.5. One day I hope to find time to write a more detailed article on how to set this up...</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Resizing RAID Volumes]]>
    	</title>
   		<pubDate>Sat, 24 Apr 2010 12:28:00 +0300</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1042</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1042</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>First off, beware - there are two documents on apple.com, both titled "RAID Utility User Guide - Instructions for setting up RAID volumes on a computer with a Mac Pro RAID Card or Xserve RAID Card" (<a href="http://images.apple.com/server/docs/RAID_Utility_User_Guide.pdf">here</a> and <a href="http://images.apple.com/xserve/pdf/RAID_Utility_User_Guide.pdf](http://images.apple.com/xserve/pdf/RAID_Utility_User_Guide.pdf">here</a>).</p>

<p>The first was created in 2007, the second in 2009. I would assume the latter is more relevant. On page 10 of that document we find the following statement:</p>

<pre><code>Expanding a Volume
You can use the command line to expand (add space to) an existing volume from
the available space on the RAID set that hosts it.
Expanding a volume doesn’t affect data already on the volume
To expand a volume:
Open Terminal and enter the following command:
$ sudo raidutil modify volume --expand -n volume -s size
where volume is the name of the volume as shown by
the raidutil list volumeinfo command and size is the amount of space you want to add to the volume.
</code></pre>

<p>Having been tasked with reorganizing some storage in a late 2008 Xserve, I thought this is perfect - I can resize my volumes without having to format/restore the whole server. In the worst case scenario, <em>maybe</em> having to restore the boot partition, but that's fine. So, boot up the installer, Utilities > Terminal, and:</p>

<pre><code># raidutil modify volume --expand -n R1V2 -s 1.6TB
Unsupported by this version of the hardware/firmware.
</code></pre>

<p>Whatever. You kinda get used to this sorta crap dealing with Apple's servers. Of course, they don't have to explain to my users why the server upgrade's gonna take 3x more time than planned. This is the reason you should never give <em>any</em> time estimate on how long an upgrade will take - this gig just went from a few hours to an entire day, just due to this tiny detail.</p>

<p>Maybe they'll fix this some day (or just withdraw the instructions), I don't know, but it's something to be aware of, for sure.</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Seeing Double]]>
    	</title>
   		<pubDate>Sat, 10 Apr 2010 12:14:00 +0300</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1039</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1039</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>There's a bug in iCal that in some situations will show every name twice when adding attendees to an event. Adding one of them will always give an error (the oh-so-not-helpful tiny exclamation mark next to the name). iCal will still add that "ghost", but the invitation will obviously never be sent.</p>

<p>At first this looked a bit like the <a href="http://unflyingobject.com/blog/story/665">proxy bug</a>, but since this isn't about delegates, but actual user accounts (and since running proxyclean didn't find any errors) I turned my attention to Open Directory. Luckily, iCal Server 2 comes with actually helpful logging, even at Information log level, just:</p>

<pre><code>    tail -f /var/log/caldavd/error.log
</code></pre>

<p>and you'll be able to see exactly how caldavd is talking to OD. Looking at that I was able to determine that OD was actually returning all the right search results (when the user was typing a name of the attendee). But even when OD returned just 1 record, iCal would still show 2. Then I remembered seeing a button iCal > Preferences > Advanced called "Clear Attendee Cache"</p>

<p style="text-align:center">
<img src="/tmp/advanced_10.5" alt=""/>
</p>

<p>"Yes! The attendee cache! Sounds like just the thing!" - I yelled, only to find the button no longer there, in 10.6:</p>

<p style="text-align:center">
<img src="/tmp/advanced_10.6" alt=""/>
</p>

<p>Well, let's make that "button" ourselves. Fire up Remote Desktop, select the ailing machines, Click "Send UNIX command" (as the currently logged in user), and:</p>

<pre><code>    killall -m '^iCal$'
    mv ~/Library/Caches/com.apple.iCal ~/.Trash/
    open /Applications/iCal.app/
</code></pre>

<p>And voilà! Problem solved!</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Nokia Phones and Your Server]]>
    	</title>
   		<pubDate>Sat, 10 Apr 2010 11:44:00 +0300</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1038</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1038</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>If your organisation uses Nokia phones, then by default, a stock 10.6 mail server will be pretty much useless to them. Even with some fairly recent hardware (E72), the phones won't be able to send or receive any mail. Here's how to make it work:</p>

<ul>
<li>Enable PLAIN authentication for IMAP, POP and SMTP. This isn't such a big issue if you're using <a href="http://www.cheapssls.com/?from=atcssl">SSL</a>. Some Nokia's might actually do CRAM-MD5 off the bat, but sooner or later you will run into a user who can't log in.</li>
<li><p>Enable "SMTPS" support in Postfix. "SMTPS", on port 465, was a "brilliant" Microsoft idea to start using port 465 for secured SMTP connections after they apparently couldn't get Outlook 2000 to work with port 25. They just missed the fact that 465 had already been <a href="http://www.iana.org/assignments/port-numbers">assigned</a> to another protocol by <a href="http://www.iana.org/">IANA</a>. What's fine for Microsoft's fine for Nokia, unfortunately, changing the mail client on a mobile is a bit more difficult than moving your poor Outlook user to Thunderbird, so:</p>

<pre><code>sudo nano -B +30 /etc/postfix/master.cf
&lt;uncomment lines 30-33&gt; and save
sudo postfix reload
</code></pre></li>
</ul>

<p>And also don't forget to forward tcp/465 to your mail server in your <a href="http://pfsense.org/">firewall</a>.</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[They Never Use SSL?]]>
    	</title>
   		<pubDate>Thu, 25 Mar 2010 20:43:00 +0200</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1036</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1036</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>OS X Server just makes me want to smoke crack sometimes. Dealing with SSL certs is one of those cases.  At first, everything is peachy:</p>

<ol>
<li>Create your self-signed cert in Server Admin, sans passphrase</li>
<li>Have it signed by a <a href="http://www.cheapssls.com/?from=atcssl">Certificate Authority</a></li>
<li>Import the signed cert, verify that all works.</li>
</ol>

<p>Great. Now you want to install Rumpus and the WFM and use SSL for that too. First, let's try to just paste the PEM file:</p>

<pre><code># cat /etc/certificates/mycert.key.pem
-----BEGIN RSA PRIVATE KEY-----
&lt;OUTPUT REMOVED FOR BREVITY&gt;
-----END RSA PRIVATE KEY-----
</code></pre>

<p>Paste that into stunnel... and:</p>

<pre><code>Mar 25 18:50:17 mail [0x0-0x24024].com.maxum.rumpus[3144]: 2010.03.25 18:50:17 LOG3[3704:2694202624]: error stack: 140B3009 : error:140B3009:SSL routines:SSL_CTX_use_RSAPrivateKey_file:PEM lib
Mar 25 18:50:17 mail [0x0-0x24024].com.maxum.rumpus[3144]: 2010.03.25 18:50:17 LOG3[3704:2694202624]: error stack: 906A068 : error:0906A068:PEM routines:PEM_do_header:bad password read
Mar 25 18:50:17 mail [0x0-0x24024].com.maxum.rumpus[3144]: 2010.03.25 18:50:17 LOG3[3704:2694202624]: SSL_CTX_use_RSAPrivateKey_file: 906406D: error:0906406D:PEM routines:DEF_CALLBACK:problems getting password
</code></pre>

<p>Yeww. Hmm. Looks like I have to strip the passphrase. Weird, I didn't give one, but... mmkay, <a href="http://www.madboa.com/geek/openssl/#key-removepass">no biggie</a>:</p>

<pre><code># openssl rsa -in /etc/certificates/mycert.key.pem -out mykey.nopass.key
Enter pass phrase for /etc/certificates/mycert.key.pem:&lt;enter&gt;
3808:error:28069065:lib(40):UI_set_result:result too small:/SourceCache/OpenSSL098/OpenSSL098-30/src/crypto/ui/ui_lib.c:850:You must type in 4 to 1023 characters
Enter pass phrase for /etc/certificates/mycert.key.pem:&lt;enter&gt;
3808:error:28069065:lib(40):UI_set_result:result too small:/SourceCache/OpenSSL098/OpenSSL098-30/src/crypto/ui/ui_lib.c:850:You must type in 4 to 1023 characters
Enter pass phrase for /etc/certificates/mycert.key.pem:&lt;enter&gt;
3808:error:28069065:lib(40):UI_set_result:result too small:/SourceCache/OpenSSL098/OpenSSL098-30/src/crypto/ui/ui_lib.c:850:You must type in 4 to 1023 characters
</code></pre>

<p>Well, like I said - THERE IS NO PASSPHRASE!!!</p>

<p>Wait, 10.6 put something in the System Keychain... ah, there it is. Maybe I should export the key from there. Launch KA, select the key, File > Export, and:</p>

<p style="text-align:center">
  <img src="/tmp/keychain_export_error.png" alt="" />
</p>

<p>Wtf? No, wait, <a href="http://www.youtube.com/watch?v=nHJkAYdT7qo">"it was a bug, Dave"</a>. Keychain Access doesn't have permissions to export <em>anything</em> from the System keychain. Ah, yes, I remember now:</p>

<pre><code>$ sudo /Applications/Utilities/Keychain\ Access.app/Contents/MacOS/Keychain\ Access
</code></pre>

<p>... export the key and. Ah, thank you!</p>

<p>Ok, that was weird... But wait a minute - this is PKCS format, I can't use this! Back to Terminal:</p>

<pre><code>$ openssl pkcs12 -in mycert.p12 -out mycert.pem -nodes
Enter Import Password:&lt;enter&gt;
MAC verified OK
</code></pre>

<p>And finally I have something to use with Rumpus.</p>

<p>If 10.6 Server is "simpler than ever" then I can't wait for 10.7! How the hell is a "typical" OS X Server admin (a graphic designer who shares his time between the Wacom and the server closet) supposed to know all this crap? This is exactly the kind of set up a typical design firm would run - 10.6 for collaboration, file sharing and backup and Rumpus for client access.</p>

<p>... I guess they just never use SSL.</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Went Indie]]>
    	</title>
   		<pubDate>Mon, 15 Mar 2010 21:59:00 +0200</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1035</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1035</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>The reason I've been even more absent than usual is because we've started a new company.  It's called <a href="http://www.mcare.fi/index_en.html">mcare</a>. I think the "m" stands for "Mac", but who cares - it's just a name. We're an AASP that does everything an AASP should - Mac and iPod hardware repairs, upgrades, warranty repairs, data recovery, etc. as well as some light retail (Mac accessories, cables, batteries etc) and software consultation.</p>

<p style="text-align:center">
<img src="/tmp/bcard.jpg" alt="" />
</p>

<p>It's the third startup I've been involved in, but this one is very different. This one will actually fly. After a month and a half, we know it can. The biggest difference is that for the first time, we have actual employees and the company is our only source of income. This not only motivates you, but also allows you to focus much better.</p>

<p>I'll probably age six years this year, but I must say, even when things are really tough, and with some weeks constantly re-defining the meaning of mental anguish, there are moments when I feel truly happy. Career-wise, this has been major downgrade - I make about half the paycheck compared to last year, it will be a long time until I get to see anything nearly as cool as I did working for <a href="http://www.tvtools.fi/english.html">TV Tools</a> and every day I run into problems that have nothing to with my ACSA certification...</p>

<p>But I'm happy.</p>

<p>I'm happy because finally I have the opportunity to test out all those ideas about how a company should function, to have the freedom to decide what I make and what I sell. To have total ownership of what I create and to be able to share it with whoever I please. I'm happy to have the freedom to blame no-one but myself if things don't go as they should. And I'm happy to work in a place where everyone else has that same freedom. To do great work, to take risks, to make a difference and to have fun.</p>

<p>Speaking of creating, I actually do a fair bit of R&amp;D (after all, that's what it says on my business card) at mcare (we've even developed some hardware, more on that later). I've decided to open source everything that might be useful to other people in this field. The first project is <a href="http://github.com/filipp/mtk">MTK</a> - a collection of scripts for OS X and hardware testing. Our service engineers sometimes ask me to write tests and they all end up in MTK.</p>

<p>Perhaps the biggest thing we will release is <a href="http://github.com/filipp/servo">Servo</a> - a complete rewrite of the service management system I made for Humac back in 2007. I'm currently working on the API for that and hope to be releasing something in the coming months. Our other company, <a href="http://mekanisti.fi">Mekanisti</a> owns the rights to that and for a brief period we even tried to make it into a product - until we realised the value for us will always be in using, not selling the tool. More engineers than salesmen, I guess...</p>

<p>And to anyone who at some point in their life has to choose between going indie and taking a lucrative job offer - do the first thing that comes to your mind... ;-)</p>

<p>Anyways, if you're in the Helsinki area and looking for fast, friendly and professional service for your Mac, iPod or Apple accessory, please drop by!</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Keychain Access... Dancing?]]>
    	</title>
   		<pubDate>Wed, 16 Dec 2009 23:44:00 +0200</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1030</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1030</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>Keychain Access went into a weird "trance"-like state today when I tried to import a Cisco VPN certificate:</p>

<p style="text-align:center">
<object classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" width="478" height="158"
   codebase="http://www.apple.com/qtactivex/qtplugin.cab#version=6,0,2,0"
   align="middle" >
  <param name="src" value="/tmp/keychaindance.mov" />
  <param name="autoplay" value="true" />
  <embed src="/tmp/keychaindance.mov" width="478" height="158" 
    pluginspage=http://www.apple.com/quicktime/download/
    align="middle" autoplay="false" loop="true" bgcolor="#232323" > </embed>
</object>
</p>

<p>It's like it's afraid of the impending Force Quit that happened shortly after.</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Deploying Final Cut Studio]]>
    	</title>
   		<pubDate>Tue, 15 Dec 2009 18:23:00 +0200</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1027</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1027</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>I (and every other sysadmin who's had to deal with this) often bash Adobe for creating "enterprise-unfriendly" installers but when you think about it, Apple is just as bad with Final Cut Studio (i.e. "their Creative Suite"). It may come as a pkg but that doesn't mean you can automate the installation any better. The main reason seams to be that FCS packages refer to each disc using a <a href="http://www.afp548.com/forum/viewtopic.php?showtopic=21949">x-disc URL scheme</a> which <em>installer</em> seems to ignore. The result is that even if you mount all the discs, running <em>installer</em> with the main .mpkg will only install the apps and none of the additional content.</p>

<p>You can modify the .dist files, but here's an alternative approach:</p>

<ul>
<li>Create a 50 GB sparse image, name the volume "Final Cut Studio 3"</li>
<li>Enable permissions on the "Final Cut Studio 3" volume</li>
<li><p>Mount all the FCS discs, install the main package using <em>installer</em>:</p>

<pre><code>installer -verbose -pkg /Volumes/Final\ Cut\ Studio\ Install/Installer/FinalCutStudio.mpkg -taret /Volumes/Final\ Cut\ Studio\ 3
</code></pre></li>
</ul>

<p>Running the first phase through <em>installer</em> allows us to skip entering the license info.</p>

<ul>
<li>Run all the remaining installers from the individual discs, i.e. "Audio Content 1", "DVD Studio Pro Content", "Motion Content 1". In the installer click "Change Install Location..." and select the "Final Cut Studio 3" volume.</li>
<li>Create a new compressed disk image from the "Final Cut Studio 3" volume, scan for restore (only necessary if you want to do a block restore, see below).</li>
</ul>

<p>Now you have a complete FCS install as a single disk image, ready to be restored with <em>asr</em>. I've only tested this with fresh systems so YMMV, but the idea is straigtforward - we just copy all the files that come with FCS to their correct locations.</p>

<p>Since a default FCS installation is about 14 times the size of a minimal Snow Leopard install (!) it might make sense (save time) to <em>first</em> lay down FCS with a block copy (i.e. erasing the target first) and <em>then</em> restore the OS with a file copy. I tried this and it actually worked! With this method, a complete install of Final Cut Studio 2 clocks in at just under 12 minutes.</p>

<p>On an unrelated note, a minimal 10.6 install restores in 80 seconds over 1Gb Ethernet (onto a Mac Pro, using RAID 6 on the server). Probably less time most Windows PC's take to boot up. :-P</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Validating Finnish Social Security Numbers]]>
    	</title>
   		<pubDate>Tue, 15 Dec 2009 15:48:00 +0200</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1029</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1029</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>Just in case someone else needs this - here's one, fairly elegant way to validate Finnish SSN's, in JavaScript:</p>

<pre><code>/**
 * Check Finnish social security number
 * @return true if correct, false if incorrect, -1 if malformed
 */
function checkSsn(ssn)
{
  ssn = ssn.toLowerCase();
  m = ssn.match(/(\d{6})-(\d{3})(\w){1}/);

  if (!m) {
    return -1;
  }

  c = Array(); base = 35;
  n = parseInt(m[1] + m[2], 10) % 31;

  for (i = 0; i &lt; base; i++)  {
    e = parseInt(i, 10).toString(base);
    if ('gioq'.indexOf(e) &lt; 0) {
      c.push(e);
    }
  }

  return (c[n] == m[3]);

}
</code></pre>

<p>The idea is the last character in the SSN is essentially a verification code derived from all the numbers in the SSN. The specs are from the Finnish <a href="http://www.vaestorekisterikeskus.fi/vrk/home.nsf/pages/2575C011A439C3ACC22571FB00248CA2">Population Register Center</a> but unfortunately they only seem to be available in Finnish.</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Makes Sense?]]>
    	</title>
   		<pubDate>Tue, 15 Dec 2009 15:28:00 +0200</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1028</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1028</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p style="text-align:center">
<img src="/tmp/suibug.png" alt="System Image Utility Bug"/>
</p>

<p>Yeah, that's what I thought too. This happens every time I tried to create a NetRestore image using Apple's System Image Utility. Clicking "OK" just brings the same dialog back after some time.</p>

<p>This reminds me of how a customer brought me his PowerBook with the classic "Document was not saved" dialog in Excel 2004, with only one button - "OK". "No, it's not OK", he said. :-)</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Reinstalling Final Cut Server.app]]>
    	</title>
   		<pubDate>Thu, 10 Dec 2009 16:35:00 +0200</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1022</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1022</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>If you ever find yourself being unable to re-install Final Cut Server.app, then open/Applications/Utilities/Java Preferences > Network and click on the "Delete Files..."  button and re-download.</p>

<p style="text-align:center">
  <img src="/tmp/javaprefs.png" alt="Java Preferences" />
</p>

<p>I ran into this after deleting the 1.5.1 shortcut from the Desktop. Going to the .app download page just opened the .jnlp launching the app, but the shortcut was gone. Command-clicking the app in the dock just selected the java executable. This trick forces the client to re-download and also create the .app on the desktop.</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Punk Widget Update]]>
    	</title>
   		<pubDate>Sat, 14 Nov 2009 22:13:00 +0200</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1020</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1020</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>I was cleaning up log files on our web server and noticed I was getting quite a few hits on the script that acts as the backend for the <a href="http://www.macupdate.com/info.php/id/22627/punk">IMDB widget</a> that me and <a href="http://personal.inet.fi/koti/mgimpl/">Martin</a> created. Then I tried using it and noticed there were some parse errors with weird numbered lists showing up after a search result. I guess IMDB had tweaked their layout again.</p>

<p>Anyways, the script's been fixed now. No need to update the actual widget since that acts simply as the UI. Enjoy! ;-)</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[Relocating SUS on 10.6 server]]>
    	</title>
   		<pubDate>Wed, 11 Nov 2009 10:29:00 +0200</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1018</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1018</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p>This might actually be in the new documentation, I haven't checked, but when you <em>rsync</em> your SUS catalog to another volume and set it to use it, you will see a similar error in the logs:</p>

<pre><code>Symbolic link not allowed or link target not accessible /Volumes/data/SoftwareUpdate/html/index.sucatalog
</code></pre>

<p>This will probably only happen if you remove the original <em>swupd</em> datastore. The fix is to clear out all the index files:</p>

<pre><code>serveradmin stop softwareupdate
rm -rf /Volumes/data/SoftwareUpdate/html/index*
serveradmin start softwareupdate
</code></pre>

<p>IIRC, this wasn't necessary in 10.5, but I might be wrong...</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[BatchDMG]]>
    	</title>
   		<pubDate>Thu, 22 Oct 2009 01:33:00 +0300</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1016</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1016</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p><a href="http://github.com/filipp/BatchDMG/">BatchDMG</a> is a handy utility for times when you have to image large collections of disks (like installation media etc). Just run it (as root, to avoid an authentication dialog) and start feeding your machine with media.</p>

<p>The imaging starts automatically when a volume is mounted. Should also work with multiple DVD drives. The images are bzip compressed (UDBZ, need 10.4 or later to open) and are named after the volume name. It ejects the media once the imaging has completed.</p>

<p>Should work with 10.5 or later (uses PyObjC).</p>
]]>
			</description>
		</item>


	  <item>
	    <title>
  	    <![CDATA[MediaRelay]]>
    	</title>
   		<pubDate>Tue, 20 Oct 2009 17:56:00 +0300</pubDate>
	   	<link>http://unflyingobject.com/blog/posts/1015</link>
  	 	<guid>http://unflyingobject.com/blog/posts/1015</guid>
			<author>filipp@lepalaan.org (Filipp Lepalaan)</author>
			<description>
				<![CDATA[<p><a href="http://github.com/filipp/MediaRelay">MediaRelay</a> is a little Python tool I wrote that transfers new items from one FTP server to another. It can be useful when combined with a timer or possibly a folder action.</p>

<p>To use it, just modify <em>config.yaml</em>. Multiple sources and destinations can be defined under their own "name". Anonymous connections haven't been tested, but should be in the form ":@server/path".</p>

<pre><code>$ python relay.py 
-- checking default
&lt;- getting Untitled_2.wmv
-&gt; sending Untitled_2.wmv
</code></pre>

<p>The skiplist is stored in $CWD/.skiplist. Remove it to do a full transfer. The files are always relayed through the local machine (not sent from server to server) which is not terribly efficient but sometimes the only option. Folders are not trasfered - they throw an exception and are skipped on the next run.</p>
]]>
			</description>
		</item>


  </channel>
</rss>
