@madpilot makes

Review: Siemans SpeedStream 6520 ADSL2+ Modem Router

With my move to my new house/office, and with Amnet offering static IPs on their ADSL 2 plans it has become time to retire my trusty Alcatel ADSL modem and WRT54G modem/router combination. I went through this process about a year ago when I blew the power supply on my WRT54G and was not impressed with the quality of many of the routers out there. Instead, I modified another power supply and got a UPS (I learnt my lesson)

Anyway, my luck hasn’t changed. Amnet offer a Siemans SpeedStream 6520 with their accounts, so I thought I would give it a go. As far as I can tell, this modem/router is only being offered by Telstra and Amnet as a package and as a result, you can’t purchase it from a retail store.

Problems:

  • The router doesn’t seem to handle persistent connections well. If I open an SSH session, it will often drop out after a period of inactivity – using the PuTTY “keep-alive” feature fixes the problem, so it isn’t the quality of my connection. The same occurs with my Outlook IMAP connection. Very annoying.
  • It doesn’t support port forwarding beyond DMZ – not a huge problem, but I liked this feature of the WRT54G
  • For some weird reason, my VoIP software – eyeBeam, can’t connect through the firewall. It’s little brother, X-Lite works fine, but eye-Beam is so much better I’m quited annoyed at this. Note this may not be a problem with the router, but it worked fine with the WRT54G.

I’ve asked for a refund for it and have ordered a Linksys WAG54Gv2 which is the combination big brother of the WRT54G. Hopefully Linksys is on other winner with this product. I’ll let you know.

Australia Day

Australia Day is my favourite holiday of the year. What has happened in previous years is we would all assemble at Trashy Central for the world famous potato salad contest. It is amazing how, when you say you are having a potato salad contest, ever persons response follows the lines of “I make the best potato salad EVER!” Judged by the party host, the winner gets taken to the restaurant of their choice.

Then down to the foreshore to watch the fireworks, whilst the host stays back to prepare for party: Stage 2.

The party continues once everyone meanders back up.

What happened this year? I worked. It was for a UK client, so cries of “But it’s Australia day!” went unheeded. So I spent the day in front of my laptop, with the TripleJ hottest 100 blaring.

I did mange to finish by 6 and walk down to Maylands (Just down the road now that we are in Mt Lawley) with Giovanna and her family to watch the skyworks – so not all was lost. Still would have been nice to hang with the Knutsfords though :(

Next year – I’m partying!

Using fcgid instead of fastcgi with Ruby on Rails

I have fallen victim to the fastcgi zombie process issue. It would seem that there is a problem with FastCGI running under apache2, where many zombie processes can not be killed, which eventually fills up the process table, slowing down the server. My guess is that is using up all of the sockets, thus stopping any other processes from taking connections (THis is speculation as I haven’t really investigated fully)

Any way – after a quick google, I found that other people have been successfully using the fcgid module, which is a binary compatible replacement for mod_fastcgi. Generic instructions can be found on this blog – however, the following instructions are suitable for Gentoo – it also allows you to use the .htaccess file, giving a finer site control:

  1. emerge mod_fcgid (I used the ACCEPT_KEYWORDS=”~x86″ to get the latest version)

  2. edit /etc/conf.d/apache – add the flag -D FCGID

  3. modify the virtual host in the apache.conf file to include:

Options ExecCGI

and

DefaultInitEnv RAILS_ENV production (For production mode obviously)

  1. modify /etc/apache2/modules/20_mod_fcgid.conf to include:

IPCCommTimeout 40
IPCConnectTimeout 10

(I put it immediately after the LoadModule directive)

  1. modify the A_ddHandler fastcgi-script .fcgi_ line in [Rails_app_root]/public/.htaccess to read:

AddHandler fcgid-script .fcgi

  1. Restart Apache.

I’ll keep you posted on whether it fixes the problem :)

Tagging in Ruby on Rails – easy as you like!

One of my projects required tagging, and I was about to write my own engine, when I can across this article. This library from the article turned adding tags into a five minute job.

Kudos to Dema, the developer of it.

Ruby on Rails validator plugin for password fields

I’m working on a site that allows users to create password protected accounts (Pretty much like every other website around) and I needed a way to check that the password field and confirm password field were the same.

I saw this as an opportunity to play with plug ins :)

You can download the validates_equality_of plug here.

Instructions for use:

  1. Untar the file into the plugins directory of your rails application
  2. You now have access to the validates_equality_of method

Easy!

The method is called in the following manner (assuming you have fields called password and confirm_password)

validates_equality_of :password, :with => :confirm_password

You can override the message in the usual way by supplying a :message attribute.

Hope someone find it useful.

