<?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>Ideas.... &#187; Mac OS X</title>
	<atom:link href="http://rosalynmetz.com/ideas/tag/mac-os-x/feed/" rel="self" type="application/rss+xml" />
	<link>http://rosalynmetz.com/ideas</link>
	<description>a blog for me to record thoughts and ideas</description>
	<lastBuildDate>Mon, 19 Jul 2010 16:27:30 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
<atom:link rel="hub" href="http://pubsubhubbub.appspot.com"/><atom:link rel="hub" href="http://superfeedr.com/hubbub"/>		<item>
		<title>Random Moodle</title>
		<link>http://rosalynmetz.com/ideas/2009/02/13/random-moodle/</link>
		<comments>http://rosalynmetz.com/ideas/2009/02/13/random-moodle/#comments</comments>
		<pubDate>Fri, 13 Feb 2009 15:24:29 +0000</pubDate>
		<dc:creator>Rosalyn Metz</dc:creator>
				<category><![CDATA[Work]]></category>
		<category><![CDATA[Mac OS X]]></category>
		<category><![CDATA[Moodle]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://rosalynmetz.com/ideas/?p=450</guid>
		<description><![CDATA[It&#8217;s been a while since I wrote, and its not that I forgot about my blog, it&#8217;s just that I&#8217;ve been busy.  Our Moodle installation is growing up and will be getting its own server soon.  I&#8217;m hoping that it&#8217;ll be a OSX 10.5 Server so I&#8217;ve been working out some of the kinks in [...]]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s been a while since I wrote, and its not that I forgot about my blog, it&#8217;s just that I&#8217;ve been busy.  Our Moodle installation is growing up and will be getting its own server soon.  I&#8217;m hoping that it&#8217;ll be a OSX 10.5 Server so I&#8217;ve been working out some of the kinks in my test installation:</p>
<ol>
<li>GD Library &#8212; By default the GD library&#8217;s aren&#8217;t part of the PHP package in Server 10.5.  I was poking around in this <a href="http://docs.moodle.org/en/Step_by_Step_Installation_on_a_Mac_OS_X_10.5_Server">Step by Step Installation guide</a> trying to upgrade my PHP library on my server.  Turns out I didn&#8217;t need to for various reasons (also the package recommended screwed with my Apache).  So instead i went into my php.ini file and uncommented the line:<br />
<blockquote><p>extension=php_gd2.dll</p></blockquote>
<p>This turned on the GD Library and Moodle looks much better now.</li>
<li>MySQL &#8212; I was getting a weird error in Moodle under Admin &gt; Server &gt; Environment.<br />
<blockquote><p>It is required that you store all your data in Unicode format (UTF-8). New installations must be performed into databases that have their default character set as Unicode. If you are upgrading, you should perform the UTF-8 migration process (see the Admin page).</p></blockquote>
<p>I thought that was a bit weird cause I installed the database from scratch. But sometimes you just need to do what it tells you to.  So I ran the following query:</p>
<blockquote><p><code>alter database moodle collate = utf8_unicode_ci;</code></p></blockquote>
<p>And voila the error went away.</li>
</ol>
<p>So now my Moodle is a bit happier.  I am of course (like always) recording this so that when I get my new server and I run into these problems again, I can remember what the heck I did.</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save">Share/Save</a> </p>]]></content:encoded>
			<wfw:commentRss>http://rosalynmetz.com/ideas/2009/02/13/random-moodle/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Updating a Server is Scary</title>
		<link>http://rosalynmetz.com/ideas/2008/12/23/updating-a-server-is-scary/</link>
		<comments>http://rosalynmetz.com/ideas/2008/12/23/updating-a-server-is-scary/#comments</comments>
		<pubDate>Tue, 23 Dec 2008 13:16:02 +0000</pubDate>
		<dc:creator>Rosalyn Metz</dc:creator>
				<category><![CDATA[Work]]></category>
		<category><![CDATA[Mac OS X]]></category>

		<guid isPermaLink="false">http://rosalynmetz.com/ideas/2008/12/23/updating-a-server-is-scary/</guid>
		<description><![CDATA[but only the part where you&#8217;ve lost all communication with it. like right now. i&#8217;m pinging it and i&#8217;m getting nothing in response. that freaks me out. yay! its back]]></description>
			<content:encoded><![CDATA[<p>but only the part where you&#8217;ve lost all communication with it.  like right now.  i&#8217;m pinging it and i&#8217;m getting nothing in response.  that freaks me out.</p>
<p>yay!  its back</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save">Share/Save</a> </p>]]></content:encoded>
			<wfw:commentRss>http://rosalynmetz.com/ideas/2008/12/23/updating-a-server-is-scary/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Making a MediaWiki Farm</title>
		<link>http://rosalynmetz.com/ideas/2008/11/14/making-a-mediawiki-farm/</link>
		<comments>http://rosalynmetz.com/ideas/2008/11/14/making-a-mediawiki-farm/#comments</comments>
		<pubDate>Fri, 14 Nov 2008 20:56:07 +0000</pubDate>
		<dc:creator>Rosalyn Metz</dc:creator>
				<category><![CDATA[Work]]></category>
		<category><![CDATA[Mac OS X]]></category>
		<category><![CDATA[MediaWiki]]></category>

		<guid isPermaLink="false">http://rosalynmetz.com/ideas/?p=164</guid>
		<description><![CDATA[Introduction I was tasked by my boss to create a MediaWiki Farm.  I thought this would give me the opportunity to learn more about MediaWiki, but believe it or not it also helped me learn more about Mac&#8217;s &#8220;Unix&#8221; flavor. The purpose of the MediaWiki Farm is so that professors can request wikis for academic/research [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Introduction</strong></p>
<p>I was tasked by my boss to create a MediaWiki Farm.  I thought this would give me the opportunity to learn more about MediaWiki, but believe it or not it also helped me learn more about Mac&#8217;s &#8220;Unix&#8221; flavor.</p>
<p>The purpose of the MediaWiki Farm is so that professors can request wikis for academic/research work from our Research and Instruction Department.  The reason we chose to create a farm was so that we could minimize the amount of work necessary to maintain 5 plus MediaWikis (I don&#8217;t want to have to update each and every one&#8217;s filesystem each time a new version comes out).</p>
<p><strong>Creating the MediaWiki Farm with Symbolic Links</strong></p>
<p>While poking around on my good friend Google I found a lovely page that described <a href="http://www.shawndouglas.com/wikifarm/">How to Create a MediaWiki Farm using Symbolic Links on Mac OS X</a>.  It was nice because it gave me directions.  But as a former Unix person I assumed some of the directions could be improved upon (silly me).  So I set about creating my MediaWiki Farm.</p>
<p>Below are the directions that I followed and what I learned from the process:</p>
<ol>
<li><em>Download MediaWiki and unpack it.</em><br />
I decided to put everything in a directory named wikis since I have multiple products running on this server.  I then asked that the wikis folder be mapped to a new DNS (wikis.wheatoncollege.edu).</li>
<li><em>Create symbolic links from the unpacked MediaWiki to a template directory.</em><br />
<blockquote><p><code>ln -s mediawiki-[version] template</code></p></blockquote>
<p>At first I wasn&#8217;t sure why I was doing this that way.  Why not just link everything to the unpacked file system?  After thinking about this I realized that it would be easier to update symbolic links once, not 5, 10, 15 times.  But I have to say I&#8217;m still on the fence about this, because of the next step.</li>
<li><em>Create a blank wiki from your template.</em><br />
First I created the direcotory the new wiki will reside in.</p>
<blockquote><p><code>cd /Library/WebServer/Documents/wikis<br />
mkdir [newdirectory]<br />
cd /Library/WebServer/Documents/wikis/[newdirectory]<br />
</code></p></blockquote>
<p>Another thing to consider is creating the AdminSettings.php file.  To do this I renamed the sample file and created a symbolic link for it:</p>
<blockquote><p><code>cd /Library/WebServer/Documents/wikis/template<br />
mv AdminSettings.sample AdminSettings.php<br />
sudo chmod 744 AdminSettings.php</code></p></blockquote>
<p>You&#8217;ll also want to edit the AdminSettings.php file and include super user access.  This will help you in updating the wiki later on down the road.</p>
<p>The next thing I did was create a list of all the files in the template directory.  This is why I&#8217;m still on the fence about not just linking directly; will I have to create a new list every time I update MediaWiki?  I&#8217;m sure there is a way to automate this, but I don&#8217;t have time to work on this now, I&#8217;ll do that later.</p>
<p>Another thing is that Mac works strangely with symbolic links.  If I were to do an <code>ln -s mediawiki-[version] [newdirectory]</code> it would link to everything in that directory.  And let&#8217;s say I go into [newdirectory] and remove one of the files in the directory using <code>rm wiki.phtml</code> for example.  The <code>rm wiki.phtml</code> will <strong>not only</strong> delete the file in [newdirectory], but also the one in the template directory <strong>and</strong> the one in the mediawiki-[version] directory.  I discovered this when I went in and symlinked the template to [newdirectory] using <code>ln -s template [newdirectory]</code>.  I ended up having to start over.</p>
<p>So I created a symlink for each of the files and the subdirectories:</p>
<blockquote><p><code>ln -s /Library/WebServer/Documents/wikis/template/api.php<br />
ln -s /Library/WebServer/Documents/wikis/template/AdminSettings.php<br />
ln -s /Library/WebServer/Documents/wikis/template/api.php5<br />
ln -s /Library/WebServer/Documents/wikis/template/COPYING<br />
ln -s /Library/WebServer/Documents/wikis/template/docs<br />
ln -s /Library/WebServer/Documents/wikis/template/extensions<br />
ln -s /Library/WebServer/Documents/wikis/template/FAQ<br />
ln -s /Library/WebServer/Documents/wikis/template/HISTORY<br />
ln -s /Library/WebServer/Documents/wikis/template/img_auth.php<br />
ln -s /Library/WebServer/Documents/wikis/template/img_auth.php5<br />
ln -s /Library/WebServer/Documents/wikis/template/includes<br />
ln -s /Library/WebServer/Documents/wikis/template/index.php<br />
ln -s /Library/WebServer/Documents/wikis/template/index.php5<br />
ln -s /Library/WebServer/Documents/wikis/template/INSTALL<br />
ln -s /Library/WebServer/Documents/wikis/template/install-utils.inc<br />
ln -s /Library/WebServer/Documents/wikis/template/languages<br />
ln -s /Library/WebServer/Documents/wikis/template/locale<br />
ln -s /Library/WebServer/Documents/wikis/template/maintenance<br />
ln -s /Library/WebServer/Documents/wikis/template/Makefile<br />
ln -s /Library/WebServer/Documents/wikis/template/math<br />
ln -s /Library/WebServer/Documents/wikis/template/opensearch_desc.php<br />
ln -s /Library/WebServer/Documents/wikis/template/opensearch_desc.php5<br />
ln -s /Library/WebServer/Documents/wikis/template/profileinfo.php<br />
ln -s /Library/WebServer/Documents/wikis/template/README<br />
ln -s /Library/WebServer/Documents/wikis/template/redirect.php<br />
ln -s /Library/WebServer/Documents/wikis/template/redirect.php5<br />
ln -s /Library/WebServer/Documents/wikis/template/redirect.phtml<br />
ln -s /Library/WebServer/Documents/wikis/template/RELEASE-NOTES<br />
ln -s /Library/WebServer/Documents/wikis/template/serialized<br />
ln -s /Library/WebServer/Documents/wikis/template/skins<br />
ln -s /Library/WebServer/Documents/wikis/template/StartProfiler.php<br />
ln -s /Library/WebServer/Documents/wikis/template/t<br />
ln -s /Library/WebServer/Documents/wikis/template/Test.php<br />
ln -s /Library/WebServer/Documents/wikis/template/tests<br />
ln -s /Library/WebServer/Documents/wikis/template/thumb.php<br />
ln -s /Library/WebServer/Documents/wikis/template/thumb.php5<br />
ln -s /Library/WebServer/Documents/wikis/template/trackback.php<br />
ln -s /Library/WebServer/Documents/wikis/template/UPGRADE<br />
ln -s /Library/WebServer/Documents/wikis/template/wiki.phtml</code></p></blockquote>
<p>Essentially the reason I&#8217;m creating a list is because certain files in the first layer of the directory should not be symlinked (ie. LocalSettings.php and the images directory).  So I need to create/copy those files into [newdirectory]:</p>
<blockquote><p><code>mkdir images<br />
sudo chown www:wheel images<br />
cp -R /Library/WebServer/Documents/wikis/template/config .<br />
sudo chmod a+w config</code></p></blockquote>
<p>Ok now we have the file system for a new wiki set up.  Next we need to create the database piece.</li>
<li><em>Create the Database for the MediaWiki</em><br />
So in the document on <a href="http://www.shawndouglas.com/wikifarm/#Creating_the_Nth_Wiki">How to Create a MediaWiki Farm on Using Mac OS X</a>, the author creates the database from a shell script.  While it seems to make sense, I personally need to know more about how it works before I&#8217;ll do this.  And I just don&#8217;t have the time to do that right now.</p>
<p>So what I&#8217;ll do for now is go to the wiki&#8217;s start page and follow the instructions there.  Simple enough.</li>
<li><em>Move the LocalSettings.php file and delete the config directory</em><br />
The last step is to move the LocalSettings.php file and delete the config directory.  Make sure that when you move the LocalSettings.php file that you&#8217;re moving it to the full path name, otherwise if you do a <code>mv LocalSettings.php ../</code> it&#8217;ll end up in the template directory (this is because of the weirdness with Macs and symlinks).</p>
<blockquote><p><code>cd config/<br />
mv LocalSettings.php /Library/WebServer/Documents/wikis/[newdirectory]/<br />
cd ..<br />
rm -rf config</code></p></blockquote>
<p>After you move the the LocalSettings.php file you will need to change permissions on it so that people can&#8217;t write or execute the file unless they are the admin user.</p>
<blockquote><p><code>sudo chmod 744 LocalSettings.php</code></p></blockquote>
</li>
<li>Now your MediaWiki is ready to go!</li>
</ol>
<p><strong>Next Steps for the MediaWiki Farm</strong></p>
<p>My next posts will be on moving a MediaWiki to the farm and updating a farmed MediaWiki with separate databases for each instance of MediaWiki.  These topics of are concerned from me since we are currently in an environment where we have multiple outdated MediaWikis being housed in completely seperate installations.  I need to end that, and quickly since its a lot of work to maintain multiple MediaWikis.</p>
<p>Also its important to point out that the reason I chose to use separate databases for each instance of MediaWiki is because of our current environment.  It is possible to use one database for <strong>all</strong> of your MediaWikis, you just append tables with a prefix when you do the install.  The reason I&#8217;ve chosen not to do this is because importing a database as a database and not as tables is significantly easier than renaming all those tables.</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save">Share/Save</a> </p>]]></content:encoded>
			<wfw:commentRss>http://rosalynmetz.com/ideas/2008/11/14/making-a-mediawiki-farm/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
