Archive for the ‘General’ Category

Sockets with JavaScript

We’ve seen a great push towards using JavaScript in modern websites, using AJAX and JSON for dynamic websites which start to feel more like applications instead of plain boring pages.   One of the problems which more interactive sites face is the constant polling of the web server due to the way HTTP works.  Various web apps these days tend to poll for data with the server keeping the connection alive without sending any data, once data has been sent then a new request is sent asking for more data.

One particular web app which isn’t that great is IRC web chat.  Most IRC servers are keen on users connecting from their real connection, as it’s hard to track abuse when connections are being proxied by a web server.  Using AJAX or JSON with a web server isn’t that ideal either, browsers have to constantly poll and refresh with the server to receive the data, this typically requires a light weight web server as Apache with PHP or Perl is hardly efficient for multiple users.  The most common approaches over the years has been CGI:IRC, but this is just yet another inefficient Perl script which keeps the connection open.  One of the oldest methods is using a hefty Java application, hardly friendly for users.

So, why not use sockets with JavaScript?  Obviously JavaScript can’t do it directly, but with Adobe Flash and something like socketBridge (or this improved version) you could control a socket with mostly JavaScript.  The only problem with Flash and sockets is that it would have to connect to a policy port before being authorised to connect to that particular port, however it would be a much lighter solution for the server compared to all the polling techniques.

I’m tempted to try and create a web IRC client using JavaScript and the Flash socket bridge.  Even if other IRC networks won’t open a port for Flash policy requests, you could do something similar to the other web chat apps – use your server as a proxy.

Mar10

Forwarding all mail with Gmail

If you’ve got multiple Gmail accounts, such as different Google Apps Gmail accounts (for hosted domains) and gmail.com accounts, being able to forward them all to one account saves a lot of time and effort.  Gmail does allow you to forward email under the Forwarding and POP/IMAP section of the control panel, however this only forwards non-spam emails.  As most people know, sometimes the spam filters aren’t quite perfect and suffer from false positives occasionally.

To forward all mail to another account, simply remove your existing forward, create a new filter from * (matches any sender), then forward it to your main email address – making sure you’ve got Never send to spam selected.  You’ll probably want to choose Delete it as well, this means any incoming mail on that specific account will be forwarded and deleted on the original account – but you’ll still have 30 days until it gets removed from trash.

This way you’ll get all mail forwarded from Gmail – including spam.  Now you can see all the spam from any other Gmail accounts incase there are any false positives.

Mar09

Adverts in RSS feeds

RSS feeds are great for those people who want to follow up on news sites without having to constantly revisit the same site multiple times a day.  Google FeedBurner offers nice statistics to any sites with RSS feeds, allowing them to see how many subscribers they’ve got by hosting the RSS feed.  What I’m finding increasingly annoying is the other service which FeedBurner offers – their advertising programme.

I don’t mind if RSS feeds are either partial feeds to show users the first paragraph to attract users to visit the site, or full feeds to show users the entire article, however putting in adverts is highly annoying.  To me RSS feeds are there to entice me to go and visit the site itself.  RSS feeds are mostly used by fairly technical users – putting in adverts where the people reading them are most likely to ignore them seems a bit pointless.  Adding other little buttons/icons to enhance the feed is annoying as well, I just want the article and nothing more!

I don’t usually bother with advert blocking, but after seeing more feeds with adverts in I’ve finally installed Adblock Plus for Firefox.  Good riddance to pointless adverts!

Dec29

Cables not included

To me this is one of the most annoying things manufacturers decide on when releasing their products – not including all the cables necessary to use the product!

Various USB printers have done this for quite a while, you have to buy the cable separately.  Whilst it’s sometimes understandable with cheap products, it’s still slightly annoying that the product you buy isn’t usable until you go and buy yet another cable.  What I find really annoying is spending £300 on a console such as the PlayStation 3 and they’re too cheap to include an HDMI cable.  This is a console designed for high definition gaming, yet they don’t even bother including a cable for it.

It feels like the modern equivalent of “batteries not included”, certainly not something which should happen if you spend large amounts of money on a new device.

Dec25

Poor Windows Vista support in games

As much as people might dislike Vista, it’s the operating system bundled with new machines and it’s here to stay.  It’s been around 2 years since Vista was launched, whilst I can understand certain software developers might not offer support from the immediate release – it should be one of their high priorities.  MMORPG developers seem to be among the worst for poor Vista compatability, along with other game developers.

Certain games decide that they need to run as Administrator from the moment the patcher starts up, even though the patcher might not need to download any file at all – therefore not needing to write any files to the Program Files directory.  So the entire game runs under admin privileges, just incase the patcher might need to update files – Mythic Entertainment are guilty of this with Dark Age of Camelot.

Other games are still living in the old days where they still write any configuration files to the game directory for all players, instead of the relevant application data directory for the user.  This is just extremely lazy and makes things awkward for users, instead of a clean split between game data and user data – everything is just lumped together in one directory.  If I wanted to make a backup of my computer, it would be far easier to just backup my user profile which would contain any important data – however keeping this data along with the game itself makes it difficult.  If I wanted to restore my machine from a backup, I’d lose any settings from the game.

There are other games which are complete failures, getting players to go with workarounds such as changing the permissions on the installation directory.  After installing Lord of the Rings Online I didn’t even get a shortcut to the game from my start menu.

If game developers could just put a bit of extra effort into game installation it would make things so much easier.  I know the aim of these developers is probably just to get the game running on these platforms, but a fully functional game which works properly would save users so many headaches.

Nov19

