March 3, 2010

DynDNS Lite!

Filed under: How To, Linux, Ubuntu — James @ 10:47 pm

As my IP address changes so rarely, my Dynamic DNS accounts keep expiring before the IP changes!
(more…)

December 16, 2009

Digikam in Ubuntu 9.10

Filed under: How To, Linux, Ubuntu — Tags: , — James @ 10:34 pm

After installing Digikam on Ubuntu, I had no video thumbnails or ability to play video.
(more…)

August 29, 2009

Count unique IP address in Apache’s access log

Filed under: Bash, How To, Linux, Ubuntu — James @ 11:14 pm
sed < /var/log/httpd/webtop.access_log -e 's/ .*$//' | sort | uniq -c

May 26, 2009

Ubuntu – Purge configuration files for removed packages

Filed under: How To, Linux, Ubuntu — James @ 11:24 am

This bash command will remove the left over config files from old packages that were removed with “apt-get remove”.

dpkg -l | awk '/^rc/ {print $2}' | xargs sudo dpkg --purge

See the source article for an explanation of how it works.

February 5, 2009

SD card and Arduino

Filed under: Arduino, Electronics, How To, Linux — James @ 8:23 pm

So, I have not long had my Arduino development board, my first project was to try and get it to log data to an SD card. This will be essential for a few future projects I have in mind. The internal EEPROM is only 512bytes, so not particularly useful for logging large amounts of data.

(more…)

November 23, 2008

Explode into associative array

Filed under: How To, Mac OS X, PHP, Programming — James @ 6:32 pm

Simple function to explode a string into an associative array. Works in the same way as the normal explode but takes an extra argument which is an array of keys to use for the returned associative array.

(more…)

November 16, 2008

List files/folders ordered by size

Filed under: Bash, How To, Linux — James @ 11:13 am
du -s * | sort -n