Confessions of a Guru....

30 May 2005

Ubuntu Upgrade

Wow :) I inserted my freshly downloaded "Hoary Hedgehog" CD, did a md5 check on it (md5sum -cv md5sum.txt) and then did this to upgrade from the previous release (Warty)

apt-cdrom add
apt-get dist-upgrade all

It took about 20 minutes and it *seemed* to work!

Custom Search

29 May 2005

/home sweet /home

We've moved! We're in our new big house (renting) and man, what a relief it is to be in town rather than stuck 30 mins south of town on the coast. Taieri Mouth, while it is a nice place is just too far away from anywhere to be comfortable - it's great to visit in the weekends and holidays but just too far for socialising.

So yep, here sit I in our lounge with a wireless connection back to my internet gateway - just plain old DUN on a WinXP machine, but I want to fire up an old p233 or similar and use it as a firewall/router.

So yay! Come visit, come stay - heaps of room for all, but please give me a shout first :)

Custom Search

28 May 2005

Predictive Text Oddities

Predictive text is a wonderful thing but it would be a bit too much to put every concievable word into the dictionary. I sometimes run into this limit, not that my eloquence ascends to unattainable altitudes while I txt, but just plainly because there are so many words in the English language.

Anyway, today's oddity is: pottering => routeshog

The odd thing about this is that a Google search for routeshog turns up nothing at all ... well I suppose give it a few weeks while the Google spiders feed themselves and it will ;)

Custom Search

110% dedication yields results

My perseverance and dedication to the task at hand paid off nicely last night - I'm now onto the second island on GTA:SA. It's not hard to get there, you just have to work your way through the missions but I got horribly hooked by the gang warfare and took all the territories on Los Santos over the last 10 hours or so of game play time.

So, lots of new things to explore - Mt. Chiliad is one big mofo and heaps of fun to barrel down on a mountain bike (or a tractor for that matter). I have borrowed the GTA:SA guide from Shannon (thanks mate) which is good to look at after you try the missions. I know there's heaps of SA resources on the 'net but it's more fun to play through unaided first.

Heaven!

Custom Search

27 May 2005

Pear::DB, what's the point?!

What the hell is the point of implementing the Pear::DB package in PHP when there are blatant differences across the different OpenSource SQL implementations? Don't get me wrong though, Pear::DB is fantastic and I wouldn't use anything else, but consider these two SQL's:
PostgreSQL:
SELECT "Bob" || "Brown" AS name;
+----------+
| name |
+----------+
| BobBrown |
+----------+

mySQL:
SELECT "Bob" || "Brown" AS name;
+------+
| name |
+------+
| 0 |
+------+
Why is there a difference? It's because the || operator in PostgreSQL is used to concatenate strings. In mySQL it is used as an OR operator (the CONCAT() function is used to concatenate string). Arrgh! How on earth do we code SQL to be truly cross database compatible?

I'm still looking into this one and will post again when I find a solution ... *grumble*

Custom Search

20 May 2005

PHP Servers

Looking for something new to play with in your journey to become a PHP guru (like me)? Try writing servers! Start off by looking at the socket_create() function and then once you got the hang of that, look into the Server tree of objects in the PEAR repository.

By using Server/HTTP, you can make your own web server with just a couple of lines of code:

require('HTTP/Server.php');
$ws = new HTTP_Server('127.0.0.1','80', 'Sequential');
$ws->start();

You can then point your web browser at http://localhost:80/ and it will serve you pages - blank pages, but pages nonetheless. You can extend the HTTP class to handle your GET/POST (etc) requests. I wrote a webserver that would render a POVRay scene on demand with a URL like http://localhost/pov/filename.pov/800/600/

The coolest thing is that because you handle the GET requests yourself (i.e., you have to parse them and do something useful with them), you determine exactly what happens.

This way of using PHP interests me so much that I'm thinking about writing a bit of a servery suite for doing useful stuff (pretty intriguing, eh ... NOT!)

Custom Search

Spam Spam, Glorious Spam

I'm back with my old company (Opus) and I was getting annoyed with the spam that I was getting - about 3 or 4 a day. My email address was created back in 1997 - it hasn't existed for the last two years but now it has been called back into existence. Anyway, today I got the following in an automated system email:


The Opus e'mail system intercepts and puts aside incoming e'mail that is probably spam, and keeps it for two weeks.

Below is a summary of the 1178 email(s) you have NOT received in the last seven days. If however, you do want to receive any of these messages, select them in the left hand column, then click the "Send Me Selected Messages" button:


Fantastic! Looks like the system is doing it's job properly. By the way, that works out to one spam message every nine minutes - ouch.

