Wordpress 2.9.0 Is Here!

wordpress-logo

The 2.9.0 version of Wordpress has been released some of the main new features include:

  • A “trash bin” feature, allow the restoration of deleted comments or posts.
  • Built in image editor, forget Photoshop! You can now scale, flip, rotate images directly in Wordpress.
  • Easier embedding of video, just post the URL and Wordpress will generate the embed code on its own.
  • Multiple updating of plug-ins, forget the days of having to go through and update each plug-in one by one.

Plus much more the 2.9 release of Wordpress incorporates over 500 tickets for bugs and enhancements.

So what are you waiting for download it now here!

leave a comment

December 19th, 2009 at 11:58 am

Posted in Open Source

Setting Up PowerDNS With A MySQL Backend On Ubuntu 9.10

Bind9 has treated us well over the years, but its lack of support for database back ends in a default install is very annoying, especially when an application needs to control DNS services dynamically. PowerDNS is a powerful alternative it supports a wide variety of back ends and can also be configured to serve different records dependant on the clients Geographical location making it a valuable asset in these coming days of private clouds gaining traction.

This article will walk you through the process of setting up a PowerDNS server with a replicated MySQL back end on two Ubuntu 9.10 systems.

Step 1 – Configuring the Master Nameserver

This nameserver is going to be your primary server, any changes that need to be made to the DNS records are made on this server and they will be replicated on the the slave. To get started log into your primary name server via SSH and execute:


apt-get update
apt-get install apt-get install pdns-server pdns-backend-mysql mysql-server

When prompted by the installer create a password for the MySQL root user and then configure the MySQL service itself:

pico /etc/mysql/my.cnf

Go down to line 53, it should look like the line below comment it out.

bind-address = 127.0.0.1 <- becomes -> # bind-address = 127.0.0.1

This is needed so the slave server can talk to the master and be aware of any changes made to its records. Save the file, then restart the MySQL service to make your changes active.

/etc/init.d/mysql restart

Okay now its time to sort out the database side of things by creating a MySQL user for PowerDNS to use and the database for the storage of its DNS records:

mysql -u root -p

Whilst in the MySQL client execute the following commands:

CREATE DATABASE dns_server;

GRANT ALL ON dns_server.* TO ‘pdns’@'localhost’ IDENTIFIED BY ‘pdns_pass’;

NOTE: Be sure to change the password for the pdns user to something a tad stronger.

GRANT ALL ON dns_server.* TO ‘pdns’@'localhost.localdomain’ IDENTIFIED BY ‘pdns_pass’;

FLUSH PRIVILEGES;

USE dns_server;

CREATE TABLE domains (
id INT auto_increment,
name VARCHAR(255) NOT NULL,
master VARCHAR(128) DEFAULT NULL,
last_check INT DEFAULT NULL,
type VARCHAR(6) NOT NULL,
notified_serial INT DEFAULT NULL,
account VARCHAR(40) DEFAULT NULL,
primary key (id)
);

CREATE UNIQUE INDEX name_index ON domains(name);

CREATE TABLE records (
id INT auto_increment,
domain_id INT DEFAULT NULL,
name VARCHAR(255) DEFAULT NULL,
type VARCHAR(6) DEFAULT NULL,
content VARCHAR(255) DEFAULT NULL,
ttl INT DEFAULT NULL,
prio INT DEFAULT NULL,
change_date INT DEFAULT NULL,
primary key(id)
);

CREATE INDEX rec_name_index ON records(name);
CREATE INDEX nametype_index ON records(name,type);
CREATE INDEX domain_id ON records(domain_id);

CREATE TABLE supermasters (
ip VARCHAR(25) NOT NULL,
nameserver VARCHAR(255) NOT NULL,
account VARCHAR(40) DEFAULT NULL
);

Then exit the MySQL client with the command:

exit;

Alternatively if you don’t feel that comfortable using the command line MySQL client you could install phpmyadmin and use that to create the database and user within web based environment.

Now that the database has been setup we need to configure PowerDNS to use our newly created MySQL database and user for any lookups it needs to make.

pico /etc/powerdns/pdns.conf