Server Name Indication being held back

Ever since we’ve had websites available over HTTPS (HTTP over SSL), there has always been the problem that the host always requires an IP per site as each site needs a new certificate.  With SSL the server couldn’t just switch certificate according to the site, as SSL is negotiated before any HTTP request is sent.

Server Name Indication is a TLS extension which sends the hostname during the TLS negotiation, which means the server can switch to the appropriate certificate – allowing a web host to potentially have as many HTTPS sites as they want on a single IP address.  It’s a great solution, however the only problem is that any chance of it’s currently being held back.

Firefox 2.0, Opera 8.0 and even Google Chrome supports SNI, however Safari on OS X currently doesn’t support it and Internet Explorer 7 only supports it on Windows Vista and not Windows XP.  So SNI is being held back due to a lack of support from IE and Safari, these are two fairly significant browsers which many people use – admins can’t ignore either of them.

SNI is only just becoming available in Linux distributions with Apache 2.2.8 and the latest versions of OpenSSL, so it isn’t available to everyone just yet.  However being unable to use it for many years due to the fact that any Internet Explorer user on Windows XP won’t be able to view any SNI sites is going to be a huge hinderance towards adopting it.

Oct17

3ware 8006-2LP RAID with CentOS 5

The Hetzner DS-8000 servers feature a 3ware RAID card (8006-2LP) for hardware RAID 1, a nice feature – although the default CentOS setup is slightly broken with SELinux.  After several hours of wondering why smartd wouldn’t work, /var/log/audit/audit.log reveals the following:

type=AVC msg=audit(1223922183.059:22): avc:  denied  { getattr } for  pid=2654 comm="smartd" path="/dev/twe0" dev=tmpfs ino=8940 scontext=user_u:system_r:fsdaemon_t:s0 tcontext=user_u:
object_r:device_t:s0 tclass=chr_file

A good administrator will probably want to add some custom SELinux policies, but the lazy admin might just want to disable SELinux.  I went with the disabling of SELinux as the easier option!  It’s not a recommended solution though.

Eventually I got smartd working again, so I’ve now got decent monitoring of the disks on the machine.

Oct14

Using Linux but never giving back

One great thing we see with Linux is that it’s used for servers quite frequently, it’s probably one of the strongest points about it. A strong and stable server platform which many companies rely on to run many parts of their infrastructure for an organisation.

A common situation we’ll see are MMORPGs, games with thousands of players mostly with Windows clients connecting to servers powered by Linux.  Occasionally you’ll see people trying to run their game client under WINE, but it isn’t quite the same as running a native game.  These companies use Linux to run their gaming servers, web servers and possibly many other parts of their infrastructure, but when it comes to building a Linux client for their game they’ll rarely consider it or even dismiss it without even considering the feasibility of it.

I don’t think anyone expects companies who use Linux to start contributing hundreds of lines of source code back to various projects, but it would be nice if they considered a Linux client of their product where it’s viable as a way of saying thank you. They’re getting the benefits of many hours of effort being placed into a freely available operating system, but they’re not helping this operating system by refusing to release their product for it.

In an ideal world we’d see multi platform clients, maybe we’ll see more if it one day.

Sep30

Ubuntu on the Aspire One

Okay, I didn’t last long. After 24 hours of sticking with Linpus I eventually decided to install Ubuntu on the laptop, even though adjusting it for the Aspire One was going to involve some tweaking – sticking with Linpus would’ve ended up annoying me.

The AspireOne page on the Ubuntu wiki explains how to get you Ubuntu up and running.  The Aspire One supports PXE booting, which I found far easier to setup than fiddling about with a USB stick just to get the install going.

The Ubuntu Netbook remix includes some great packages which are useful for running GNOME on a small screen, I did try them all however I wasn’t too happy with the UME launcher.  I’d highly recommend Maximus, an application which maximises open windows and removes the top bar from running programs, window-picker-applet which is ideal with Maximus and doesn’t hog too much space for switching between programs, and human-netbook-theme for a few visual tweaks.

Overall I’m fairly happy, now I’ve got the power of Ubuntu for this laptop.  Hopefully the weird quirks and bugs which the Aspire One has will be ironed out in future releases.

Aug26

Acer Aspire One

After resisting the EeePC for so long in the hope that better ultra portable laptops would appear with better specs, I finally decided to go for an Acer Aspire One.  The 8GB flash storage and 512MB RAM are perfectly adequate for basic use in Linux, it’s a great little device for browsing a few sites without having to take a huge laptop around with you.

The Aspire One comes with Linpus Lite, a Fedora based distribution aimed at lightweight devices.  After using it for a day it seems reasonably adequate for an average user, but for someone who understands Linux well might get a little bit annoyed at the quality of this particular distribution.

This version of Linpus Lite is based on Fedora 8, slightly out of date as it was released back in November 2007.  Firefox 2 is included, which is also a little bit old and support is ending shortly as Firefox 3 has been out for quite a while.  I suppose this is sort of expected with the fast pace of change, but it’s slightly annoying.  The one thing I did try to do is run yum upgrade from the command line, however the dependencies are broken so it won’t update – not exactly great.

I’m keen on replacing Linpus with Ubuntu in the future, however the support for the Aspire One isn’t quite complete at the moment with some functionality not quite working.  I’ll keep track of it for the future, however I want ease of use instead of having to deal with command line tweaks to fix broken functionality.

Overall a thumbs up for the Acer Aspire One, but a bit of a thumbs down for Linpus Lite.  I just wish they could’ve sorted out Ubuntu for this device.

Aug23

Pages

Categories