WordPress on OSX (10.6.8), Apache, PHP & htaccess

I’ve just managed to get OSX 10.6.8 to work with mod_rewrite and .htaccess to be able to let WordPress rewrite it’s URLs. Here is what I did.

I installed WordPress to my homefolder so I’ll access it using http://localhost/~ola/wordpress. Apache is configured to use a split config in OSX so to change the directives for the home folder you change the file /private/etc/apache2/users/Ola.conf. I changed AllowOverride None to AllowOverride All and restarted Apache.

I got a 403 Permission denied message. I checked the Apache error log /var/log/apache2/error_log. It said: [Mon Nov 28 16:30:47 2011] [error] [client 127.0.0.1] Options FollowSymLinks or SymLinksIfOwnerMatch is off which implies that RewriteRule directive is forbidden: /Users/Ola/Sites/slipstream/wp-admin/options-permalink.php, referer: http://localhost/~ola/slipstream/wp-admin/options-permalink.php

I added the Options directive FollowSymLinks to /private/etc/apache2/users/Ola.conf, restarted Apache and it worked fine.

I’m only using this config as a development box so I’m not sure if it has any security implications. If you have any knowledge about this just let me know.

Project: Making My PowerMac G4 MDD quiet

Noisy computer on my balconySome weeks ago I got my hands on an old PowerMac G4 (Mirror Drive Door). It’s no speed monster but two 1.25 GHz CUPs and 1 GB RAM it’s more than enough for my usage. There’s only one catch – The MDDs are really noisy. For a while I kept it on my balcony but that will only work when it’s not raining (and it rains a lot in Sweden) so I decided to make some modifications to get it quiet.

Computer specifications:

  • Power Macintosh G4 (Mirrored Drive Doors) – model number: M8570
  • 2 x 1.25 GHz G4 PowerPC (7455) CPUs (with ALU sink)
  • 4 x 256 MB (PC2700) RAM (max 2 GB)
  • ATI Radeon 9000 Pro (64 MB)
  • 1 x 120 GB HDD
  • FireWire 800
  • DVD Reader / CD-burner (combo drive)
  • USB 1.1 (I must get hold of an USB2 PCI card)

Preparations

I started out with some research to find out if there were any existing modifications and found the following great articles:

This was a good starting point. Both for inspiration and information.

I tore apart the mac to find specifications for all my fans. I didn’t search for any disassembly instructions which I recommend you doing. The computer is a pain to work with. I put together data (airflow, noise levels, RPM, etc) for all original fans by reading data sheets from the manufacturers web sites and tried to find replacement fans with similar air flow capacity but with lower noise levels. The specifications for both the original and new fans are put together in this Google Docs spread sheet.

Time for Modding!

Standard thermometerWhen the fans were ordered I started to gather some temperature data with the original configuration (except for the speaker which was removed). I used the program Temperature Monitor to get the CPU and HDD. Since the MDD can’t measure other temperatures I used a standard indoor/outdoor thermometer to measure PSU, room, DVD and PCI temperatures. Just attach the fan with tape where you want to measure. Having some different data was really valuable (as comparison) to find out which fans that are necessary and not. I also measured the energy (Watts) the computer used for normal desktop use to about 120 W and 130 W when burning CDs using a (UPM PM300) power meter. I compared this data to a friend’s new computer (that was quite even though it consumed 200-250 W). I thought that if that computer is quiet mine can be as well.

I’ll describe the different configurations I tried below. All data is available in the following Google Docs spread sheet.

Test 1 – Original configuration apart from removing the speaker to let air flow through that.

One 92 mm fan replacing the 2 60 mm PSU fansTest 2 – I removed the two 60 mm Nidec fans from the PSU and replaced that with one 92 mm Zahlman fan running at 7 V that I attached (temporarily) using tape. The temperatures rose a bit, but not too much whilst the noise level was lower but still too disturbing.

Custom built connector cableTest 3 – I kept the 92 mm fan attached to the PSU (from test 2) and connected the DVD fan at 5 V (instead of original 12 V). To be able to attach the DVD fan to 5 V I built a connector cable using a standard connector socket. You can cut the cables to the fan and solder these on a standard 3 pin fan connector (or 4 pin Molex connector) if you want but I thought it was better to build the custom connector. I noticed a tiny temperature drop but no real drop in noise.

92 mm chassis fan (bottom front)Test 4 – I put the DVD fan back to 12 V and attached a 92 mm fan running at 5 V in the bottom front blowing air in to the computer. I hoped that this could help the CPU fan getting some cold air from outside the chassis and thereby letting it run at as low RPMs as possible (and thereby being quiet). This mod didn’t do any difference in noise or temperature.

Ultraslim 80 mm fan between chassis and CPU sinkTest 5 – When the 92 mm fan (from test 4) didn’t do any difference I wanted to try to put a fan between the CPU sink and the chassis. The idea was that this fan should draw hot air out from the box. I had ordered a slim (15 mm instead of standard 25 mm) 80 mm fan that I hoped to fit perfect. It didn’t. The RAM was in its way. I decided to try to use a Dremel and remove as much plastic as possible from the new fan. After a whole lot of cutting (in the fan) I could attach it (using stripes). I noticed a drop in temperature but no drop in noise. The CPU fan had to be removed.