Go down to line 82 or thereabouts and find the line:

# launch=

Uncomment this line and modify so that it reads:

launch=gmysql

Edit the file /etc/powerdns/pdns.d/pdns.local

:

pico  /etc/powerdns/pdns.d/pdns.local

Add the following lines so that PowerDNS can connect with the MySQL service.

gmysql-host=127.0.0.1
gmysql-user=pdns
gmysql-password=pdns_pass
gmysql-dbname=dns_server

Save the file and its show time, just restart the PowerDNS service for your changes to take effect and the DNS side of your server should be good to go!

/etc/init.d/pdns restart

Step 2 – Setting up PowerAdmin

Okay its working but not very useful at the present, as it has no DNS records to serve. So lets install PowerAdmin so we can manage our DNS records using a web based interface. I am assuming the server you are working on already has Apache2, PHP and its modules installed already. If this is not the case you will need to install these before continuing as they are required for the operation PowerAdmin.

PowerAdmin also requires the mdb2 module to work properly, which i doubt many people will have installed already. So:

apt-get install php-mdb2-driver-mysql

Or on some older versions of Ubuntu it wont be in the repository so make sure you have PEAR installed and

apt-get install php-pear
pear install MDB2-2.5.0b2
pear install MDB2_Driver_mysql-1.5.0b2

Then continue the poweradmin install with:

cd /tmp
wget https://www.poweradmin.org/download/poweradmin-2.1.3.tgz
tar zxvf poweradmin-2.1.3.tgz
mv poweradmin-2.1.3 /var/www/poweradmin
cd /var/www/poweradmin

Now the code base is in place open your browser and point it at the Poweradmin location to continue the install process e.g http://ns1.mydomain.com/poweradmin/install

Follow the install instructions and when you reach step 6 of the install process copy the PHP code displayed on screen, go back to your terminal window create the file:

pico /var/www/poweradmin/inc/config.inc.php

Then paste the code from the browser window into the new file and save.

NOTE: The browser gives you the code with white space between some of the lines make sure these have been removed before saving the file. Otherwise after logging in you will be greeted by a “Warning: Cannot modify header information” PHP error.

Step 7 is the last step of the install process and simply asks you to delete the install directory. If you fail to complete this step, the program will not let you login!

rm -rf /var/www/poweradmin/install

The operation of PowerAdmin is pretty straight forward although if you have only used Bind in the past you may find some of the terms a little confusing. A quick look at the PowerDNS documentation should point you in the right direction though.

Step 3 – Replicating Changes on the Slave Server

Log in to the server you will be using as your MySQL slave. Update the repositories and then install the MySQL server application:

apt-get update
apt-get install mysql-server

On your master server edit the /etc/mysql/my.cnf file go down to around line 92. Uncomment and modify the lines that regard replication so they resemble:

server-id = 1
log_bin = /var/log/mysql/mysql-bin.log
expire_logs_days = 10
max_binlog_size = 100M
binlog_do_db = dns_server

Save your changes to the file and then open up the MySQL client to create a new user for the replication process:

CREATE USER ‘replication_user’@'192.168.0.2′ IDENTIFIED BY ‘mypassword’;

GRANT REPLICATION SLAVE ON * . * TO ‘replication_user’@'192.168.0.2′ IDENTIFIED BY ‘mypassword’;

NOTE: replace the IP address ‘192′.168.0.2‘ with the IP of your slave server, and change the password to something a bit stronger than ‘mypassword

Now edit the /etc/mysql/my.cnf file of your slave server and append the following lines after the [mysqld] declaration so that the slave can connect to its master:

server-id=2
master-host = 192.168.0.1
master-user = replication_user
master-password = mypassword
master-port = 3306

Be sure to change the ip address of the master server and the users password to match your setup. Save the file and restart the MySQL service on both the Master and Slave nodes so that your changes will take effect.

On the slave now use the mysql command line tool and execute the following commands:

start slave;
show slave status\G;

You you should see something like:


