Is your Linux Timezone Reverting to UTC After Rebooting?

Being based in Perth (GMT +8), I have always thought it made sense to have our servers running in the Australia/Perth timezone (rather than UTC).

This makes sense for many reasons, mostly that when we set up a cron job, we can use local time (rather than UTC), which makes life very easy.

Recently our Rackspace Cloud servers and Amazon EC2 instances (both running CentOS) were rebooted after updating the glibc package, which caused each server’s timezone to revert back to UTC.

To set the timezone, I had always created a /etc/localtime symbolic link pointing to /usr/share/zoneinfo/Australia/Perth, however it turns out that there is one other thing that has to be done in order to make the timezone setting be persistent across updates and reboots.

Luckily, the solution was hidden away in the AWS user guide.

In addition to the symlink, it is also necessary to edit the /etc/sysconfig/clock file, and change it to your local timezone ( in my case ZONE="Australia/Perth" ).

After making both of these changes, be sure to reboot your server, and then use the date command to check that your server is still in your local timezone (rather than UTC).

Command Line WordPress with WP-CLI – WordPress Perth User Goup

Today at the WordPress Perth User Group October 2014 Meetup, I gave a presentation titled Command Line WordPress with WP-CLI.

These days my favourite uses of WP-CLI include:

  1. Performing search/replaces in the WordPress database
  2. Bulk importing/managing WordPress user accounts
  3. Installing WordPress
  4. Regenerating media library items

If you’re not already using WP-CLI, I suggest heading on over to and installing it.

The command line isn’t as scary as it sounds :)

Importing 1100 users into WordPress from a CSV file using WP-CLI

The Problem

A spreadsheet of ~1100 people (name, email address, etc) that needs to be imported into a WordPress site as users:

User Import CSV File
The User Import CSV File

I tried several user import plugins, but I had trouble with some users not importing (duplicate email addresses and/or usernames), and the plugins I tried didn’t make it easy to see which accounts were failing to import and why.

The import process via the WordPress dashboard was also encountering timeout problems due to the large amount of data being imported.

The Solution

WP-CLI’s user import command available to the rescue!

I used the following command to import the 1100+ user accounts:

wp user import-csv --skip-update user-import.csv

Note: this command skips user accounts that already exist because I included the --skip-update flag.

The output of this command made it very easy to identify the lines/users that were failing to import due to their email addresses already exist.

Bulk Deleting all Subscriber Accounts

I fixed up the duplicate data in the CSV file, and then used the following command to delete the imported user accounts before attempting the import again:

wp user list --role=subscriber --field=ID | xargs wp user delete --yes

Note: this command deletes ALL existing subscriber user accounts.

Once the imported accounts were deleted, I was able to retry the import using the command above.

Using WP-CLI for this ended up working great, and the import process was much quicker than using a plugin because I didn’t have to worry about server timeouts and other problems.

Are you using WP-CLI?

If you’re not already using WP-CLI, be sure to check out my previous presentation.

Melbourne to Perth: a 3700km road trip

In July 2008, I moved to Melbourne with a plan on staying for approximately 12 months.

It turns out I was completely wrong about that time frame, because after more than 5 years, I’m still here!

Quite simply, Melbourne has been amazing. I’ve had the time of my life.

Melbourne’s food, bar and sporting culture have been highlights. On the other hand, Melbourne’s weather has not been a highlight!

I’ve met some great friends, and explored some beautiful places.

I’ve bought a house in Melbourne.

I’ve also been really impressed by Melbourne’s tech community. In particular, being a part of the WordPress Melbourne User Group.

But best of all, I’ve been lucky enough to meet the love of my life, Jen.

The Future

After many discussions, Jen and I have decided to move to Perth.

In 36 hours time, Jen and I will be leaving Melbourne and starting our huge road trip to the other side of Australia.

Here’s the 3700km plan:

Melbourne to Perth Map

We’ll be taking our time on this journey – there’s plenty of sightseeing to be done along the way!

The trip even includes a short ferry ride across the Murray River!

We’re both really excited about starting the next chapter of our lives in Perth.

I’m looking forward to being closer to my family and long-time friends, and being surrounded by amazing beaches.

I’m also excited about being in the same office as my business partner and colleagues.

Melbourne, I will miss you. But you never know – we may even be back some day!

The WordPress Melbourne User Group: a 1200 day history and a look into the future

The History

In June 2010, Andrew Davis, Anthony Cole and myself met with the idea of reinvigorating the (then defunct) WordPress Melbourne User Group.

The discussions went well, and the following month we hosted the first meeting (which had 8 people in attendance).

1202 days later, I’m immensely proud to say that we have organised 47 WordPress Melbourne User Group meetup events (an average of 1.2 events per month), all of which have helped WordPress users learn and share their knowledge about WordPress and related topics.

