<?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>cenolan.com &#187; Fedora 10</title>
	<atom:link href="http://www.cenolan.com/category/linux/fedora-10/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.cenolan.com</link>
	<description>What you looking at?</description>
	<lastBuildDate>Sun, 14 Jun 2009 20:03:23 +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>Simple time lapse video in Linux</title>
		<link>http://www.cenolan.com/2009/05/simple-time-lapse-video-in-linux/</link>
		<comments>http://www.cenolan.com/2009/05/simple-time-lapse-video-in-linux/#comments</comments>
		<pubDate>Sun, 10 May 2009 16:24:37 +0000</pubDate>
		<dc:creator>Chris</dc:creator>
				<category><![CDATA[Fedora 10]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[HowTo]]></category>
		<category><![CDATA[stop-motion]]></category>
		<category><![CDATA[timelapse]]></category>
		<category><![CDATA[Video]]></category>
		<category><![CDATA[webcam]]></category>

		<guid isPermaLink="false">http://www.cenolan.com/?p=104</guid>
		<description><![CDATA[Time lapse (or stop-motion) video is really cool, and this post explains how to make a simple time lapse style video in Linux using entirely free open source software. 
There is more than one way to skin a cat and when I was searching for how to do this I came across many different methods [...]]]></description>
			<content:encoded><![CDATA[<p>Time lapse (or stop-motion) video is <a href="http://www.youtube.com/watch?v=qBjLW5_dGAM">really cool</a>, and this post explains how to make a simple time lapse style video in Linux using entirely free open source software. </p>
<p>There is more than one way to skin a cat and when I was searching for how to do this I came across many different methods and suggestions but not really anything that suited what I wanted. Andrew Wells suggests <a href="http://wp.pr0gr4mm3r.com/linux/how-to-create-a-time-lapse-video-using-ffmpeg/">making a movie and then processing it with ffmpeg</a> to only store 1 in every n frames. That seems a neat solution but I wanted to take a series of still shots and string those together into a movie. Tim Nugent published a teaser of some nice looking <a href="http://ultrawide.wordpress.com/2009/01/27/timelapse-photography-on-linux/">time lapse software</a> he wrote but as yet there is no published source or binary. There were <a href="http://www.linux.com/feature/127059">various</a> other <a href="http://www.ludumdare.com/compo/2008/08/09/no-love-linux-timelapse-howto/">suggestions</a> dotted around the web but each one I tried had <a href="http://forums.fedoraforum.org/showthread.php?p=1211408">some problem</a> or other. So here's how I did it.</p>
<p><span id="more-104"></span></p>
<p>First of all, you need a working webcam. Webcam support has really improved recently in Linux and I found the built-in iSight on my MacBook and my cheapo Logitech USB webcam work just fine without any intervention from me. </p>
<p>Next we need some way to save an image from the webcam every x seconds. I found that <a href="http://www.smcc.demon.nl/camstream/index.html">camstream</a> does the trick just fine despite it's sucky 1996-looking website and lack of a release since 2006. Under Fedora 10 to install camstream just use yum or your favourite GUI package manager:</p>
<pre><code>yum install camstream</code></pre>
<p>Camstream is pretty easy to use. Really, a child could do it. Just use the "File" menu to open up your webcam device. Then click the little configuration icon (it looks like a spanner) to adjust the file settings you'd like to use for capture. I found that JPG images work much better than PNG. </p>
<p>As the "Basename" enter the <em>full path</em> of the filename you'd like to save your images as, for example if you want to save your images as "/home/yourname/Pictures/Webcam/MyTimeLapse/image001.jpg" (and so on) then set the basename as "/home/yourname/Pictures/Webcam/MyTimeLapse/image" then choose "Number sequence" and set the maximum sequence number to something pretty big (like 100000). Close the settings. Click the icon to "show last snapshot". </p>
<p>Now click "take snapshot at regular intervals" and set your interval. I chose 3 seconds. Choose whatever you think is appropriate. Now you're all set. Camstream will take images at the interval chosen and save them into the directory you configured. Sweeeeet.</p>
<p>Ok, so now we have a directory full of images that looks something like this:</p>
<pre><code>$ ls
image000.jpg  image003.jpg  image006.jpg  image009.jpg  image012.jpg  image015.jpg  image018.jpg
image001.jpg  image004.jpg  image007.jpg  image010.jpg  image013.jpg  image016.jpg
image002.jpg  image005.jpg  image008.jpg  image011.jpg  image014.jpg  image017.jpg</code></pre>
<p>We're gonna feed these files to mencoder for it to pull together into a movie. To do this we need a text file containing a list of the files in the order that we want them. You could write this file yourself (boring) but we can create it using something like this:</p>
<p>ls -1tr > files.txt </p>
<p>This provides a listing (ls) of the current working directory outputting 1 file per line (1) sorted by modification time (t) in reverse order (r) and sends the output (>) to a file named files.txt. In the example above my files.txt looks like this:</p>
<pre><code>image000.jpg
image001.jpg
image002.jpg
image003.jpg
image004.jpg
image005.jpg
image006.jpg
image007.jpg
image008.jpg
image009.jpg
image010.jpg
image011.jpg
image012.jpg
image013.jpg
image014.jpg
image015.jpg
image016.jpg
image017.jpg
image018.jpg</code></pre>
<p>Now download and install <a href="http://www.mplayerhq.hu/">mencoder</a>. Again it's available on nearly all modern distros. For Fedora 10 just do "yum install mencoder". Now all we need do to make our move is issue a command like this:</p>
<pre><code>mencoder -nosound -ovc lavc -lavcopts vcodec=mpeg4 -o test.avi -mf type=jpeg:fps=20 mf://@files.txt</code></pre>
<p>This will encode all the files listed in files.txt into a movie called test.avi using the mpeg4 encoder with no sound and a framerate of 20 frames per second. Messing with the fps gives very different results. See "<a href="http://www.mplayerhq.hu/DOCS/HTML/en/menc-feat-enc-images.html">Encoding from multiple input image files</a>" in the mencoder documentation for more info.</p>
<p>Here's an example video made using this method:</p>
<p><object width="425" height="344"><param name="movie" value="http://www.youtube.com/v/c6nk64D584s&#038;hl=en&#038;fs=1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/c6nk64D584s&#038;hl=en&#038;fs=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"></embed></object></p>
]]></content:encoded>
			<wfw:commentRss>http://www.cenolan.com/2009/05/simple-time-lapse-video-in-linux/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>How-To: Automated incremental daily backups to Amazon S3 using Duplicity</title>
		<link>http://www.cenolan.com/2008/12/how-to-incremental-daily-backups-amazon-s3-duplicity/</link>
		<comments>http://www.cenolan.com/2008/12/how-to-incremental-daily-backups-amazon-s3-duplicity/#comments</comments>
		<pubDate>Sat, 06 Dec 2008 16:58:30 +0000</pubDate>
		<dc:creator>Chris</dc:creator>
				<category><![CDATA[CentOS 5.x]]></category>
		<category><![CDATA[Fedora 10]]></category>
		<category><![CDATA[Fedora 8]]></category>
		<category><![CDATA[Fedora 9]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Mac OS X]]></category>
		<category><![CDATA[Yellow Dog Linux]]></category>
		<category><![CDATA[Amazon S3]]></category>
		<category><![CDATA[backup]]></category>
		<category><![CDATA[duplicity]]></category>

		<guid isPermaLink="false">http://www.cenolan.com/?p=54</guid>
		<description><![CDATA[This guide shows how to use Amazon S3 with duplicity to make secure GPG encrypted automated daily incremental backups (snapshots) of a Linux server or desktop. I have been using this method on various servers for several months and it has proved to be a reliable, secure, cheap, and robust method to create automated backups.
I [...]]]></description>
			<content:encoded><![CDATA[<p>This guide shows how to use <a href="http://aws.amazon.com/s3/">Amazon S3</a> with <a href="http://duplicity.nongnu.org/">duplicity</a> to make secure GPG encrypted automated daily incremental backups (snapshots) of a Linux server or desktop. I have been using this method on various servers for several months and it has proved to be a reliable, secure, cheap, and robust method to create automated backups.</p>
<p>I have used this method on <a href="http://fedoraproject.org/">Fedora</a>, <a href="http://us.fixstars.com/products/ydl/">YDL</a>, and <a href="http://www.centos.org/">CentOS</a> but the instructions should equally apply to other Linux distributions including <a href="http://www.debian.org/">Debian</a> and <a href="http://www.ubuntu.com/">Ubuntu</a>. It will even work on OS X using the <a href="http://www.macports.org/">MacPorts</a> version of duplicity.</p>
<h3 id="toc-aims-of-this-guide">Aims of this guide</h3>
<p>This guide explains how to create a simple wrapper script for duplicity that allows you to automatically create GPG encrypted incremental backups that are saved to an Amazon S3 bucket. The script is designed to be executed as a daily cron job so that incremental snapshot backups are created each day. The script creates a full backup set on the 1st day of each month (or when an appropriate full backup cannot be found) and then creates incremental backups on subsequent days. </p>
<p>This guide provides a walk-through of how to create the GPG encryption key, and provides full scripts and example usage for both backup and restore. You could easily adapt the backup script so that it makes full backups each week, or otherwise adjust it to suit your individual needs.</p>
<p>This guide is written with the general Linux user in mind: you do need some understanding of basic linux concepts such as cron, permissions, and directory structures.</p>
<p><span id="more-54"></span></p>
<h3 id="toc-what-is-duplicity">What is duplicity?</h3>
<p>From the duplicity home page:</p>
<blockquote><p>Duplicity backs [up] directories by producing encrypted tar-format volumes and uploading them to a remote or local file server. Because duplicity uses librsync, the incremental archives are space efficient and only record the parts of files that have changed since the last backup. Because duplicity uses GnuPG to encrypt and/or sign these archives, they will be safe from spying and/or modification by the server.</p></blockquote>
<p>I think that says it all much more concisely than I could manage.</p>
<p>One thing to note is that in my experience, and on certain machines, duplicity can cause a lot of overhead and take a long time to complete. Thus duplicity is not always a viable option when backing up huge amounts of data. That said, for backing up the critical data from a standard web server it can be a great solution. Remember, that if you're backing up databases then you need to dump them into SQL files first. For MySQL databases I recommend <a href="http://sourceforge.net/projects/automysqlbackup/">automysqlbackup</a> for this. As always, YMMV.</p>
<h3 id="toc-before-we-start">Before we start</h3>
<p>You need to install duplicity (version &gt;= 0.4.3 for S3 support). This how-to doesn't cover that aspect, but suffice to say that duplicity is available as a package for most major distros so crack open your package manager (be it yum, apt, synaptics or whatever) and install duplicity along with all it's dependencies. </p>
<p>You also need GnuGP and librsync but they should both be automatically installed as dependencies of duplicity.</p>
<h3 id="toc-step-1-generate-a-new-gpg-key">Step 1 - Generate a new GPG key</h3>
<p>If you already have a GPG key that you want to use then skip this bit - you'll just need to know what your key is which you can get through "gpg --list-keys" - it is the bit after the / in the "pub" line. Otherwise, read on...</p>
<p>I am going to presume that you'll be running your backup jobs as root, so open a terminal and become root. If you're going to run them as a different user then become that user instead but ensure that the user you have chosen has sufficient permissions to backup the data you require.</p>
<p>Now run "gpg --gen-key" to generate your key and follow the prompts:</p>
<pre><code># gpg --gen-key
gpg (GnuPG) 1.4.9; Copyright (C) 2008 Free Software Foundation, Inc.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Please select what kind of key you want:
   (1) DSA and Elgamal (default)
   (2) DSA (sign only)
   (5) RSA (sign only)
Your selection?
</code></pre>
<p>Accept the default (Enter) or press 1 for DSA and Elgamal.</p>
<pre><code>DSA keypair will have 1024 bits.
ELG-E keys may be between 1024 and 4096 bits long.
What keysize do you want? (2048) </code></pre>
<p>Again, the default (2048) is fine. Just hit Enter.</p>
<pre><code>Requested keysize is 2048 bits
Please specify how long the key should be valid.
         0 = key does not expire
      &lt;n&gt;  = key expires in n days
      &lt;n&gt;w = key expires in n weeks
      &lt;n&gt;m = key expires in n months
      &lt;n&gt;y = key expires in n years
Key is valid for? (0) </code></pre>
<p>I don't want my key to expire, so I just hit Enter again to accept the default. Do whatever you want.</p>
<pre><code>Key does not expire at all
Is this correct? (y/N) </code></pre>
<p>Sure is. Hit y and then Enter.</p>
<pre><code>You need a user ID to identify your key; the software constructs the user ID
from the Real Name, Comment and Email Address in this form:
    "Heinrich Heine (Der Dichter) &lt;heinrichh@duesseldorf.de&gt;"

Real name: Duplicity Backup
Email address: duplicity@mydomain.com
Comment: Key for duplicity
You selected this USER-ID:
    "Duplicity Backup (Key for duplicity) &lt;duplicity@mydomain.com&gt;"

Change (N)ame, (C)omment, (E)mail or (O)kay/(Q)uit?</code></pre>
<p>Enter the requested details and then press O for Okay.</p>
<pre><code>You need a Passphrase to protect your secret key.

Enter Passphrase:</code></pre>
<p>Enter a passphrase here. It should be something long and complex. Anything will do, but make sure you remember it because you'll need it later. When finished press Enter and then re-enter your passphrase when prompted and then press Enter again.</p>
<p>At this stage you may have to help generate some entropy by doing some other task - I find that running "updatedb" in another shell is pretty good, or just randomly tapping the keyboard can do the trick too.</p>
<p>Once it has finished you should get a message like this:</p>
<pre><code>gpg: key BE9274BD marked as ultimately trusted
public and secret key created and signed.

gpg: checking the trustdb
gpg: 3 marginal(s) needed, 1 complete(s) needed, PGP trust model
gpg: depth: 0  valid:   1  signed:   0  trust: 0-, 0q, 0n, 0m, 0f, 1u
pub   1024D/BE9274BD 2008-11-30
      Key fingerprint = 2FB4 A20E 57BA 80BA 9576  3ABD F79F D430 BE92 74BD
uid                  Duplicity Backup (Key for duplicity) &lt;duplicity@mydomain.com&gt;
sub   2048g/F8F35AD8 2008-11-30</code></pre>
<p>Make a note of the key (BE9274BD in this case) as you'll need that later too.</p>
<p><strong><em>Important: Remember to backup your GPG key pair somewhere safe and off the current machine. Without this key pair your backups are totally useless to you, so if you lose it and need to restore a backup then you're up a creak without a paddle. <a href="http://www.debuntu.org/how-to-import-export-gpg-key-pair">This article</a> shows the proper way to export (and import) your GPG key pair.</em></strong></p>
<h3 id="toc-step-2-the-backup-wrapper-script">Step 2 - The backup wrapper script</h3>
<p>This bash wrapper script does a full backup on the 1st day of each month followed by incremental backups on subsequent days. It will also delete old backup sets after X months have passed and it also emails a log report each day giving some valuable statistics about your backup and reporting any errors.</p>
<p>You will need to have the following information handy to edit this backup script for your needs:</p>
<ul>
<li>Your Amazon S3 Access Key ID</li>
<li>Your Amazon S3 Secret Access Key</li>
<li>Your GPG key</li>
<li>Your GPG key passphrase</li>
<li>A list of directories you want to back up</li>
<li>An email address to send the logs to</li>
<li>A unique name for an Amazon S3 bucket (the bucket will be created if it doesn't yet exist)</li>
</ul>
<p>The script is as follows, you need to change the bits in bold at least but pay attention to all the variables as you may want to tweak them to suit your needs.</p>
<p>Note that includes/excludes work on a 'fist match' basis. So if you want to exclude something in a directory, you need to exclude the file/subdirectory before including the directory. For more info see the duplicity man pages.</p>
<pre><code>#!/bin/bash

# Set up some variables for logging
LOGFILE="/var/log/backup.log"
DAILYLOGFILE="/var/log/backup.daily.log"
HOST=`hostname`
DATE=`date +%Y-%m-%d`
MAILADDR="<strong>sysadmin@mydomain.com</strong>"

# Clear the old daily log file
cat /dev/null &gt; ${DAILYLOGFILE}

# Trace function for logging, don't change this
trace () {
        stamp=`date +%Y-%m-%d_%H:%M:%S`
        echo "$stamp: $*" &gt;&gt; ${DAILYLOGFILE}
}

# Export some ENV variables so you don't have to type anything
export AWS_ACCESS_KEY_ID="<strong>YOUR_ACCESS_KEY_ID</strong>"
export AWS_SECRET_ACCESS_KEY="<strong>YOUR_SECRET_ACCESS_KEY</strong>"
export PASSPHRASE="<strong>YOUR_GPG_PASSPHRASE</strong>"

# Your GPG key
GPG_KEY=<strong>YOUR_GPG_KEY</strong>

# How long to keep backups for
OLDER_THAN="3M"

# The source of your backup
SOURCE=/

# The destination
# Note that the bucket need not exist
# but does need to be unique amongst all
# Amazon S3 users. So, choose wisely.
DEST="s3+http://<strong>your_s3_bucket_name</strong>"

FULL=
if [ $(date +%d) -eq 1 ]; then
        FULL=full
fi;

trace "Backup for local filesystem started"

trace "... removing old backups"

duplicity remove-older-than ${OLDER_THAN} ${DEST} &gt;&gt; ${DAILYLOGFILE} 2&gt;&amp;1

trace "... backing up filesystem"

duplicity \
    ${FULL} \
    --encrypt-key=${GPG_KEY} \
    --sign-key=${GPG_KEY} \
    --volsize=250 \
<strong>    --include=/vhosts \
    --include=/etc \
    --include=/home \
    --include=/root \
    --exclude=/** \</strong>
    ${SOURCE} ${DEST} &gt;&gt; ${DAILYLOGFILE} 2&gt;&amp;1

trace "Backup for local filesystem complete"
trace "------------------------------------"

# Send the daily log file by email
cat "$DAILYLOGFILE" | mail -s "Duplicity Backup Log for $HOST - $DATE" $MAILADDR

# Append the daily log file to the main log file
cat "$DAILYLOGFILE" &gt;&gt; $LOGFILE

# Reset the ENV variables. Don't need them sitting around
export AWS_ACCESS_KEY_ID=
export AWS_SECRET_ACCESS_KEY=
export PASSPHRASE=
</code></pre>
<p>Save the script somewhere and give it an appropriate name. I saved it a /usr/bin/duplicity-backup and make sure to chmod the script to 700 - it contains some sensitive information so we don't want none privileged users to have read access to it. Run the script as a test then set it up as a daily cron job to run at an appropriate time of night when the server isn't doing much else.</p>
<h3 id="toc-step-3-the-restore-wrapper-script">Step 3 - The restore wrapper script</h3>
<p>Clearly we need a way to restore from a backup, so use the following script to do just that:</p>
<pre><code>#!/bin/bash
# Export some ENV variables so you don't have to type anything
export AWS_ACCESS_KEY_ID="<strong>YOUR_ACCESS_KEY_ID</strong>"
export AWS_SECRET_ACCESS_KEY="<strong>YOUR_SECRET_ACCESS_KEY</strong>"
export PASSPHRASE="<strong>YOUR_GPG_PASSPHRASE</strong>"

# Your GPG key
GPG_KEY=<strong>YOUR_GPG_KEY</strong>

# The destination
DEST="s3+http://<strong>your_s3_bucket_name</strong>"

if [ $# -lt 3 ]; then echo "Usage $0 &lt;date&gt; &lt;file&gt; &lt;restore-to&gt;"; exit; fi

duplicity \
    --encrypt-key=${GPG_KEY} \
    --sign-key=${GPG_KEY} \
    --file-to-restore $2 \
    --restore-time $1 \
    ${DEST} $3

# Reset the ENV variables. Don't need them sitting around
export AWS_ACCESS_KEY_ID=
export AWS_SECRET_ACCESS_KEY=
export PASSPHRASE= </code></pre>
<p>Again, save this file as something sensible and chmod it to 700 to prevent prying eyes. I saved it as /usr/bin/duplicity-restore but feel free to put it wherever you like.</p>
<p>To do a restore simply invoke the script as follows:</p>
<pre><code>duplicity-restore &lt;date&gt; &lt;file&gt; &lt;restore-to&gt;</code></pre>
<p>Some notes on usage: Paths are relative not absolute. So /home/username would be backed up as home/username. You can restore whole directories but the destination needs to exist first. For example, to restore /home/username from November 20 2008 to a local directory 'restore', doing the <strong>following would not work</strong> because ./home does not exist:</p>
<pre><code>cd ~
mkdir restore
cd restore
duplicity-restore "2008-11-20" home/username home/username</code></pre>
<p>However, the <strong>following would work</strong> and would restore the directory to ./username:</p>
<pre><code>duplicity-restore "2008-11-20" home/username username</code></pre>
<p>That's all there is to it. As mentioned I've been using this method for several months to back up a variety of servers and it works very nicely. I hope it works just as well for you too!</p>
<h3 id="toc-credits">Credits</h3>
<p>This solution is the combination of a couple of tips and tricks I found while trawling the web, notably from <a href="http://www.randys.org/2007/11/16/how-to-automated-backups-to-amazon-s-s3-with-duplicity/">this howto at randys.org</a> and <a href="http://www.linode.com/forums/viewtopic.php?p=14875#14875">this post over at the linode.com forums</a>. Credit and thanks goes to the original authors - I have merely hacked their ideas together and added a few touches of my own.</p>
<p>If you find this useful or have any comments or questions then please respond below!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cenolan.com/2008/12/how-to-incremental-daily-backups-amazon-s3-duplicity/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Installing Fedora 10 on a MacBook</title>
		<link>http://www.cenolan.com/2008/11/installing-fedora-10-macbook/</link>
		<comments>http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#comments</comments>
		<pubDate>Sat, 29 Nov 2008 16:55:45 +0000</pubDate>
		<dc:creator>Chris</dc:creator>
				<category><![CDATA[Fedora 10]]></category>
		<category><![CDATA[Leisure]]></category>
		<category><![CDATA[MacBook]]></category>
		<category><![CDATA[Broadcom]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[HowTo]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[mactel-linux]]></category>

		<guid isPermaLink="false">http://www.cenolan.com/?p=22</guid>
		<description><![CDATA[

What works and what doesn't?
Basic installation instructions
Post installation
Fixing the wireless
Fixing the touchpad
Disable touchpad while typing
iSight camera
Bluetooth
Apple SMC (Optional)
Plymouth graphical boot (Optional)
What next?


This guide will help you through all the steps necessary for installing Fedora 10 on a MacBook Santa Rosa. This guide is currently aimed at Fedora 10 x86_64 but will also work on i386 [...]]]></description>
			<content:encoded><![CDATA[<div class="toc">
<ol>
<li><a href="http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#toc-what-works-and-what-doesnt">What works and what doesn't?</a></li>
<li><a href="http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#toc-basic-installation-instructions">Basic installation instructions</a></li>
<li><a href="http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#toc-post-installation">Post installation</a></li>
<li><a href="http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#toc-fixing-the-wireless">Fixing the wireless</a></li>
<li><a href="http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#toc-fixing-the-touchpad">Fixing the touchpad</a></li>
<li><a href="http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#toc-disable-touchpad-while-typing">Disable touchpad while typing</a></li>
<li><a href="http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#toc-isight-camera">iSight camera</a></li>
<li><a href="http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#toc-bluetooth">Bluetooth</a></li>
<li><a href="http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#toc-apple-smc-optional">Apple SMC (Optional)</a></li>
<li><a href="http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#toc-plymouth-graphical-boot-optional">Plymouth graphical boot (Optional)</a></li>
<li><a href="http://www.cenolan.com/2008/11/installing-fedora-10-macbook/#toc-what-next">What next?</a></li>
</ol>
</div>
<p>This guide will help you through all the steps necessary for installing Fedora 10 on a MacBook Santa Rosa. This guide is currently aimed at Fedora 10 x86_64 but will also work on i386 version (adjust as necessary). Most of the steps equally apply to pre-Santa Rosa models too.</p>
<p>These instructions will work with the MacBook 3,1 (Late 2007) and newer but will NOT work with the new aluminium MacBooks since they have different hardware (especially the graphics card). These instructions are not suitable for the MacBook Pro either!!</p>
<p>This guide is based largely around my <a href="http://www.mactel-linux.org/wiki/Fedora8OnMacBookSantaRosa">previous guide for Fedora 8</a>, and again much credit goes to the people who created the original <a href="https://help.ubuntu.com/community/MacBook_Santa_Rosa">Ubuntu wiki guide</a>.</p>
<h3 id="toc-what-works-and-what-doesnt">What works and what doesn't?</h3>
<p>There are a few things that need fixing (covered in detail below) but the following all work "out of the box" with Fedora 10: video/graphics, compiz effects, firewire, CD/DVD reading and writing, function keys (brightness, volume etc), sound, and ethernet. Even the new "plymouth" graphical boot screen works fine once activated.</p>
<p>I have yet to try the infrared or connecting an external monitor. Everything else works with the tweaks described below, except for suspend and hibernate which seem generally pretty broken in F10 (as it was in F9 too). <em>Update 7 November 2008: Suspend and hibernate are fixed with 2.6.27.7-134 kernel and newer. <a href="https://bugzilla.redhat.com/show_bug.cgi?id=473542">See bug report</a>.</em></p>
<p><span id="more-22"></span></p>
<h3 id="toc-basic-installation-instructions">Basic installation instructions</h3>
<p>If you're new to installing Linux then these steps should help you. If you're an old hand then skip below to view the post-installation steps necessary to fix the things that don't "just work".</p>
<ol>
<li>Update the MacBook firmware to the latest version. If you prefer, you may use the standard "Software Update" in OS X.</li>
<li>Get your Fedora 10 installation DVD ready. Note: you should use the x86_64 version of Fedora 10 and that I have only tested this using the Install Media, not the Live DVD.</li>
<li>Install <a href="http://refit.sourceforge.net/">rEFIt</a> on OS X if you want a boot menu to select between OS X/Fedora to appear on every boot. This is highly recommended but optional - this guide assumes you have installed rEFIt. You can make Fedora boot by default and change the menu timeout by editing the "refit.conf" file (described on the rEFIt website).</li>
<li>Use the OS X partition manager in Disk Utility to resize your OS X partition and make space for Fedora. On my 260GB hard drive, I shrank the OS X (hfs+) partition to 120GB to leave about 130GB for Fedora. Insert your Fedora 10 installation DVD in the drive and reboot.</li>
<li>If you have rEFIt installed, then on boot you will be given the option to boot from the DVD, choose it. If you don't have rEFIt installed, then hold down "C" to boot from the DVD.</li>
<li>Install Fedora as usual, except:</li>
<ol>
<li>In the partitioner, select to manually edit partition table</li>
<li>Create a 200MB boot partition with mountpoint '/boot' (this will be /dev/sda3)</li>
<li>Create a new ext3 partition with mountpoint '/' - this will be your main Fedora partition on /dev/sda4. Make sure to leave 2GB free space after this partition for your swap partition</li>
<li>With the remaining 2GB, create a linux swap partition - this will be /dev/sda5</li>
</ol>
<li>Finish the installation and reboot.</li>
<li>If you installed rEFIt, you should have a choice between booting OS X and Linux. Use the arrow keys and Enter to select Linux.</li>
<li>Log in to Fedora</li>
<li>Follow the steps in the sections below to work around things that still do not work out-of-the-box in Fedora 10.</li>
</ol>
<h3 id="toc-post-installation">Post installation</h3>
<p>Note: The wireless on the MacBook doesn't work out of the box in Fedora, so you're going to need an ethernet internet connection available until we get round to fixing the wireless later in this guide.</p>
<p>It is very important now to update your Fedora installation to the latest packages using yum. To do so:</p>
<pre><code>su -
yum update</code></pre>
<p>Once yum has finished updating, reboot, and then do a yum update again. Repeat this process until yum finds no more packages to update.</p>
<h3 id="toc-fixing-the-wireless">Fixing the wireless</h3>
<p>The MacBook comes with a Broadcom 4328 wireless chipset. This is not supported by default in Fedora 10 and there are two options to make it work: using ndiswrapper and Windows drivers or using the new official Broadcom STA wireless driver. In this guide we will use the official Broadcom driver because it is easier and more reliable.</p>
<p><strong>1) Enable the rpmfusion non-free repository.</strong></p>
<p>The broadcom-wl and wl-kmod RPMs that we need are in the <a href="http://rpmfusion.org">rpmfusion.org</a> non-free repository which also requires the rpmfusion.org free repository. To enable these repos in Fedora simply do this:</p>
<pre><code>su -c 'rpm -Uvh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm'</code></pre>
<p><strong>2) Update and install the driver package</strong></p>
<p>Now that you have the appropriate repository enabled, to install the driver package we first ensure that we have the latest updates and then install the "broadcom-wl" package which will bring with it the required "kmod-wl" package:</p>
<pre><code>su -
yum update
yum install broadcom-wl</code></pre>
<p>That's all there is to it. At this stage you may need to reboot in order to enable the new driver and any new kernel that was installed during the update. For more details or if you have any difficulties <a href="http://www.cenolan.com/2008/11/rpm-install-broadcom-wireless-sta-driver-fedora/">see this post</a>.</p>
<p>When future kernels are released a simple "yum update" command should install the new kernel and also pull in the updated Broadcom driver for that new kernel.</p>
<h3 id="toc-fixing-the-touchpad">Fixing the touchpad</h3>
<p>(Thanks to <a href="http://bd-things.net/fedora-10-thank-you-very-much-macbook-review-and-fixes/">bodom_lx</a> for this tip)</p>
<p>The touchpad works out of the box but there is no way to right or middle click. Traditionally this was fixed by adding the appropriate options to /etc/X11/xorg.conf but the new xorg-server in F10 doesn't use the traditional xorg.conf file. Instead it is configured through <a href="http://www.freedesktop.org/wiki/Software/hal">HAL</a> fdi configuration files. </p>
<p>To create the appropriate file for configuring the touchpad:</p>
<pre><code>su -
gedit /etc/hal/fdi/policy/appletouch.fdi</code></pre>
<p>Copy and paste the following into the empty file:</p>
<pre><code>&lt;?xml version="1.0" encoding="ISO-8859-1"?&gt;
&lt;deviceinfo version="0.2"&gt;
  &lt;device&gt;
    &lt;match key="info.capabilities" contains="input.touchpad"&gt;
      &lt;match key="info.product" contains="appletouch"&gt;
        &lt;merge key="input.x11_driver" type="string"&gt;synaptics&lt;/merge&gt;
        &lt;merge key="input.x11_options.SendCoreEvents" type="string"&gt;true&lt;/merge&gt;
        &lt;merge key="input.x11_options.HorizEdgeScroll" type="string"&gt;0&lt;/merge&gt;
        &lt;merge key="input.x11_options.VertEdgeScroll" type="string"&gt;0&lt;/merge&gt;
        &lt;merge key="input.x11_options.VertTwoFingerScroll" type="string"&gt;1&lt;/merge&gt;
        &lt;merge key="input.x11_options.HorizTwoFingerScroll" type="string"&gt;0&lt;/merge&gt;
        &lt;merge key="input.x11_options.VertScrollDelta" type="string"&gt;10&lt;/merge&gt;
        &lt;merge key="input.x11_options.HorizScrollDelta" type="string"&gt;10&lt;/merge&gt;
        &lt;merge key="input.x11_options.VertScrollDelta" type="string"&gt;10&lt;/merge&gt;
        &lt;merge key="input.x11_options.TapButton1" type="string"&gt;0&lt;/merge&gt;
        &lt;merge key="input.x11_options.TapButton2" type="string"&gt;3&lt;/merge&gt;
        &lt;merge key="input.x11_options.TapButton3" type="string"&gt;2&lt;/merge&gt;
        &lt;merge key="input.x11_options.ClickFinger1" type="string"&gt;1&lt;/merge&gt;
        &lt;merge key="input.x11_options.ClickFinger2" type="string"&gt;3&lt;/merge&gt;
        &lt;merge key="input.x11_options.ClickFinger3" type="string"&gt;2&lt;/merge&gt;
        &lt;merge key="input.x11_options.FingerLow" type="string"&gt;10&lt;/merge&gt;
        &lt;merge key="input.x11_options.FingerHigh" type="string"&gt;20&lt;/merge&gt;
        &lt;merge key="input.x11_options.PressureMotionMinZ" type="string"&gt;10&lt;/merge&gt;
        &lt;merge key="input.x11_options.SHMConfig" type="string"&gt;On&lt;/merge&gt;
      &lt;/match&gt;
    &lt;/match&gt;
  &lt;/device&gt;
&lt;/deviceinfo&gt;</code></pre>
<p>Save the file and reboot. You should now be able to right-click by using a two finger tap on the touchpad and middle-click by using a three finger tap. You can also right-click by holding two fingers on the touchpad and clicking the button, and middle-click by holding three fingers and clicking the button.</p>
<p>If you want to adjust any of the options (or add new ones) see "man synaptics" for an explanation of what they do.</p>
<h3 id="toc-disable-touchpad-while-typing">Disable touchpad while typing</h3>
<p>The placement and sensitivity of the MacBook touchpad means that it is prone to moving your cursor while you're typing which is very annoying. We can fix this:</p>
<p>To disable the touchpad while typing use this command:</p>
<pre><code>syndaemon -i 1 -d</code></pre>
<p>This disables the touchpad for 1 second after you type something. This works well but if you go back and forth a lot it can be a hassle to wait that one second. NOTE you can use ".5" for half a seconf instead and it works much better.</p>
<p>Alternatively,</p>
<pre><code>syndaemon -t -d</code></pre>
<p>This disables tapping motions but not movement while typing.</p>
<p>Both work fine, and the one that works best for you will likely be determined by the type of computing you do. Try them both and decide for yourself.</p>
<p>Once you've found the one you want to use, add it as an application to start in your gnome session. </p>
<h3 id="toc-isight-camera">iSight camera</h3>
<p>First of all, you will need a copy of the firmware from Apple. You can either <a href="http://www.i-nz.net/files/projects/linux-kernel/isight/against-revision-140/firmware/AppleUSBVideoSupport">download this here</a>, or copy it from a Mac OS X partition. While the latter is usually preferred I can't guarantee that the firmware distributed with your MacBook will be supported, so sometimes its easier just to download it.</p>
<p>To acquire the firmware, save the file AppleUSBVideoSupport to your home directory. Next, we need to convert the AppleUSBVideoSupport to a useable firmware file. The isight-firmware-tools will do this for us so we need to install that package:</p>
<pre><code>su -c "yum install isight-firmware-tools"</code></pre>
<p>Now, finally, we can convert the AppleUSBVideoSupport to a useable firmware file. From your home directory where you downloaded the AppleUSBVideoSupport file: </p>
<pre><code>su -c ift-extract --apple-driver AppleUSBVideoSupport</code></pre>
<p>Reboot and your webcam should be fully functionally. Test it with Cheese, Ekiga, or Skype2.</p>
<h3 id="toc-bluetooth">Bluetooth</h3>
<p>Bluetooth works out of the box but due to some <a href="https://bugzilla.redhat.com/show_bug.cgi?id=371061#c2">kernel bug</a> it needs to be enabled properly first.</p>
<p>Edit /etc/sysconfig/bluetooth and make sure it says 'HID2HCI_ENABLE=true'.</p>
<p>That'll fix it on subsequent reboots. For now, just run '/sbin/hid2hci' as root.</p>
<h3 id="toc-apple-smc-optional">Apple SMC (Optional)</h3>
<p>This is an optional but recommended step. The <a href="http://www.mactel-linux.org/wiki/AppleSMC">Apple SMC</a> (System Management Controller) provides an interface to devices such as fans, temperature sensors, motion sensors, leds and controls these.</p>
<p>The applesmc kernel module is not loaded by default - I guess this is a bug. The correct way to load a module on boot in Fedora 10 is to create a .modules file in /etc/sysconfig/modules/ - here is how to do it for applesmc:</p>
<pre><code>su -
gedit /etc/sysconfig/modules/applesmc.modules</code></pre>
<p>Paste the following into the file: </p>
<pre><code>#!/bin/sh

if [ ! -d /sys/devices/platform/applesmc.768 ] ; then
        exec /sbin/modprobe applesmc >/dev/null 2>&#038;1
fi</code></pre>
<p>Save and exit, then change the file permissions as follows:</p>
<pre><code>chmod 755 /etc/sysconfig/modules/applesmc.modules</code></pre>
<p>On next boot the applesmc module will load. Meanwhile, just do "modprobe applesmc" as root. </p>
<h3 id="toc-plymouth-graphical-boot-optional">Plymouth graphical boot (Optional)</h3>
<p>To activate the plymouth graphical boot you must edit /boot/grub/grub.conf and add your framebuffer resolution at the end of the kernel line. For the MacBook with Intel graphics the resolution that works is "0x318". So, become root and edit the kernel line to look something like this:</p>
<pre><code>title Fedora (2.6.27.5-117.fc10.x86_64)
	root (hd0,2)
	kernel /vmlinuz-2.6.27.5-117.fc10.x86_64 ro root=UUID=afb18b52-bfdf-49aa-95f0-234d3013f87d rhgb quiet <strong>vga=0x318</strong>
	initrd /initrd-2.6.27.5-117.fc10.x86_64.img</code></pre>
<p>By default only the solar and text themes are installed. To add additional plymouth themes type:</p>
<pre><code>su -
yum install plymouth-plugin-{fade-in,pulser,spinfinity}</code></pre>
<p>Now you can try any theme you want like shown below, just replace pluginname with one of the following: solar, fade-in, pulser, spinfinity, text:</p>
<pre><code>su -
plymouth-set-default-plugin pluginname
/usr/libexec/plymouth/plymouth-update-initrd</code></pre>
<p>After that just reboot your computer to enjoy a lovely graphical boot. </p>
<h3 id="toc-what-next">What next?</h3>
<p>Now your MacBook hardware should be fully functional so it is time to get busy adding the software you want and tweaking the system to your needs. </p>
<p><a href="http://www.mjmwired.net/resources/mjm-fedora-f10.html">This guide by Mauriat Miranda</a> is a great place to look for details of how to install common media players, codecs and fonts. </p>
<p>For the native 64bit flash plugin see <a href="http://forums.fedoraforum.org/showpost.php?p=1112258&#038;postcount=3">this post</a>.</p>
<p>Have fun!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cenolan.com/2008/11/installing-fedora-10-macbook/feed/</wfw:commentRss>
		<slash:comments>38</slash:comments>
		</item>
		<item>
		<title>RPM installation of Broadcom 802.11 STA wireless driver in Fedora 8/9/10</title>
		<link>http://www.cenolan.com/2008/11/rpm-install-broadcom-wireless-sta-driver-fedora/</link>
		<comments>http://www.cenolan.com/2008/11/rpm-install-broadcom-wireless-sta-driver-fedora/#comments</comments>
		<pubDate>Sat, 15 Nov 2008 11:53:54 +0000</pubDate>
		<dc:creator>Chris</dc:creator>
				<category><![CDATA[Fedora 10]]></category>
		<category><![CDATA[Fedora 8]]></category>
		<category><![CDATA[Fedora 9]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Broadcom]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[RPM]]></category>

		<guid isPermaLink="false">http://www.cenolan.com/?p=21</guid>
		<description><![CDATA[RPMs for the Broadcom 802.11 STA Wireless Driver are now available from the rpmfusion.org repos for Fedora 8, 9 and 10.
This is an official-release of Broadcom's IEEE 802.11a/b/g/n hybrid Linux device driver for use with Broadcom's BCM4311-, BCM4312-, BCM4321-, and BCM4322-based hardware. This driver also supports the incorrectly identified BCM4328 chipset which is actually a [...]]]></description>
			<content:encoded><![CDATA[<p>RPMs for the Broadcom 802.11 STA Wireless Driver are now available from the <a href="http://rpmfusion.org/">rpmfusion.org</a> repos for Fedora 8, 9 and 10.</p>
<p>This is an official-release of Broadcom's IEEE 802.11a/b/g/n hybrid Linux device driver for use with Broadcom's BCM4311-, BCM4312-, BCM4321-, and BCM4322-based hardware. This driver also supports the incorrectly identified BCM4328 chipset which is actually a BCM4321 or BCM4322 chipset.</p>
<p>Previously I explained <a href="http://www.cenolan.com/2008/10/installing-the-broadcom-sta-driver-fedora-9/">how to build the Broadcom STA driver from source</a> but now the installation and updates can all be taken care of using yum and the rpmfusion non-free repository. Just follow these two simple steps:</p>
<p><span id="more-21"></span></p>
<p><strong>1) Enable the rpmfusion non-free repository.</strong></p>
<p>The broadcom-wl and wl-kmod RPMs that we need are in the rpmfusion non-free repository which also requires the rpmfusion free repository. To enable these repos in Fedora simply do this:</p>
<pre><code>su -c 'rpm -Uvh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm'</code></pre>
<p><strong>2) Update and install the driver package</strong></p>
<p>Now that you have the appropriate repository enabled, to install the driver package we first ensure that we have the latest updates and then install the "broadcom-wl" package which will bring with it the required "kmod-wl" package:</p>
<pre><code>su -
yum update
yum install broadcom-wl</code></pre>
<p><strong>3) Make a couple of adjustments</strong></p>
<p>At this stage you should reboot and provided you have Network Manager running (default setting for F10) it should detect your Broadcom wireless device and you should be able to connect to your wireless network.</p>
<p>If you're having problems then it is likely some conflict between Network Manager and the network service. To ensure that Network Manager can use the wireless go to System &gt; Administration &gt; Network and select the wireless device (if it's not there then this doesn't apply to you). Edit the device and check "Controlled by Network Manager" and "Activate device when computer starts". Close Network Configuration, save changes and then reboot.</p>
<p>You should also read the license and readme which are located in /usr/share/doc/broadcom-wl-5.10.27.6/</p>
<p><strong>4) Enjoy your wireless!</strong></p>
<p>That's all there is to it. At this stage you may need to reboot (if you didn't already) in order to enable the new driver and any new kernel that was installed during the update.</p>
<p>When future kernels are released a simple "yum update" command should install the new kernel and also pull in the updated Broadcom driver for that new kernel.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cenolan.com/2008/11/rpm-install-broadcom-wireless-sta-driver-fedora/feed/</wfw:commentRss>
		<slash:comments>93</slash:comments>
		</item>
	</channel>
</rss>