*************************** 1. row ***************************
Slave_IO_State: Waiting for master to send event
Master_Host: 192.168.0.1
Master_User: replication_user
Master_Port: 3306
Connect_Retry: 60
Master_Log_File: mysqld-bin.000001
Read_Master_Log_Pos: 98
Relay_Log_File: mysqld-relay-bin.000002
Relay_Log_Pos: 236
Relay_Master_Log_File: mysqld-bin.000001
Slave_IO_Running: Yes
Slave_SQL_Running: Yes
Replicate_Do_DB:
Replicate_Ignore_DB:
Replicate_Do_Table:
Replicate_Ignore_Table:
Replicate_Wild_Do_Table:
Replicate_Wild_Ignore_Table:
Last_Errno: 0
Last_Error:
Skip_Counter: 0
Exec_Master_Log_Pos: 98
Relay_Log_Space: 236
Until_Condition: None
Until_Log_File:
Until_Log_Pos: 0
Master_SSL_Allowed: No
Master_SSL_CA_File:
Master_SSL_CA_Path:
Master_SSL_Cert:
Master_SSL_Cipher:
Master_SSL_Key:
Seconds_Behind_Master: 0
1 row in set (0.00 sec)

Now test it by creating a record on the master and with any luck you will also be able to see it on the slave. That said i stuffed around a bit when setting mine up and the slave service wouldn’t start as it was looking for the wrong bin file on the master. I was able to follow these instructions though to point the slave in the right direction to get it working again.

leave a comment

December 1st, 2009 at 12:21 pm

Posted in Linux, Sysadmin

Tagged with , , ,

Zend Framework 1.9.6

zf_logo_whiteZend Framework 1.9.6 has been released today with over 60 bug fixed included, most of which where found during the bug hunt days last week. The official Zend Framework site reports this release is planned to be the last before the 1.10.0 release.

The new release can be downloaded here, and a full list of the changes in this release the change log can be found here.

leave a comment

November 25th, 2009 at 10:23 pm

Posted in PHP

Tagged with

Firediff For Tracking DOM Changes

A major problem with developing AJAX applications is trying to follow data flowing back and forth between the server and client and the changes being made to the DOM.

Enter FireDiff to ease the pain! Firediff is an extension for Firebug that adds a change monitor, logging all changes made to the CSS and DOM. Which makes it a must for most web developers, FireDiff requires Firebug 1.4 or higher to work, and you can find the latest version to install from http://www.incaseofstairs.com/download/firediff/

leave a comment

July 2nd, 2009 at 2:59 pm

Posted in Uncategorized

Online Games to be banned in Australia

Everyone’s favorite communications minister Stephen Conroy today confirmed what had long been suspected. That under the new filtering regime online “adult” games of those perceived to have adult elements such as Second Life will be banned in Australia.

This will apply to all flash games, downloadable games and sites that sell games that do not meet Australia’s limited MA 15+ classification.

Shameful! Read the full story here.

leave a comment

June 25th, 2009 at 11:36 pm

Posted in Uncategorized

Google opens up internal speed tool

The loading time of a webpage is crucial it can mean the difference between a user staying to enjoy your content or heading to a competing site to find the information they are after.

Google up until today has been using an in house tool called “Page Speed”, similiar to the Yahoo Y-Slow plugin to aid developers.

Today Google has released the tool to the developer community for download and use to optimize the loading time of their own sites.

Quote from the Google blog:

 

 

For example, Page Speed automatically optimizes images for you, giving you a compressed image that you can use immediately on your web site. It also identifies issues such as JavaScript and CSS loaded by your page that wasn’t actually used to display the page, which can help reduce time your users spend waiting for the page to download and display.

leave a comment

June 5th, 2009 at 12:46 pm

Posted in Uncategorized

Client Negotiations

If you have ever done any freelancing or run your own business you have no doubt come across clients like this. For some reason they won’t pay full fare but want full service and will hound you relentlessly for not allowing them to screw you over if you try and walk away!

 

leave a comment

June 4th, 2009 at 10:33 pm

Posted in Uncategorized

Jailbreaking An Ipod Touch 2nd Generation

I have had my ipod touch (2.2.1 firmware) now for almost two months and i have found it to be a great little gadget. Although i have continually been annoyed Apple’s efforts to cripple the applications available through the itunes app store eg no last.fm scrobbling, having to sync to itunes to retrieved episodes of subscribed podcasts.

