CaolanMcMahon/Blog

Stop Firefox Crashes From Killing Google Docs

April 2nd, 2008

Firefox is a great browser, I use it all the time, but its not always the most reliable application on your desktop. I have a habit of stress-testing my browser with extreme tabbing, add that to my laptops inability to handle videos and crashes and sluggish performance are inevitable.

The problem is that I have replaced many of my traditional desktop applications with web-based versions. My email, calendar, documents and many other key applications are all accessed through my browser, so when that goes down they all go down!

Recently, I’ve been playing around with Mozilla’s Prism, a program similar to Adobe’s AIR which aims to integrate web applications with the desktop. I wouldn’t call this a major breakthrough… yet. At the moment its essentially a new browser window without a navigation toolbar which, most importantly, runs as a seperate process. This prevents a problem with my main Firefox window affecting all my other applications.

So, how do you achieve this state of productive bliss? Easy (ish), but first you’ll have to get the latest beta of Firefox 3. Don’t worry too much about stability, I’ve been running beta 4 for a while now and had no problems, and the Ubuntu guys seem confident enough to include it in their Hardy Heron release.

You can get the relevant version for your set-up here:
http://www.mozilla.com/en-US/firefox/all-beta.html

Once you’ve got that you can install the Prism plug-in for Firefox 3 which will automagically transform the site you’re currently visiting into a Prism application. You can get the plugin here:
https://addons.mozilla.org/en-US/firefox/addon/6665

Once that’s all set up, you can start creating Prism applications by clicking “Tools > Convert Website to Application” and following the prompts.

Here’s one I made earlier…

Google Docs running as a Prism application

Now, start combining this with Google Gears, and perhaps we can make something a little more interesting!

Tags: , , ,
Posted in Linux, Web | No Comments »

Seagate FreeAgent 500gb and NSLU2 read-only problem

March 20th, 2008

I had a strange problem with the NSLU2 where it would re-mount all partitions on my Seagate FreeAgent 500gb drive as read-only. I ran fsck to see if a problem on the drive was causing it (the Debian /etc/fstab settings has the root partition do this automatically on errors). Fsck found nothing and I noticed that this kept happening in the middle of the night when it was least active. Turns out its due to the device spinning down during inactivity (one of the reasons I bought this drive!) and debian’s driver not starting it up again.

For anyone Googling this problem, here is the fix I used on a Debian/NSLU2 system:

edit /etc/rc.local to include:
echo 1 > /sys/block/sda/device/scsi_disk*/allow_restart

You’ll also need to change the shebang at the top of the file to use bash for the wildcard in the above line to work:
#!/bin/bash

Since I often just copy and paste some error messages into Google I’ve included some of the errors that came up in the syslog for searching purposes:


sd 0:0:0:0: Device not ready: <6>: Current: sense key=0×2
ASC=0×4 ASCQ=0×2
end_request: I/O error, dev sda, sector 244567
sd 0:0:0:0: Device not ready: <6>: Current: sense key=0×2
ASC=0×4 ASCQ=0×2
end_request: I/O error, dev sda, sector 41050925
sd 0:0:0:0: Device not ready: <6>: Current: sense key=0×2
ASC=0×4 ASCQ=0×2
end_request: I/O error, dev sda, sector 244583
Buffer I/O error on device sda1, logical block 30565
lost page write due to I/O error on sda1
Aborting journal on device sda1.
Aborting journal on device sda3.
ext3_abort called.
EXT3-fs error (device sda1): ext3_journal_start_sb: Detected aborted journal
Remounting filesystem read-only
ext3_abort called.
EXT3-fs error (device sda3): ext3_journal_start_sb: Detected aborted journal
Remounting filesystem read-only

Posted in Linux | 1 Comment »

Sounds of the Slug

March 8th, 2008

Soundsystem Diagram

So, my Linksys NSLU2 (a.k.a. ‘Slug’) has arrived, and I am one happy geek! I know people say it’s tiny, but I really hadn’t expected it to be this small!

Here’s what I’ve got it to do so far…

  1. Installed Debian/NSLU2 on it - it crashed during the partitioning phase (out of memory I think), but a reboot and manual setting-up of the partitions sorted it
  2. Plugged in an external USB soundcard and installed alsa, alsa-tools and alsa-utils - a quick test using the ‘aplay’ command and it worked straight away (I love you Debian)
  3. Installed Music Player Daemon (MPD) and Music Player Client (MPC) - transferred a few songs over and gave it a test run, works great.
  4. Installed lastfmsubmitd and lastmp to submit songs played via MPD to my Last.fm profile

Now I have a mini, silent running server which will play music through my mixer and can be controlled wirelessly around the house. Not much use, sure… but plenty of fun. I can sit on the sofa with my laptop and no connecting cables and just pick my music. This could be neat in an office or cafe as you can get a collaborative playlist going. I’m working on a web-based client for MPD (none of the existing ones really do what I want) currently codenamed ‘Beatseek‘.

So far I’ve only tried playing FLAC, but its worked flawlessly. The sound quality is great, much better than my laptop and desktop which both generate a lot of background hiss.

It’s been running fine with my current usage so I think it will take plenty more abuse beyond just being my personal music slave. A torrent box instantly springs to mind… Take a look at some of the other cool things being done with the ‘Slug’ over at http://www.nslu2-linux.org/

Tags: , , , ,
Posted in Linux, Music | No Comments »