Flogging a dead horse – technologies that don’t belong on the web

The web has come a long way since it’s inception. No longer is it a mismash of ugly looking static pages, posted by scientists. Ecommerce has gone nuts, allowing people to perform online banking and shopping. The advent of blogging has allowed anyone with a net connection to become an author and post their opinions on stuff. Web 2.0 social websites have brought the net back to the people – all in all a pretty exciting time.

However! There are some technologies that seem to be gaining steam because that is what everyone expected the web to do two years ago. The reason that these technologies will fail is because they are trying to force a paradigm where it doesn’t fit. This technique was fine a couple of years ago, but now that the web has started to find it’s feet, the incompatibility is becoming clearer.

One that immediately comes to mind is video-blogging (vblogs). Ever since people realised you could download a video off the net, on-demand video has been touted as the next big thing. Unfortunately, I don’t think it will happen. Why? It is an old medium. It is still one-way. You can’t interact with the video – you are forced to sit and watch and listen to the story. You can’t skim view it, nor can you do other stuff while watching it (You can almost get away with listening to it and doing something else, in which case, it would make more sense to listen to an audio podcast). Not to mention the speed issues – broadband still hasn’t gotten fast enough to really make it work. We young and part of the now generation – we don’t want to wait for for a video download only to find out it is crap.

Another is online newspapers. Sure, these have been around for a while but they have really missed the mark on the web. What is the point of setting up a newspaper to look and feel like it’s real-world counterpart? If I wanted to read my news like that, I would go and buy the paper. The way slashdot distributes it’s news is much closer to the mark. Give me tidbits from every story. That way I can make up my mind straight away if I want to continue reading. Trying to “flick” through a paper online in a traditional sense is too much effort.

What other technologies can you think that are being pushed, but don’t really belong?

Network issues yesterday

Apologies for those wanting to read my blog yesterday – my service provider managed to kill most of their users connection for about 12 hours :(

But I’m back online now which is the main thing…

Ruby, FastCGI and Virtualhosts

Now that that MadPilot Productions site is live, I wanted to run FastCGI. Even though the site is relatively low traffic, I was intrigued to see whether the speedup would be noticable. It is. Unfortunately, the literature I have seen hasn’t really made it clear how to set this up on a server that runs virtualhosts, so here is how it works.

To make a ruby on rails site run in production mode you need to add the following line to the apache.conf file:

FastCgiServer /path/to/site/public/dispatch.fcgi -initial-env RAILS_ENV=production -processes 15 -idle-timeout 60

However, putting this between VirtualHost tags fails. The solution is simple really – put it OUTSIDE the VirtualHost tag. You can have multiple entries in the config file. Since I split my virtual hosts into seperate files (ala Debian, even though I run a Gentoo server) I just drop it in bottom on the file below the closing VirtaulHost tag.

As an aside – Gentoo has a slight problem in that there may throw an error about User/Groups when starting. To fix, put the lines

User apache
Group apache

before the FastCgiIpcDir /tmp/fcgi_ipc directive in the [number]_mod_fastcgi.conf file that is located in /etc/apache/modules.d/ directory.

MadPilot is on Rails

The MadPilot Productions website now has a new look and a new scripting engine driving it – Ruby on Rails!

Leave your comments and tell me what you think :) 

Web 2.0 frameworks – fundamental or fluff?

Over at Port 80, we recently added a Ruby on Rails forum. This was met with both excitement and doubt from forum members. There were those that were excited about a new framework that promises to reduce development time by taking the tedium out of development. There were those who were doubtful about a system that has had a lot of hype, but hasn’t had the market infiltration to match it. Many people think that anyting that rises so quickly will only fall just as quickly. Will this happen to rails? No idea – only time can give us the answer.

However, I think there is an underlying factor here that has been over looked. The idea of frameworks designed specifically to speed up web development is what we should be getting excited about.

Web development, and to a degree, software development has changed. Customers are more than ever expecting cheap software that is good. It doesn’t make sense for us as developers to waste our precious time re-implementing the same parts of a system for different jobs. Introduction of frameworks that do this simply can only be a good thing.

One hurdle for many professional coders is the lead-time required for learning a new framework. Be the very definition, frameworks expect the coder to do things in a certain way. This may put many coders off, because they have to spend time learning, not coding and this costs money. What they may not realise, though, is that every hour they spend re-coding form validators instead of learning a framework that does it for them, adds up over time.

The old adage of work smarter not harder is extremely relevent here. There will never be more hours in a day. Trying to use all of them is impossible. Trying to improve productivity with out changes in thinking won’t work. We as web programmers know how this web thing works. The designers of these frameworks know how this web thing works. We really should be working together to work smarter.

Previous Next