Last week i decided enough was enough and the only way around the limitations from Apple was to jail break the gadget. I found a lot of the guides on the net easy to follow but it still seems a bit of an inexact science and i ran into plenty of issues. After first trying i had to lived with a bricked ipod for a few days until i could find the time again to fix it properly. First i tried Quickpwn this technique seemed to give me an error of the #1600 variety when trying to restore my custom firmware in itunes.

Next up i went with the RedSn0w 0.3 beta, this script was pretty smooth although after running it the ipod just seemed to reset into recovery mode again with no forward progress. I then tried Voltage reading around the net people seemed to be saying good things about this one, but alas it also let me down due to a bug, so refused to find my original Apple firmware.

By this stage i had wasted a lot of time and was starting to lose hope in ever finding freedom from the itunes appstore, that was until Quick Freedom. I restored my ipod back to it’s default state for what seemed like the 100th time ready to have my hope crushed by another 1600 error. But this time it was different i glanced down at my ipod whilst itunes told me “preparing ipod for restore” only to see the pengiun wallpaper i had selected when i created the custom firmware.

Another 15 minutes later and the custom install had successfully completed offering me the “installer” and “cydia” applications after rebooting. For anyone hoping to jail break their devices i give two pieces of advice. First although most of the youtube videos are only 10 minutes long showing how to jailbreak an ipod by the time you get all of the software together and find a method that will works for you. Be prepared to spend a huge amount of time getting it done. Second if a method dosent work for you return right back to the start with the default firmware before trying again. I found trying to charge ahead and skipping this step will only lead to failure and more wasted time.

Happy jail breaking!

leave a comment

May 17th, 2009 at 5:30 pm

Posted in Uncategorized

Australian Pirate Party

The Pirate Party in Sweden seems to be making waves after four men where found guilly of helping run the infamous bit torrent tracker site known as The Pirate bay.

It seems though Australian may not have to wait to long for a Pirate party of it’s very own! The domain has been registered and a basic site built to gauge support for the planned party, with the group currently working on a constition based on the Pirate manifesto which can then be submitted to the AEC.

leave a comment

May 6th, 2009 at 1:34 am

Posted in Uncategorized

Jaunty Jackalope Is Here!

The day has finally come and the latest release of Ubuntu 9.04 (Jaunty Jackalope) is available for download.

So Whats Been Improved?

 

  • Easier configuration of multiple monitor setups
  • A number of video cards now have free drivers available
  • Significantly faster boot up times
  • Support for the ext4 filesystem
  • Improved range of wireless and 3g devices supported
  • Intelligent switching between wireless and 3g connections
  • The server version comes with Eucalyptus, allowing you to play with cloud computing before paying money for the likes of Amazon’s ec2

 

Can I Upgrade From 8.10?

Sure, just press the ALT & F2 keys, in the dialog box that appears type update-manager -d.This should open up the update manager which will tell you a new release is available. To get the ball rolling simply press the upgrade button the next screen will show you the realease notes for Jaunty. Press the upgrade button down the bottom of this screen and the system will go have a look at what pakages it needs to complete the upgrade.

If no issues are found a window will eventually pop up asking you if you would like to start the upgrade. Pressing the “start upgrade” button on this dialog box will then start the upgrade in earnest downloading all the packages it needs and then installing them. Be forewarned the actual upgrade can take a long time especially if you have a slow connection or are not getting great speeds from you mirror of choice.

When the process is done you will be asked if you want to remove any obsolete packages, just click the “remove” button to continue . The next dialog box will inform you the system requests a restart, click the “restart now” button and wave goodbye to Intrepid Ibex and hello Jaunty Jackalope. Upon restart if you want to be absolutely sure you didn’t get short changed open up a terminal and type sudo lsb_release -a, you will be told what version of Ubuntu you are currently running in the output.

 

Links

Ubuntu

Kubuntu

The Ubuntu Forums

Ubuntu 9 Tweets

leave a comment

April 23rd, 2009 at 10:02 pm

Posted in Uncategorized

SEO Powered by Platinum SEO from Techblissonline