Custom Search

15 May 2005

Webmin Install

When installing Webmin with the setup.sh script, note that it takes a second optional (but HIGHLY recommended) parameter which is the installation directory. If omitted webmin will be configured to run from the directory that you have untarred it into, which may be undesireable.

The best installation method is as follows:

bob@ubones:~/webmin-1.200 $ sudo ./setup.sh /usr/local/webmin

Then, follow the defaults and you will have it installed into /usr/local/webmin instead of /home/bob/webmin-1.200

Note: If you specify a directory that is NOT /usr/share/webmin (like I did above) then you will need to modify the webmin init script (/etc/init.d/webmin) to change the DAEMON setting to point to the location of miniserv.pl (that is the webmin main controller script - yeah, it's written in perl).

Custom Search

Laptop Linux

I went along to my first ever Dun-LUG (website down at the mo for some DNS-related reason) and had a good old natter with some of the local members. I also got a copy of Ubuntu linux (a variant of Debian) and decided that based on the number of people there with Linux on their laptops that I'd take the plunge as well and install it on mine.

It went well ... but the driver support out of the box was lacking, so much so that I wasn't able to configure my Atheros based Wifi adapter (from what I've read I see that Atheros is like the NE1000 range of NIC's - widely supported and emulated). After struggling with that problem for a day (it was keeping my new Ubuntu-top off the Internet, making support and diagnosis a pain in the backside) I decided to roll back to a dual-boot system.

I used the Toshiba system restore CD (and quickly un-installed it's AOL nastiness, et. al) and then used ntfs-resize to resize the C: drive from 60GB (100% of disk) to 35GB which should give gave me plenty of room to install Ubuntu. I had to do it this way because the Toshiba CD wouldn't give me the option of installing WinXP to a particular partition - it wanted the whole lot.

After that, I ran the Ubuntu install (it's "Warty" by the way, "Hoary" is available but beggers can't be choosers!) and created two partitions for it, /dev/hda2 (ext3) and /dev/hda3 (swap). Grub happily installed into /dev/hda0 and auto-detected Windows XP and added it to the boot menu. A quick tweak to the grub config file and a call to update-grub was all that was needed to set the default OS to WinXP and set some nice colours.

I then downloaded VMWare Workstation 5.0 (eval) and I have my WinXP system set up so that I can boot Ubuntu directly from the hard drive (no virtual disk files thank you very much) and if I want to boot Ubuntu properly all I need to do is reboot my laptop and choose Ubuntu at the Grub prompt. This gives me the flexibility of having Internet access in Ubuntu (via VMWare's bridged networking) so that I can resolve the Wifi issue.

Fun and games! The scary thing is that it works nicely :) I did have to install gcc and linux-headers from the Ubuntu CD for the vmware-tools package to successfully install. This allows Xwindows to run properly inside VMWare, plus some other neat things like shared folders between host and guest OS's.

Custom Search

10 May 2005

Total Annihilation

We've retrieved many of the boxes that we put into storage before we left for the UK and amongst other things (such as a collection of 386 components that work, sans-case) I found my long-forgotten Total Annihilation CDROM. If you have it, be sure to download the 3.1 patch to address many issues and add extra functionality.

IMHO, TotalA is one of the best realtime strategy games to come out - it was ahead of it's time with completely 3D rendered terrains and units - you could see the front and sides of tanks and other units as they rolled over hills and rocky terrain. It's the only game I've played (other than Descent) that has made me jump out of my chair.

Now all I have to do is find the manual for it - I'm having trouble remembering the keypresses for unit selection etc. I've also found my old Age Of Empires II CDROM as well which Linda is getting into right now.

Custom Search

09 May 2005

Win32 Programming

Win32 has been around for ages - since Windows 95 if I'm correct. I used to program in Delphi heaps and really enjoyed it. I've had a hankering to get back into Win32 programming and so I hunted around on the 'net today and found WinBinder. WinBinder is an extension for PHP that allows it to interact with the Windows GUI. Check out the examples. The main thing I like about this is that since I use PHP pretty much exclusively nowadays I can get back into Win32 programming without a) having to download any warez and b) without having to re-learn Delphi or pick up Visual C++ (or similar).

Still not quite sure where I want to go development-wise - I've started to see great potential in using localised PHP (i.e., not running on a webserver) for application development. Bring it on!

Custom Search

06 May 2005

Strange Grafitti

Twice in two days I have now seen strange grafitti on walls. The first one was on a sign for a construction company whose slogan read 'We Build'. Someone had continued the slogan with '... spaceships for corporate aliens'. I don't know what it was but there was something about that prose that grabbed me and made me chuckle.

The second was 'Soup is real good food', written on a board in the Scarfie (student) area in Dunedin. Again, my body convulsed slightly as my GSOH was tickled.

Custom Search

04 May 2005

Relief

A great weight has just been lifted from my soul. I have finally properly done what I should have done a long time ago. I have turned over a new leaf and I'm feeling nothing but good about it. Sorry, I know there's no details there but I just had to blog this event, more for my sake than yours.

Custom Search

03 May 2005

Marketing creates new techincal challenges

Today I went into Dick Smith Electronics (similar to the UK's Maplin's stores) and bought a new mouse. It cost me $28 - not bad considering it's a nice hold, scroll-wheel optical mouse but one thing did strike me as odd - it's a "Optical 3D Mouse". Now this concerns me greatly and I feel as if I have been cheated.

After I plugged the mouse in I found I was only able to move the mouse pointer in TWO dimensions. I cannot work out how to access the third. Even if I do manage to work it out, I'm sure my laptop doesn't support the third dimension (depth in this case, left-right and up-down seem to be fine).

It is of course possible that the product title refers to the fact that the mouse itself exists in three dimensions - but they have forgotten to include the fourth (and theoroetically the other 12 or so, I've lost count now) as this mouse definitely exists in the fourth dimension as well. If the title refers to the amount of matter that this product displaces in the current universe, why are other products not sold as such? How about Burger King's 3D Whopper or KFC's new 3D, 3 piece quarter-pack? The marketing guys have missed the boat there.

One final possibility exists - that the 'D' in '3D' doesn't stand for 'dimension', in which case I shall leave it up to you to choose what it might mean.

Custom Search

02 May 2005

Legal software, if I could!

For quite a long time now I have been using a particular software package almost on a daily basis. I will confess right now that I have never bought a license for it and as such I am using an illegal copy of it. I decided that the time had come to buy it, and since I had seen a prior version for sale at a computer fair I thought I'd go online and buy the current version at the RRP which is about £80 or so.

As it turns out, the company has just been bought out by Corel and Corel don't seem to have it on their list of products yet - at least, not for Australia/New Zealand. I can't purchase it from the US website as I cannot select New Zealand from the country list for my credit card. When trying to purchase from the UK site, the price was the same in pounds as it was in US dollars - unless I'm wrong I think iTunes got done for charging different prices for online products from different countries (between UK & Europe).

So, I struggle onwards - the site doesn't work to select New Zealand, or Australia, or the entire Pacific Region for that matter. After genuinely trying for about 15 minutes with my credit card handy I gave up with a sigh of dispair.

So, here I am, still using it illegally. I'll buy it when I see it on a shelf.

Custom Search

Normality Ho!

Normality is on the horizon! Linda and I are now back in NZ (see our travel blog) and it won't be long before I can settle down again with a desktop PC and start to configure my network!

Two things for today's rather overdue post....

badblocks
badblocks is a linux utility that is the equivalent to the chkdsk /f utility that comes with DOS/Windows. It will ONLY scan a hard drive for physical errors. It does this in a variety of modes, read-only, read-write and read-write-destructive. The safest (and most informative) invocation of the utility is:

badblocks -s -v /dev/hda

This will merrily check your /dev/hda device for bad blocks. badblocks doesn't care what is actually on the device as it's not looking at filesystems at all. For that you want to use fsck or e2fsck (for Linux partitions only). I'm not sure but there may be a NTFS/FAT checker available as well. Check out the Linux NTFS Project. I highly recommend that you get a hold of a boot-from-CD version of Linux so that you can use it as a diagnostic CDROM. Knoppix is one such distro and you can get it at www.knoppix.de. It is a German-led project but there is a wide range of language translations available, including that English language thingy.

PortableThunderbird
It's just that. PortableThunderbird is a portable version of the popular Thunderbird email client. It allows you to install the entire program onto a USB key, CDRW or other removable media. In only a few minutes I had it installed and working on my 256MB USB key, along with a nifty autorun.inf file which fires up Thunderbird when I double click on the drive icon. I couldn't get autorun to fire up Thunderbird though for some reason. For reference, here's my autorun.inf file:

[autorun]
shell\mail\command=thunderbird\PortableThunderbird.exe
shell\mail=&Thunderbird
icon=thunderbird\PortableThunderbird.exe,0
shellexecute=thunderbird\PortableThunderbird.exe
shell=mail

So all I have to do is carry my USB key around with me (an easy habit) and I'm set for mobile email.

Custom Search