Test 6 – The final mod! I kept the 80 mm fan (as in test 5). I replaced the 120 mm CPU fan with the PrimeCooler fan. And put back the original two 60 mm fans in the PSU. Since I had ordered a quiet 60 mm fan I replaced the original chassis door fan with that as well (even though it didn’t do any difference). I ran the computer for a while and found out that both noise and temperature was ok so I put back the speaker and crossed my fingers. After some hours I realized that this configuration was more than good enough! The noise level is ok. The computer is not quiet but it doesn’t disturb me anymore and that’s good enough. The temperatures are almost normal so I decided to stop here. For now at least.

Conclusion

It was a fun project to get this computer quiet even though it required about 10 h of work. I can’t really understand why Apple decided to make the computer so loud when it’s possible to make the “windtunnel” macs quiet. It’s like they wanted it to be noisy to make people feel that it was a really powerful computer or something.

If you aren’t into modding I would recommend you just changing the 120 mm Delta CPU fan with a new one and keep an eye on the temperatures. I think that would be enough. If it isn’t try to find a slim 80 mm fan that you attach between the CPU sink and the chassis as well.

Happy modding! Comments and questions are more than welcome.

Software Recomendations!

Today I’ll do a quick round up on a number of different programs that I have found the last days. First a game, then a computer recovery tool, an audio player and I round up with a new web browser for your phone!

Frets On Fire
This is a game where you play ”the guitar” and are supposed to hit different ”notes” in tact with music as they appears on the screen. It works surprisingly well with your keyboard but I guess you’ll get the most out of the game if you hook up a fake guitar to your computer (for example the RedOctane Guitar Hero SG Controller with an USB to Playstation convertor). Update: I have now bought a guitar for the PS2 version of Guitar Hero and plugged it into a USB to PS2 convertor. It works really well!

Simon playing Frets On FireI ran this game on my laptop (a fairly old 1.5ghz laptop) and it worked quite well but I had some random runtime errors that kept crashing the game. After some research I found out about a setting in the game called ”Light Graphics” and after setting that to ”On” my problems disappeared.

Two songs are included in the game and you can import songs from the Playstation game Guitar Hero (if you are going to buy a RedOctane guitar the game can be bought bundled with the guitar) or you can check out community made songs. You can even make your own songs and import. See the Frequently Asked Questions for more information.

Frets On Fire is available for Linux and Windows and an experimental Mac OS X version is also available.

Check out the Frets On Fire web site for more information.

Update: Frets On Fire is currently not developed but are merged to FoFiX that is

Carbon Copy Cloner
Some months ago I got an old PowerMac MDD that I’m using for video editing. The computer had an old 80GB hard drive that I didn’t trust but I wasn’t very keen on doing a reinstall. Instead I searched around for a tool to clone a hard drive to another; Carbon Copy Cloner is just that tool and it works really well!

I just inserted the new hard drive in my computer, booted up (from my old disk with the new one as a slave disk), formated the new disk (in the standard Mac OS X disk utility) and selected to clone the old disk to the new. Half an our later it was done. I shut down the computer, removed the old disk and booted up on the new one. Viola!

Cog – A great audio player for Mac OS X
Ok, I think that iTunes is a good audio player if you need a complete set with all those whistles and bells but since this is not my primary computer that’s not what I want. Instead I tried out Cog which is a seems to be a great light weight audio player. It’s in early development (I got the 0.06 release) but after running it for some hours I haven’t had any problems yet.

Opera Mini 4 beta
Opera has been my favorite web browser for the phone since I started to surf the web on my phone. It’s now available in a new version (version 4 beta) and it’s so great I wish my desktop computer was a phone!

Thats all for now. Hopefully will these tools do you as much good for you as they have for me! Comments, questions and feedback is as always welcome!

Swedish Dvorak keyboard layout for OS X

For the longest time I have been using aoeu.info for all my Dvorak information. But some days ago when I needed a Swedish Dvorak keyboard layout for Mac OS X I found the site down. I searched around for a while but couldn’t find any Swedish Dvorak layouts for OS X so I decided to build my own. I found a tool called Ukelele which helps you create your keyboard layout.

Download: OS X Swedish Dvorak keyboard layout version 0.1

The layout looks like this:
Swedish Dvorak layout for OSX - Standard

And this with the shift key pressed:
Swedish Dvorak layout - Shift pressed

And this with the Apple key pressed:
Swedish Dvorak layout - Apple key pressed

If you have any concerns or questions just post a comment here and I’ll get back to you.

Magnus (from aoeu.info) if you get your site up again I am happy to redirect users from this post to aoeu.info instead. Just post a note here.

Update: aoeu.info is now up and running again!

Setting PAL as default video format in iMovie HD 06

This week I got my hands on a PowerMac dual G4 Mirror Drive Door that I will use as a video editing station with iMovie.

When I started iMovie I noticed that it had set the default DV format to be DV-NTSC (probably since I use English as my language). iMovie adjusts the format based on the camera hooked in to the system but as I created the project before I hooked my camera to the computer it used NTSC and I was screwed. I did not find any setting in iMovie to change the default format. I did a search in the manual. I searched Google but could not find anything. So I decided to apply some brute force the application folder. In a couple of minutes I found the setting string defaultVideoFormat that said DV-NTSC. Changed it to DV-PAL and I was good to go.

The file you need to change is located in:
/Applications/iMovieHD.app/Contents/Resources/
English.lproj/Localizable.strings

(If you are using some other language than English look in that folder instead)