Skip navigation.
Sponsors
Recent comments
Thingy Ma Jig

Free Christmas Wallpapers

30
Nov
2008

As part of my RSS reading, Smashing Magazine is rapidly becoming something I look forward to reading. Every month they do a roundup of desktop wallpapers which include a calendar and are, in some way, seasonal. This month is no exception! They have a fantastic selection of christmassy wallpapers for you to chose from and they're all free!

Backing up a Drupal Database

26
Nov
2008

I was just dumping a database using mysqldump and I noticed that tables such as cache (and its cousins cache_page, cache_menu, etc), sessions and watchdog can be pretty big and are also not often essential for backing up. I mean, when you restore your web site do you really care about restoring people's logged in sessions from when the backup took place? I can understand maybe keeping watchdog; but then again should you lose your site you would probably lose it several hours after the backup so would miss out on any relevant watchdog notices.

Anywho… I did a mysqdump for a large database for a website I maintain and the dump came out at 400Mb. I then spent a few minutes cobling together a small script which would do a mysqldump but had some pre-programmed Regular Expressions to match specific groups of tables which it would only dump the structure for (ie, no data). After running this script, the SQL dump was only 220Mb. Much better! It also runs considerable quicker too and will cause less table locking.

So - the script?

SVN + NFS = svn nfs cant get exclusive lock

25
Nov
2008

Last night I was trying to configure SVN on a server. The setup was that the SVN Repo was on "srv2" and the frontend and code I wanted to import was on "srv1".

I created an NFS share on srv2 and mounted it on srv1 in /mnt/svnroot. The mount worked perfectly and I could touch and remove files from srv1.

So I tried to create a "sites" folder where I wanted to import a site I wanted to version control. This is where I started to have problems… The sollution was to add "nolock,bg" to the mount options on the client. Read on for more details!

List enabled services in Linux

21
Nov
2008

Today I needed to list all of the services which were enabled on boot-up for one of the servers I maintain. Obviously, my first port of call was to use the nifty tool ChkConfig like so…

Upgrading Netgear DG834PN

14
Oct
2008

Something I thought I'd post up quickly which caused me a little trouble just now…

I tried to upgrade my Netgear DG834PN (an ADSL WiFi router, EXCELLENT piece of kit incidentally) from the stock 1.3.30 firmware to the latest (as of writing) 1.3.39. There was no particular reason for the upgrade - I'm just a "bleeding edge" kinda guy!

Relevant Content gets some love

25
Sep
2008

Druplicon tag cloudI while ago (almost a year!) I released a module called Relevant Content to the community. This module executes a relatively lightweight SQL query which pulls up other nodes and sorts them by how many terms they have in common with the current node you're looking at. This provides a rudimentary method of suggesting other content to visitors to the page. It also provides a way of teaching search engines about other potentially relevant content.

Abessive For Drupal 6

15
Sep
2008

My first theme, Abessive, gets a new release today for Drupal 6. Turns out to be a pretty easy upgrade!

In case nobody caught onto what Abessive was the first time; it is an (almost) image free theme with flexible 1, 2 or 3 column layout (depending on where/if you place any blocks). Each block/section has rounded corners and slight top & bottom gradient which is achieved using only CSS techniques involving margins, padding and background colours. This makes the theme very lightweight and elegant at the same time.

Abessive Screenshot

Using Tar and SSH to improve SCP Speeds

03
Sep
2008

I am currently in the process of migrating several dozen sites between two servers. I tried using scp command to copy the sites over however scp is a very slow command when transferring many small files.

I did a little research on how to use tar over an ssh connection and realised that you could specify the stdout on tar.

Vim and Drupal Modules

18
Aug
2008

I just finished upgrading a server to Ubuntu 8.04 which came with Vim 7.1 rather than 6.3 on the older server. It seems 7.1 does things slightly differently to 6.3.

In 6.3 I could create ~/.vim/filetype.vim and in there define a line as follows:

au BufRead,BufNewFile *.module,*.install,*.theme setf php

However in 7.1, it looks like a line similar to this has to go into ~/.vimrc instead…

Removing trailing spaces with vim

16
Jul
2008

Baby Tux

After recently reading about how great VIM is for the three hundredth and fifty second time (I kept count), I decided to take a look.

