Tuesday, 16 December 2008

PostgreSQL management on the iPhone

Back in the summer Bob Zurek (CTO at EnterpriseDB) persuaded me to spend some time on a simple iPhone application for remote administration of PostgreSQL and Postgres Plus. I decided to write it as a web app as I didn't really have the spare time to learn Objective-C to the level required and besides, there are certain advantages to handling most of the processing server-side - for example, paging of large result sets from arbitrary user queries can be made more efficient. As is often the way, other projects took over and it fell by the wayside despite being more or less complete, but I finally managed to find the spare cycles to get Sachin from our installer team to package it up (thanks Sachin) - and I'm pleased to say that as of today it's finally available through StackBuilder for those of you with an iPhone or iPod touch.

So, what does it do? Not a massive amount admittedly - it's designed primarily for emergency maintenance (and frankly, who wants to do their day to day work on a phone?), but as can be seen from the main menu there are options to view server info, connections, GUC variables, locks, prepared transactions, and the ability to run arbitrary SQL queries.

The Info tool for example, displays various details of the server you're connected to. The installer will setup a connection to the local server, but you can add as many more as you like:


Probably the most useful feature is the ability to run arbitrary SQL queries. Batches of rows are summarised in a list, with the usual option at the end to get fetch the next batch. Selecting a row will display the complete set of values - the screenshot below captures the row details sliding across the display from the right:

If you want to have a go, just select the pgPhoneHome download in StackBuilder.

Oh... and while I think of it, we also updated the installer for the PostgreSQL JDBC driver to v8.3-604 at the same time.

Enjoy :-)

Friday, 5 December 2008

StackBuilder application updates

I've just published a number of updates to various StackBuilder applications (if you're not sure what Stackbuilder is, see my previous blog post which included a brief description). The updates available are:
  • ApachePHP has been updated to Apache v2.2.10 & PHP v5.2.6 (Linux 32/64 bit, OS X and Windows).
  • Drupal has been updated to v6.6 (Linux 32/64 bit, OS X and Windows).
  • mediaWiki has been updated to 1.13.2 (Windows).
  • psqlODBC has been updated to 08.03.0400 (Linux 32/64 bit, OS X and Windows).
  • EnterpriseDB Tuning Wizard has been updated to 1.2 (Linux 32/64 bit and OS X).
So, fire up StackBuilder and start downloading those updates!

Thursday, 4 December 2008

Going mobile with a Linux netbook

A friend of mine bought a Linux based Acer Aspire One netbook, and asked me to help get it working with her Three (a UK 3G network) mobile broadband dongle. It's not entirely straightforward to figure out, but is pretty easy once you know how.

Initial setup


- Click on Settings and run the Aspire's Live Update program to update the operating system with the latest patches. Reboot when prompted. Keep doing this until Live Update reports that all updates have been installed.


- Shutdown the Aspire, and plug in the Three modem.


- Boot the Aspire, and select the Mobile Partner app on the Connect tab.


- Wait for Mobile Partner to detect the modem.


- Select Tools -> Options, and the click the New button.


- Give the profile a name, such as 'Three mobile broadband' and configure the following options:


  APN type: Static

  APN name: three.co.uk

  Access number: *99#

  Username: three

  Password: three

  Protocol: chap


- Save the profile.


Daily use


- Boot the Aspire, and plug in the modem. If a file browser window opens, close it.


- Run the Mobile Partner app on the Connect tab.


- Wait for Mobile Partner to detect the modem.


- Click the Connect button.


- When Mobile Partner has connected, minimise (don't close) it, fire up the web browser and away you go!


And what's the PostgreSQL angle you might ask? There isn't one. Sorry.