The Thank You’s

I’d like to extend a sincere thank you to the following people and companies, who have all played a big part in making WPmelb a success.

The sponsors (past and present):

The venues (past and present):

The organisers (past, present and future):

The regular volunteers (past and present):

The speakers:

  • There have been in excess of 60 volunteer speakers (too many to list unfortunately).

The members and community:

  • Countless people have come along to our events to expand or contribute their knowledge
  • These people have also helped spread the word about the group, and encouraged their friends to join and attend.

As of today, we are lucky enough to have almost 1000 members.

Without all of you the user group would be meaningless.

Thank you.

The Future

With my impending move to Perth, tonight will be the last WPmelb event I attend for a while.

I’ve also stepped down as lead organiser, and I feel confident knowing that a talented and awesome team of volunteer organisers will be ensuring that the group grows and prospers into the future!

It’s been fantastic being a part of the WordPress Melbourne User Group over the last 3 and a half years.

I’ve met so many great people, learnt so many things, and had countless opportunities to share some of my knowledge with others.

If you live in or near Melbourne, and are interested in WordPress, I strongly recommend that you join the friendly group and come along to an event.

Command Line WordPress with WP-CLI

Tonight at the WordPress Melbourne User Group September 2013 Meetup, I gave a presentation titled Command Line WordPress with WP-CLI.




Are you already using WP-CLI? If so, please let me know what your favourite WP-CLI command is.

If not, I suggest you go to and give it a try :)

The Inaugural BeachPress Australia – August 2013 – Phillip Island, Victoria

A weekend where WordPress developers and/or businesses owners get together to write code, share ideas, collaborate on projects, and maybe even relax.

Do you like WordPress?

Do you like sharing ideas, stories and (GPL) code with like minded people?

Do you have an idea for a new plugin, and want to team up with someone to get it finished and published?

Do you have a WordPress project that you’ve been wanting to finish, but haven’t been able to find the time?

If you answered yes to any (or all) of those questions, then this weekend is for you!

Arrive Friday 16 August 2013 after 3pm.
Depart Monday 19 August 2013 by 9am.

A deluxe 5 star holiday house (including ocean views) in Phillip Island, Victoria:

(Photos courtesy of the holiday house’s owner)

What’s included?

  • 3 nights accommodation in Rhyll, Phillip Island, Victoria.
  • 7 meals (Friday dinner, Saturday breakfast, Saturday lunch, Saturday dinner, Sunday breakfast, Sunday lunch, Sunday dinner).
  • your own bed (including linen).
  • the opportunity to collaborate and have fun with some great Australian WordPress people!

How much?
$250 AUD per person (paid in advance).
Note: we are not going to profit from this event – any extra money will be spent on additional food/drinks/snacks for everyone.

What do I need to bring?

  • your laptop and charger
  • mobile phone (with mobile data) – wifi is not available, so we’ll need to use our phones for internet access
  • any alcoholic drinks
  • any specialist snacks/food
  • your wetsuit (if you’re crazy enough to swim during a Melbourne winter!)

Who is organising this?
James Collins and Aaron Rutley.
(Two WordPress developers from Melbourne, and organisers of the WordPress Melbourne User Group).

Can I come?
We are keeping the numbers small – places are limited to 10-12 people.
If you’re willing to sleep on the floor (instead of in a bed), it is more likely we’ll be able to squeeze you in.
So if you’re interested in coming, please contact me.

This event is now sold out. Please keep an eye on the blog if/when we organise another one of these events.

I can’t make it on those dates. Will there be another one?
No promises, but we’re really excited about this concept, and we’re hoping to make them a (semi) regular event in different locations around Australia.

Full disclosure: this event wasn’t my idea – recently in Portland, Justin Sainton organised an event called BeachPress, and he’s been kind enough to give me some advice and let me run a similar event in Australia.

Rackspace Cloud now available in Sydney, Australia

In August 2012, Rackspace announced that they were working on launching an Australian datacentre for their cloud offerings.

Today that dream is a reality, with the official announcement of their new Sydney-based datacentre:

Rackspace now have datacentres in 9 locations, including Australia, the UK, Hong Kong, and the USA.

Map of Rackspace Datacentre Locations
Image Credit: Rackspace Australia

I just logged into the Rackspace Control Panel, and here’s the proof:

Rackspace Control Panel - Add New Server
Rackspace Control Panel – Add New Server

I’ve invested many hours in AWS’ offerings, so I’m not planning on switching to Rackspace Cloud any time soon, but it is great to see more competition in the Australian-based cloud industry.

(AWS launched their Sydney datacentre in November 2012).