It really is quite cool! I've also decided to try to log any cool tips I learn about it. Here is the first which I found after running the coder module on one of my modules (Page Title 2) and it threw hundreds of errors about too many trailing spaces on empty lines.

Generate random string in MySQL

10
Jul
2008

Have you ever wanted to generate a random string in MySQL, say for assigning a random password to a list of users? Well here is a usefull tip!

Synergy for OSX Leopard

07
Jul
2008

I recently setup my PC in the living room with my TV so I could play games and watch streamed video from the net (eg, BBC's iPlayer). Unfortunately this always meant having a keyboard and mouse attached.

Then came along Synergy.

Global Redirect Update

03
Jul
2008

Global Redirect Logo

One of my most popular Drupal modules - Global Redirect - has just had an update from 1.2 to 1.3. This update includes several fixes for the following:

My First Drupal Theme

12
Jun
2008

I have just finished commiting my very first theme to the drupal community! I'm not a designer by nature - I prefer to be deep in the code. Thats why I commited this theme - it contains very little design (in terms of Photoshop work). This design is, pretty much, image free! On top of that - its SEO friendly too!

Abessive Screenshot

I say 'Pretty much' because it is still using 3 core image files for the bullet points. But what I'm pleased about is the curved CSS-only corners with a slight gradient on them AND the fact that if you remove content from a column, the content fills out over it automatically.

American Boy Remix

26
May
2008

Kasha LogoMy mate and Kasha have done a REALLY nice remix of the fairly recent song American Boy by Estelle. You can hear it on KashaMusic.co.uk

Page Title 2 for Drupal 6

02
May
2008

I've just released Page Title 2 for Drupal 6. Page Title 2 is still marked as Alpha (as a project) however its in use on a number of my sites and appears to work.

I'd appeciate people's feedback regarding this module. Its a GREAT way to improve your websites SEO!

My iPhone Theme

30
Apr
2008

Dekstop Screenshot ThumbnailI treated myself to a nice new iPhone last week and am LOVING it!

My phone is jailbroken and unlocked now (using PwnageTool). This means I can run all kinda of funky apps and games. I decided recently to design my own theme to make my phone feel more like "mine". Here are some screenshots. I'm working with a friend on how to release this theme along with some he has done too…

Getting Lighttpd working with AWStats

21
Apr
2008

Lighttpd meets AWStats

Following my previous post about configuring Lighttpd on this VPS Webserver to replace Apache I bring you a guide to configuring AWStats under Lighttpd. This process is differs to Apache as control of directories and aliasing is handled differently. There can also be complications if you have previously enabled the Drupal LUA Magnet script on your site for clean URL handling!

How to batch rename files

19
Apr
2008

This afternoon I needed to rename a bunch of files from one form to another in a command shell… Well technically I didn't need to do it in a shell - but, as sure as there is a hole in my ass, I wasn't gonna go through renaming them all manually!

They needed to go from, for example, add.png to add_32.png. After a little research into commands like printf, awk, bison and so on - I suddenly realized that 'cut' held the key!

for i in *; do j=`echo $i | cut -d . -f 1`; j=$j"_32.png"; mv $i $j; done

Powered by Lighttpd

16
Apr
2008

Lighttpd LogoThis blog is now no longer powered by Apache (the feature filled but slightly bloated beast), instead I have decided to give Lighttpd (pronounced Lighty) a whirl.

What convinced me? Ages ago I read an article by Dries Buytaert comparing webserver configurations. It was shocked to see that Lighttpd appeared to be able to serve almost twice as many pages per second as Apache. There is also the advantage that a static file will only cost you substantially less memory to serve in Lighty than it will in Apache due to Apache bundling ALL the mods into every process.

So what is Lighttpd? The inventors describe it perfectly…

It'd be nice if you asked before taking stuff from my site. Contact me at webmaster [at] thingy - ma - jig . co . uk

This site was based on the Cobalt 2.0 Theme for phpBB written by Jakob Persson

Search
Weblinks

Add to Technorati Favorites

TGC Webring

CMS Drupal Showcase

Feedburner for ThingyMaJig

View Nicholas Thompson's profile on LinkedIn

Nicholas Thompson's ClaimID

IconBuffet

Twitter

Become A Fan

bile-edge