<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-4957742841515787198</id><updated>2011-12-23T23:34:25.314+08:00</updated><category term='linux'/><category term='mysql'/><category term='java'/><category term='jsf2'/><category term='usb'/><category term='php'/><category term='broadband'/><category term='codeigniter'/><category term='css3'/><category term='fonts'/><category term='ipvs'/><category term='nebula'/><category term='ssh'/><category term='fedora'/><category term='misc'/><category term='hadoop'/><category term='sql'/><category term='rsyslog'/><category term='freeradius'/><category term='spring'/><category term='html'/><category term='shorewall'/><category term='debian'/><category term='openvpn'/><category term='windows'/><category term='ubuntu'/><category term='kvm'/><category term='radius'/><title type='text'>Tech Tots</title><subtitle type='html'>Random thoughts on Linux, Java, security and other technical stuff...</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>49</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-6324819524662055279</id><published>2011-12-16T14:34:00.001+08:00</published><updated>2011-12-16T14:34:44.190+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='php'/><category scheme='http://www.blogger.com/atom/ns#' term='codeigniter'/><title type='text'>Logging request parameters in CodeIgniter</title><summary type='text'>The application I'm currently working on provides services to mobile devices.  As such, I need to constantly check what values the mobile devices are POST-ing to the application.  Instead of adding a call to all functions in the controllers to perform this task, I decided to implement a hook in the application.

Hooks are supported in CodeIgniter (more info here).  Here's my hook class to perform</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/6324819524662055279/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=6324819524662055279' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6324819524662055279'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6324819524662055279'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/12/logging-request-parameters-in.html' title='Logging request parameters in CodeIgniter'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-9339795884746392</id><published>2011-12-16T14:10:00.001+08:00</published><updated>2011-12-16T14:10:07.883+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='kvm'/><title type='text'>Copying a running VM to external host</title><summary type='text'>Friend had a small incident the other day where KVM/QEMU seg-faulted and lost communication with a running VM.  The VM was still running but it isn't writing to persistent storage.  We decided to do a live backup of the running VM.  Although this is definitely NOT recommended, we were left with no other choice as shutting down the VM would mean losing all changes made.  The VM is running Linux </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/9339795884746392/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=9339795884746392' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/9339795884746392'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/9339795884746392'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/12/copying-running-vm-to-external-host.html' title='Copying a running VM to external host'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-4189657127614720466</id><published>2011-12-15T22:17:00.000+08:00</published><updated>2011-12-15T22:17:00.064+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='mysql'/><title type='text'>Using mysqldump to export CSV file</title><summary type='text'>By default, mysqldump outputs SQL table dumps.  If you ever need to export a table (or even a database) in CSV format using only mysqldump, here's the quick and easy way without using any additional clients:

mysqldump -u root -p --fields-terminated-by="," --fields-enclosed-by="" --fields-escaped-by="" --no-create-db --no-create-info --tab="." information_schema CHARACTER_SETS


mysqldump will </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/4189657127614720466/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=4189657127614720466' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4189657127614720466'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4189657127614720466'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/12/using-mysqldump-to-export-csv-file.html' title='Using mysqldump to export CSV file'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-6597245486556993996</id><published>2011-12-12T16:44:00.001+08:00</published><updated>2011-12-16T08:54:57.026+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><category scheme='http://www.blogger.com/atom/ns#' term='rsyslog'/><title type='text'>Using logback to log to a syslog server</title><summary type='text'>In my previous posts, we've configured a rsyslogd server to accept remote connections via TCP/UDP as well as a rsyslogd instance to write to a remote rsyslogd server.  We'll now take this further by logging to the rsyslogd server we've configured earlier using the logback library (http://logback.qos.ch/).  

Besides the logback JAR files, you'll need to grab the latest SLF4J libraries as well </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/6597245486556993996/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=6597245486556993996' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6597245486556993996'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6597245486556993996'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/12/using-logback-to-log-to-syslog-server.html' title='Using logback to log to a syslog server'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-3424483159066490694</id><published>2011-12-12T15:20:00.001+08:00</published><updated>2011-12-12T15:23:13.034+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='rsyslog'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>rsyslog: Logging to remote server</title><summary type='text'>Now that we've setup the rsyslogd server to accept incoming connections (NOTE: UDP somehow didn't work.  I had to configure rsyslogd to listen to TCP instead); we can now configure the "client" rsyslogd instance to log to a remote server.

In the "client" server, we'll need to edit the same configuration file /etc/rsyslog.conf.  I've added the highlighted lines below:

[...]
###############
#### </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/3424483159066490694/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=3424483159066490694' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/3424483159066490694'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/3424483159066490694'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/12/rsyslogd-logging-to-remote-server.html' title='rsyslog: Logging to remote server'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-7554328968407367826</id><published>2011-12-12T11:47:00.001+08:00</published><updated>2011-12-12T15:22:47.208+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='rsyslog'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>rsyslog: Enabling remote logging service in Ubuntu</title><summary type='text'>Newer versions of Ubuntu (since 9.10 according to rsyslog wiki: http://wiki.rsyslog.com/index.php/Ubuntu) comes with rsyslog instead of sysklogd.  Was trying to enable it via the sysklogd way by adding the "-r" option in the startup script.  That obviously didn't work :)

What you'll need to do is just uncomment 2 lines in the /etc/rsyslog.conf file:

# provides UDP syslog reception
$ModLoad </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/7554328968407367826/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=7554328968407367826' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7554328968407367826'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7554328968407367826'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/12/rsyslog-enabling-remote-logging-service.html' title='rsyslog: Enabling remote logging service in Ubuntu'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-7389016712126786705</id><published>2011-12-08T22:33:00.001+08:00</published><updated>2011-12-08T22:34:10.742+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='css3'/><title type='text'>CSS3 Generator</title><summary type='text'>I'm currently implementing (or rather trying to implement :P) a site with HTML5 and CSS3.  Found a very nifty site which helps in generating cross browser CSS3 effects e.g. shadows, border radius, etc:

http://css3generator.com/

Give it a try and see if it helps you as much as it helped me :)</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/7389016712126786705/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=7389016712126786705' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7389016712126786705'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7389016712126786705'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/12/css3-generator.html' title='CSS3 Generator'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-5817503182509595413</id><published>2011-12-08T09:09:00.000+08:00</published><updated>2011-12-08T22:38:45.981+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='jsf2'/><category scheme='http://www.blogger.com/atom/ns#' term='java'/><title type='text'>Barebones JSF2 Eclipse project</title><summary type='text'>Quick view on minimal libraries required to get a JSF2 project running in Eclipse (should work everywhere else):

com.springsource.javax.servlet.jsp-2.1.0.jar ==&gt; Obtained from Spring framework dependencies package
com.springsource.javax.servlet.jsp.jstl-1.1.2.jar ==&gt; Obtained from Spring framework dependencies package
javax.faces.jar ==&gt; Obtained from http://javaserverfaces.java.net/.  </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/5817503182509595413/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=5817503182509595413' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/5817503182509595413'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/5817503182509595413'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/12/barebones-jsf2-eclipse-project.html' title='Barebones JSF2 Eclipse project'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-226213744270380613</id><published>2011-12-08T08:53:00.000+08:00</published><updated>2011-12-08T13:37:36.563+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><category scheme='http://www.blogger.com/atom/ns#' term='hadoop'/><title type='text'>Setting up Hadoop in clustered mode in Ubuntu</title><summary type='text'>Overview

This entry details the steps I took to setup Hadoop in a clustered setup in Ubuntu 11.10.  Hadoop version 0.20.205.0 was used to setup the environment.  The Hadoop cluster consists of 3 servers/nodes:

node616 ==&gt; namenode, tasktracker, datanode, jobtracker, secondarynamenode
node617 ==&gt; datanode, jobtracker
node618 ==&gt; datanode, jobtracker

In an actual production setup, thet namenode </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/226213744270380613/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=226213744270380613' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/226213744270380613'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/226213744270380613'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/12/setting-up-hadoop-in-clustered-mode.html' title='Setting up Hadoop in clustered mode in Ubuntu'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-1670941693955511379</id><published>2011-12-06T23:29:00.000+08:00</published><updated>2011-12-06T23:29:12.983+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='mysql'/><category scheme='http://www.blogger.com/atom/ns#' term='ssh'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>Connecting to remote MySQL via SSH in Ubuntu</title><summary type='text'>I had to access my MySQL server via SSH tunnel on my Ubuntu desktop machine.  First up, setup ssh to tunnel the server's MySQL port (default 3306) to my Ubuntu's desktop machine port 13306:


ssh mylogin@myserver.com -p 4265 -L 13306:127.0.0.1:3306
However, when I tried accessing port 13306 on my Ubuntu desktop, it failed:


$ mysql -u root -p -P 13306Enter password:ERROR 1045 (28000): Access </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/1670941693955511379/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=1670941693955511379' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1670941693955511379'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1670941693955511379'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/12/connecting-to-remote-mysql-via-ssh-in.html' title='Connecting to remote MySQL via SSH in Ubuntu'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-4871390457663422675</id><published>2011-11-04T14:34:00.000+08:00</published><updated>2011-11-04T14:34:57.010+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='css3'/><category scheme='http://www.blogger.com/atom/ns#' term='fonts'/><title type='text'>Commercial Use Free Fonts</title><summary type='text'>Stumbled upon an awesome website offering commercial use free fonts:


http://www.fontsquirrel.com/




It also provides @font-face kits (CSS3) where you can upload a font file and it'll generate the necessary files for you to use in your CSS3 styles.



Awesome!!!!</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/4871390457663422675/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=4871390457663422675' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4871390457663422675'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4871390457663422675'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/11/commercial-use-free-fonts.html' title='Commercial Use Free Fonts'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-4566511831909399012</id><published>2011-10-06T22:03:00.000+08:00</published><updated>2011-10-06T22:03:00.935+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='nebula'/><title type='text'>Installing Open Nebula 3.0 on Ubuntu 10.04</title><summary type='text'>

Downloaded the .deb file from Open Nebula website (http://dev.opennebula.org/packages/opennebula-3.0.0/Ubuntu-10.04/opennebula_3.0.0-1_amd64.deb)


Installed it but gave some problems hence had to do the following steps:


dpkg -i opennebula_3.0.0-1_amd64.debapt-get install libmysqlclient16 libxmlrpc-c3apt-get -f install 



Once that's installed, the oned daemon will be started automatically.</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/4566511831909399012/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=4566511831909399012' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4566511831909399012'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4566511831909399012'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2011/10/installing-open-nebula-30-on-ubuntu.html' title='Installing Open Nebula 3.0 on Ubuntu 10.04'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-258441708198445530</id><published>2010-02-20T13:50:00.000+08:00</published><updated>2010-02-20T13:50:47.722+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><category scheme='http://www.blogger.com/atom/ns#' term='spring'/><title type='text'>EHCache with Spring AOP</title><summary type='text'>Building on the previous post (Spring AOP with @AspectJ annotations), we now add EHCache functionality to the Aspect class.  We won't be adding any new Java class files, but we'll be modifying the existing class files.  Here's a screenshot of the finished project in Eclipse.  New elements are highlighted in red.






Adding EHCache functionality 

Add the EHCache JAR file to the project.  We'll </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/258441708198445530/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=258441708198445530' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/258441708198445530'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/258441708198445530'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/02/ehcache-with-spring-aop.html' title='EHCache with Spring AOP'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_i6x7ecGbplY/S39ZO1PNYJI/AAAAAAAAABc/pxygZhs0ym4/s72-c/springaop2.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-4401318866060793962</id><published>2010-02-19T09:12:00.001+08:00</published><updated>2010-02-19T09:15:17.980+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><category scheme='http://www.blogger.com/atom/ns#' term='spring'/><title type='text'>Spring AOP with @AspectJ annotations</title><summary type='text'>Here's a quick sample on how to use Spring's AOP feature with @AspectJ annotations.  First off, please read the Spring Reference manual on AOP.  This post is a copy and paste tutorial (hopefully I get it right :P).  We begin by creating a normal Java Project in Eclipse.  I've named it "springtest".  You can name it whatever you like.  Here's a screenshot of the project in Eclipse:



Take note of</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/4401318866060793962/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=4401318866060793962' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4401318866060793962'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4401318866060793962'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/02/spring-aop-with-aspectj-annotations.html' title='Spring AOP with @AspectJ annotations'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_i6x7ecGbplY/S31BWvwJC7I/AAAAAAAAABU/7XHAT6WHbPo/s72-c/springaop1.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-5244350274809080948</id><published>2010-01-21T11:57:00.000+08:00</published><updated>2010-01-21T11:57:36.548+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ipvs'/><category scheme='http://www.blogger.com/atom/ns#' term='fedora'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><category scheme='http://www.blogger.com/atom/ns#' term='openvpn'/><title type='text'>Load balancing OpenVPN connections via IPVS (Linux Virtual Server)</title><summary type='text'>First Steps
 First off, I've performed the setup and configuration on my own local PC using VirtualBox VMs.  Network for all the VMs are set to bridge mode.  Here's how the servers are configured:

director--------Fedora 12VIP=eth0:0 192.168.1.150RIP=eth0 192.168.1.200ovpnserver1-----------UbuntuRIP=eth0 192.168.1.201VIP=lo:0 192.168.1.150 (no arp)ovpnserver2-----------UbuntuRIP=eth0 </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/5244350274809080948/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=5244350274809080948' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/5244350274809080948'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/5244350274809080948'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/load-balancing-openvpn-connections-via.html' title='Load balancing OpenVPN connections via IPVS (Linux Virtual Server)'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-6120684982880803385</id><published>2010-01-19T12:13:00.000+08:00</published><updated>2010-01-19T12:13:37.794+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>Mounting an NTFS partition in a folder</title><summary type='text'>To mount an NTFS partition in a folder similar to what's done in Unix systems, do the following:



Go to the "Run..." screen and type in compmgmt.msc.
Click on "Disk Management".
Right click on the volume you want to use and select "Change Drive Letter and Paths..."
Click "Add".  Another window will be displayed like below:







Click on the second radio box "Mount in the following empty NTFS </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/6120684982880803385/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=6120684982880803385' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6120684982880803385'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6120684982880803385'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/mounting-ntfs-partition-in-folder.html' title='Mounting an NTFS partition in a folder'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_i6x7ecGbplY/S1UwnUj5m0I/AAAAAAAAABE/h-eJ2VbyXgo/s72-c/1.PNG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-7642902078508574309</id><published>2010-01-14T16:10:00.002+08:00</published><updated>2010-01-17T07:08:11.166+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><title type='text'>Connecting to MQ using Spring without WAS</title><summary type='text'>Here's how to connect to MQ using spring without WAS.  First, here's the properties value for the connection settings:


# MQ related values


mq.jms.qcf=IBMMQQCF


mq.jms.request.queue=TEST.REQUEST.QUEUE





# Connection details


mq.host.url=192.168.1.200:1415/SYSTEM.DEF.SVRCONN


mq.factoryclass=com.ibm.mq.jms.context.WMQInitialContextFactory





# Authentication details


mq.auth=simple


</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/7642902078508574309/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=7642902078508574309' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7642902078508574309'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7642902078508574309'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/connecting-to-mq-using-spring-without.html' title='Connecting to MQ using Spring without WAS'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-119110356334723491</id><published>2010-01-14T10:31:00.001+08:00</published><updated>2010-01-14T10:44:30.244+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='shorewall'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>Installing Shorewall in Ubuntu</title><summary type='text'>I started off with the simple command:


# apt-get install shorewall shorewall-doc


Thought everything was installed properly.  But I got the following error instead:


# shorewall start


Compiling...


   No shorewall compiler installed


Seems I'm missing one more package:


# apt-get install shorewall-perl


Once the shorewall-perl package is you should get the following output:


# </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/119110356334723491/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=119110356334723491' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/119110356334723491'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/119110356334723491'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/installing-shorewall-in-ubuntu.html' title='Installing Shorewall in Ubuntu'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-662599669092720230</id><published>2010-01-11T15:35:00.002+08:00</published><updated>2010-01-11T15:43:01.963+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='freeradius'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><category scheme='http://www.blogger.com/atom/ns#' term='openvpn'/><title type='text'>Configuring OpenVPN + FreeRADIUS + MySQL</title><summary type='text'>Here's a quick guide on how to configure OpenVPN to use FreeRADIUS for authentication.  I've only tried it on Ubuntu Karmic.  YMMV on other distros.

Download the radiusplugin here http://www.nongnu.org/radiusplugin/.  You'll have to compile it from source as there's currently no deb package for it.  Compile steps below:

# apt-get install libgcrypt11 libgcrypt11-dev build-essential
# make

The </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/662599669092720230/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=662599669092720230' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/662599669092720230'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/662599669092720230'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/configuring-openvpn-freeradius-mysql.html' title='Configuring OpenVPN + FreeRADIUS + MySQL'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-7161966196625576301</id><published>2010-01-11T03:22:00.002+08:00</published><updated>2010-01-11T15:38:42.890+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='radius'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>Installing and configuring daloRADIUS</title><summary type='text'>With FreeRADIUS+MySQL installed, it's now turn to install daloRADIUS; a web-based management system for FreeRADIUS.  Before installation, ensure that Apache, PHP and MySQL have been installed and running.  You'll need PHP PEAR as well.  Use the following command to install the required libs:

# apt-get install php-pear
# pear install DB

Get the latest version of daloRADIUS from http://</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/7161966196625576301/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=7161966196625576301' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7161966196625576301'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7161966196625576301'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/installing-and-configuring-daloradius.html' title='Installing and configuring daloRADIUS'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-1422896355843062229</id><published>2010-01-10T13:13:00.003+08:00</published><updated>2010-01-10T13:23:36.019+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='radius'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>Installing and configuring FreeRADIUS with MySQL authentication</title><summary type='text'>Here's a *near* step-by-step guide to setup FreeRADIUS with MySQL backed authentication done on Ubuntu 9.10 (Karmic).  Start by installing the necessary deb files:


# apt-get install freeradius freeradius-mysql


Add the following lines to the /etc/freeradius/users file: 

abc     Cleartext-Password := "123"

Stop freeradius service just in case:

/etc/init.d/freeradius stop

Now test using the </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/1422896355843062229/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=1422896355843062229' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1422896355843062229'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1422896355843062229'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/installing-and-configuring-freeradius.html' title='Installing and configuring FreeRADIUS with MySQL authentication'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-7267863410087694411</id><published>2010-01-08T17:43:00.002+08:00</published><updated>2010-01-08T17:44:59.732+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='misc'/><title type='text'>Creating split RAR files via command line</title><summary type='text'>Command below creates split RAR files (e.g. file.part001.rar, file.part002.rar...) via the command line:


$ rar a -m0 -v50000k &lt;rar-file-name&gt; &lt;files-to-be-rared&gt;


That creates files of 50,000k a piece without any compression (-m0).  The most important option here is the -v option :) </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/7267863410087694411/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=7267863410087694411' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7267863410087694411'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7267863410087694411'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/creating-split-rar-files-via-command.html' title='Creating split RAR files via command line'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-7429113250926589226</id><published>2010-01-08T17:31:00.000+08:00</published><updated>2010-01-08T17:31:25.050+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>Creating network aliases for single network interface</title><summary type='text'>First some assumptions:

network interface is aliased to eth0
eth0 assigned to 192.168.1.1

Here's how you assign more than one IP to a single network interface in Ubuntu/Debian:


# ifconfig eth0:0 192.168.1.2 up

That's it.  Wait for a while for the interface to become active and you'll be able to configure services to serve from that IP.  To make the change permanent, edit the /etc/network/</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/7429113250926589226/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=7429113250926589226' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7429113250926589226'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7429113250926589226'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/creating-network-aliases-for-single.html' title='Creating network aliases for single network interface'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-5372868620385911569</id><published>2010-01-08T16:56:00.004+08:00</published><updated>2010-01-08T17:08:24.470+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='java'/><title type='text'>.NET and Apache Axis Interop Problem</title><summary type='text'>I've been using Apache Axis for a long time to publish web services in Java apps.  But recently, it's the first time that a .NET client is used to call the web services published via Axis.  Although I do not have the exact error messages in the .NET client, the client mentioned they received "null" errors when parsing the response.

First thing to do was to disable "multirefs" output.  This can </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/5372868620385911569/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=5372868620385911569' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/5372868620385911569'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/5372868620385911569'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/net-and-apache-axis-interop-problem.html' title='.NET and Apache Axis Interop Problem'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-5529846019265021817</id><published>2010-01-06T16:09:00.001+08:00</published><updated>2010-01-18T10:02:13.510+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Removing invalid/encoded characters from filenames</title><summary type='text'>If you see the following output in your file system:


drwxrwxrwx 2 www-data www-data 4096 Jan  5 03:30 ?????? - ?Q?U?H-?X?Y??Like?t???


drwxrwxrwx 2 www-data www-data 4096 Jan  5 03:41 ???O?? ?@?????j?t???


It'll be difficult to work with the files.  By using "detox", you can remove all invalid characters from the files/folders.  In Ubuntu, simply perform the following command to install it:

</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/5529846019265021817/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=5529846019265021817' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/5529846019265021817'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/5529846019265021817'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/removing-invalidencoded-characters-from.html' title='Removing invalid/encoded characters from filenames'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-6948562924729814704</id><published>2010-01-06T11:40:00.000+08:00</published><updated>2010-01-06T11:40:28.098+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='debian'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>List of installed packages in Ubuntu/Debian</title><summary type='text'>Use the following command to show the list of installed packages in Ubuntu/Debian:

# dpkg --get-selections

acl      install
acpi-support     install
acpid      install
adduser      install
aisleriot     install

[..]


You can then use grep to look for the packages you want.</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/6948562924729814704/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=6948562924729814704' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6948562924729814704'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6948562924729814704'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/list-of-installed-packages-in.html' title='List of installed packages in Ubuntu/Debian'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-4180990582993128755</id><published>2010-01-06T09:47:00.001+08:00</published><updated>2010-01-08T17:02:41.891+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>Grep in Windows</title><summary type='text'>Ever wanted to grep a string in Windows console?  Here's how:


c:\&gt;netstat -an | findstr 50000

There are other options for findstr.  You can check it out by typing "help findstr".</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/4180990582993128755/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=4180990582993128755' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4180990582993128755'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4180990582993128755'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/grep-in-windows.html' title='Grep in Windows'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-1739733904582613221</id><published>2010-01-05T20:29:00.001+08:00</published><updated>2010-01-08T17:02:18.353+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>(L)AMP installation on Ubuntu</title><summary type='text'>Just got a new server up and running.  Here are the commands to install Apache2, PHP5 and MySQL:


# apt-get install apache2 libapache2-mod-php5 mysql-server-5.1 php5-mysql php5-mcrypt

Make sure you do a restart.  Sometimes the apt-get process doesn't restart Apache properly to ensure the PHP5 module is loaded.


# /etc/init.d/apache2 restart

</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/1739733904582613221/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=1739733904582613221' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1739733904582613221'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1739733904582613221'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/lamp-installation-on-ubuntu.html' title='(L)AMP installation on Ubuntu'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-7521728842923937032</id><published>2010-01-05T17:35:00.001+08:00</published><updated>2010-01-08T17:02:53.546+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>Compiling and installing libtorrent/rtorrent</title><summary type='text'>Here are the steps to compile and install libtorrent/rtorrent.  The latest stable version of libtorrent/rtorrent is 0.12.6 and 0.8.6 respectively as of writing this article.  The tarballs can be obtained here.  Following commands must be run as root.


# apt-get install build-essential libssl-dev libssl0.9.8 libsigc++-2.0-dev libncurses5-dev libncursesw5-dev libcurl4-openssl-dev libssl-dev </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/7521728842923937032/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=7521728842923937032' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7521728842923937032'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7521728842923937032'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/compiling-and-installing.html' title='Compiling and installing libtorrent/rtorrent'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-2939778727162732091</id><published>2010-01-03T18:27:00.002+08:00</published><updated>2010-01-19T16:11:21.044+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><category scheme='http://www.blogger.com/atom/ns#' term='openvpn'/><title type='text'>OpenVPN with pam_mysql username/password authentication</title><summary type='text'>Here's how I setup OpenVPN with pam_mysql using only username/password authentication (insecure, but really easy on the admin side :P).  Target platform is Ubuntu Jaunty.  For starters, you'll need the following installed:

openvpn
mysql - server installed and running

Get the latest version of pam_mysql from http://pam-mysql.sourceforge.net/.  Untar it into a working directory.  The latest </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/2939778727162732091/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=2939778727162732091' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/2939778727162732091'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/2939778727162732091'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/openvpn-with-pammysql-usernamepassword.html' title='OpenVPN with pam_mysql username/password authentication'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-4019003004159789980</id><published>2010-01-03T07:32:00.000+08:00</published><updated>2010-01-03T07:32:16.919+08:00</updated><title type='text'>Compiling openvpn-auth-ldap on Debian</title><summary type='text'>Here are the steps I followed to compile openvpn-auth-ldap plugin on Debian:

apt-get install re2c 
apt-get install libldap2-dev
apt-get install gobjc
./configure --prefix=/usr/local --with-openldap=/usr/include --with-openvpn=/usr/include/openvpn

The libldap2-dev package is required for openldap header files while the gobjc package is required to satisfy sanity check on cpp.  Openvpn's header </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/4019003004159789980/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=4019003004159789980' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4019003004159789980'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4019003004159789980'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2010/01/compiling-openvpn-auth-ldap-on-debian.html' title='Compiling openvpn-auth-ldap on Debian'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-60884106061214662</id><published>2009-12-11T02:47:00.000+08:00</published><updated>2009-12-11T02:47:23.675+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='misc'/><title type='text'>Opera Mini 5 Beta 2</title><summary type='text'>The new version of Opera Mini 5 Beta is out.  It's no longer called Opera Mini but Opera Mobile.  Either way, it's shaping up to be a really nice browser.  Gone are the days of it being a J2ME app.  It's now a native S60 application.  Speed increase is very noticeable.  Give it a go here: http://www.opera.com/mini/next/</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/60884106061214662/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=60884106061214662' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/60884106061214662'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/60884106061214662'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2009/12/opera-mini-5-beta-2.html' title='Opera Mini 5 Beta 2'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-6048076086880031895</id><published>2009-11-19T09:59:00.001+08:00</published><updated>2010-01-08T17:03:40.638+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Using 'ps' to find CPU intensive processes</title><summary type='text'>If you've been using 'top' to determine which processes use the most CPU resource, there's another way.  Use 'ps' and sort the output via CPU.  Here's the command:
ps aux --sort -cp
</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/6048076086880031895/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=6048076086880031895' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6048076086880031895'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6048076086880031895'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2009/11/using-ps-to-find-cpu-intensive.html' title='Using &apos;ps&apos; to find CPU intensive processes'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-1409370829786981334</id><published>2009-10-15T16:45:00.000+08:00</published><updated>2009-10-15T16:45:50.729+08:00</updated><title type='text'>Using whois To Search For Records</title><summary type='text'>Here's a nice tip to search for relevant records from a DNS using whois:
whois -h "whois.apnic.net" -a "Google"
 This will search "whois.apnic.net" for all records matching "Google".  Good stuff :)</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/1409370829786981334/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=1409370829786981334' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1409370829786981334'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1409370829786981334'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2009/10/using-whois-to-search-for-records.html' title='Using whois To Search For Records'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-1235148136195968113</id><published>2009-10-11T01:58:00.000+08:00</published><updated>2009-10-11T02:00:38.263+08:00</updated><title type='text'>Installing Virtualbox Guest Additions in Centos 5</title><summary type='text'>To install VBox's Guest Additions in CentOS 5, simply run the following commands:yum install gcc -yyum install kernel sources -yyum install kernel-devel -yReboot the system.  Right after that, run the VBox additions .sh file.</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/1235148136195968113/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=1235148136195968113' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1235148136195968113'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1235148136195968113'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2009/10/installing-virtualbox-guest-additions.html' title='Installing Virtualbox Guest Additions in Centos 5'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-7844351040739804633</id><published>2009-10-09T16:14:00.000+08:00</published><updated>2009-10-09T16:20:36.183+08:00</updated><title type='text'>XML Pretty Formatting</title><summary type='text'>I've had this problem for a long time.  A huge XML document which is not formatted.  Finally found the simplest solution... HTML Tidy library.  Grab the EXE from SourceForge: http://tidy.sourceforge.net/.  Then run the following command:tidy -xml -indent -quiet -o "output.xml" input.xmlThis will read the input.xml file and treat it as a well formed XML.  No additional output will be displayed on </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/7844351040739804633/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=7844351040739804633' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7844351040739804633'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7844351040739804633'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2009/10/xml-pretty-formatting.html' title='XML Pretty Formatting'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-1242340887490730358</id><published>2008-07-22T23:00:00.000+08:00</published><updated>2008-07-22T23:06:49.310+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Extracting audio stream from an AVI file using mencoder</title><summary type='text'>If you ever need to extract the audio stream from an XVID/MP3 encoded file and save the audio stream back into MP3 format, here's the command to do it using mencoder:mencoder "${file}" -of rawaudio -oac mp3lame -ovc copy -o audio/"${file/%avi/mp3}"This commands saves the output in the audio directory.   The portion ${file/%avi/mp3} uses bash string replacement to replace the avi to mp3 within the</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/1242340887490730358/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=1242340887490730358' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1242340887490730358'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1242340887490730358'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/07/extracting-audio-stream-from-avi-file.html' title='Extracting audio stream from an AVI file using mencoder'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-9000169963788163742</id><published>2008-07-22T11:36:00.000+08:00</published><updated>2008-07-22T12:03:13.281+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='mysql'/><title type='text'>MySQL: "Cannot insert new word" error</title><summary type='text'>The internal forum (powered by phpBB) I was using was suddenly giving me the error "cannot insert new word".  Tailing /var/log/messages and MySQL error logs came up empty.  After Googling a bit, it seems that the MySQL tables are corrupt.  Running the SQL command below fixes the problem beautifully:repair table [tablename];</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/9000169963788163742/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=9000169963788163742' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/9000169963788163742'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/9000169963788163742'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/07/mysql-cannot-insert-new-word-error.html' title='MySQL: &quot;Cannot insert new word&quot; error'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-883728435284218039</id><published>2008-07-21T13:23:00.000+08:00</published><updated>2008-07-21T13:31:23.958+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>Kernel panic in Linux 2.6.26 on VirtualBox</title><summary type='text'>I've been trying to get Intrepid Ibex Alpha 1 &amp; 2 to boot on VirtualBox in a Linux host; but due to what it seems like a kernel bug, I've been unable to do so.  If you're interested to see the development/status of this bug, click here.</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/883728435284218039/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=883728435284218039' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/883728435284218039'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/883728435284218039'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/07/kernel-panic-in-linux-2626-on.html' title='Kernel panic in Linux 2.6.26 on VirtualBox'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-8250706939601236903</id><published>2008-07-21T11:26:00.000+08:00</published><updated>2008-07-21T13:18:34.726+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='html'/><title type='text'>HTML Cache Headers</title><summary type='text'>I've always get burnt for setting the wrong HTTP headers for cache control.  So here's the braindump of what these headers are and what to set them to.  The RFC for HTTP header field definitions is located here. Note that it's always better to set the headers both in the HTTP-EQUIV META tags as well as to set it via the headers as some browsers have problems parsing the HTTP-EQUIV META tags.There</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/8250706939601236903/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=8250706939601236903' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/8250706939601236903'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/8250706939601236903'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/07/html-cache-headers.html' title='HTML Cache Headers'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-7109842897268515036</id><published>2008-07-21T00:55:00.000+08:00</published><updated>2008-07-21T14:16:22.298+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='html'/><title type='text'>Cache Control Settings</title><summary type='text'>I've always get burnt for setting the wrong HTTP headers for cache control. So here's the braindump of what these headers are and what to set them to. The RFC for HTTP header field definitions is located here.Note that it's always better to set the headers both in the HTTP-EQUIV META tags as well as to set it via the headers as some browsers have problems parsing the HTTP-EQUIV META tags.There </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/7109842897268515036/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=7109842897268515036' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7109842897268515036'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7109842897268515036'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/07/cache-control-settings.html' title='Cache Control Settings'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-1018600061595859451</id><published>2008-07-20T21:55:00.000+08:00</published><updated>2008-07-21T00:54:26.035+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>Restarting NetworkManager in (K)ubuntu</title><summary type='text'>If NetworkManager's acting up on your (K)ubuntu installation, you can restart 2 daemons instead of performing a reboot.  Here's what you do:sudo /etc/dbus-1/event.d/25NetworkManager restartsudo /etc/dbus-1/event.d/26NetworkManagerDispatcher restartOnce that's done, wait for a while for the daemon to refresh itself.  Then try to re-associate your machine with an AP.</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/1018600061595859451/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=1018600061595859451' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1018600061595859451'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/1018600061595859451'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/07/restarting-networkmanager-in-kubuntu.html' title='Restarting NetworkManager in (K)ubuntu'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-7061395282889972973</id><published>2008-07-03T23:26:00.000+08:00</published><updated>2008-07-04T00:03:56.384+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Backup fun with netcat (nc)</title><summary type='text'>Was asked to help on backing up files in one server and then transfer the image to another server.  Sounds simple, but unfortunately the server which files are to be backed up has very limited disk space and prevents me from creating a tar-ball. Instead of creating a tar-ball in the server, I used netcat (or known as nc) to stream the files over to another server while running the tar command. On</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/7061395282889972973/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=7061395282889972973' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7061395282889972973'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/7061395282889972973'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/07/backup-fun-with-netcat-nc.html' title='Backup fun with netcat (nc)'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-4196162194625831765</id><published>2008-07-03T23:11:00.000+08:00</published><updated>2008-07-03T23:53:59.675+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='broadband'/><category scheme='http://www.blogger.com/atom/ns#' term='usb'/><title type='text'>Configuring Huawei E220 USB GSM modem on Kubuntu Hardy</title><summary type='text'>Managed to get my hands on a repackaged Huawei E220 USB GSM modem provided by Maxis via their Maxis Broadband package.  Since there's no instructions to install and use it on Linux (Windows and OSX instructions are provided), I decided to see how Linux will behave when it's plugged into the USB port.Lo and behold; my system's /var/log/messages when it's plugged in:Jul  3 10:56:50 mymachine kernel</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/4196162194625831765/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=4196162194625831765' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4196162194625831765'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4196162194625831765'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/07/configuring-huawei-e220-usb-gsm-modem.html' title='Configuring Huawei E220 USB GSM modem on Kubuntu Hardy'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-4051986314096310782</id><published>2008-07-01T11:46:00.000+08:00</published><updated>2008-07-01T13:33:29.496+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>Installing/Configuring kismet on Ubuntu</title><summary type='text'>Been experimenting with kismet over the weekend and was finally well enough to configure it after some quick digging.InstallationDo a simple apt-get to install kismet:apt-get install kismetThat's all there to it.  Please note that the version in Ubuntu's repo is 2007-10-R1-2build1.  It's a lot older than the one currenly available for download i.e. Kismet-2008-05-R1.ConfigurationIf you run kismet</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/4051986314096310782/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=4051986314096310782' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4051986314096310782'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/4051986314096310782'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/06/installingconfiguring-kismet-on-ubuntu.html' title='Installing/Configuring kismet on Ubuntu'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp1.blogger.com/_i6x7ecGbplY/SGnAxurMhjI/AAAAAAAAAAQ/41iMieAcDwQ/s72-c/kismet.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-8715414337795575064</id><published>2008-06-29T22:43:00.000+08:00</published><updated>2008-06-29T22:50:18.898+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><title type='text'>Intrepid Ibex Alpha 1</title><summary type='text'>The first alpha of the next Ubuntu version code named "Intrepid Ibex" is now available!  Get the release info and the release notes here.  Gonna download it and try it out on a VM.  Let's see what's new in a few :)I'm downloading Kubuntu 8.10a1 as I type this.  However, seems like only the "alternate" version is available.  Strange...</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/8715414337795575064/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=8715414337795575064' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/8715414337795575064'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/8715414337795575064'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/06/intrepid-ibex-alpha-1.html' title='Intrepid Ibex Alpha 1'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-488434511275727140</id><published>2008-06-26T14:08:00.000+08:00</published><updated>2008-06-29T22:49:31.292+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Argument list too long</title><summary type='text'>Ever tried to do a "rm *" on a directory and got the error "argument list too long"?  Use xargs and chain the commands!ls | xargs rmFound this gem here: http://www.shell-fu.org/lister.php?id=251</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/488434511275727140/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=488434511275727140' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/488434511275727140'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/488434511275727140'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/06/argument-list-too-long.html' title='Argument list too long'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-6193656757564923609</id><published>2008-06-26T09:37:00.000+08:00</published><updated>2008-07-01T14:18:18.990+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sql'/><title type='text'>UPDATE...FROM</title><summary type='text'>The UPDATE...FROM SQL statement saved me tonnes of time during a previous system migration.  Using the FROM clause in an UPDATE statement allows you to pull data from one or more tables into the data you're updating.Say you have a table with 10,000 user records (let's call it tbl_migration_1) which you'd like to find the last login time which is stored in the master user table (let's call it </summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/6193656757564923609/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=6193656757564923609' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6193656757564923609'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/6193656757564923609'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/06/updatefrom.html' title='UPDATE...FROM'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4957742841515787198.post-2696816064755039870</id><published>2008-06-25T11:56:00.000+08:00</published><updated>2008-06-26T14:07:53.268+08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><title type='text'>Using CURL to obtain superflous HTTP verbs</title><summary type='text'>Instead of using netcat or telnet to check a website for allowing superflous HTTP verbs, CURL makes it simpler:curl -X OPTIONS -I &lt;host name&gt;An example of the output is shown below:# curl -X OPTIONS -I http://thestar.com.myHTTP/1.1 200 OKAllow: OPTIONS, TRACE, GET, HEADContent-Length: 0Server: Microsoft-IIS/6.0Public: OPTIONS, TRACE, GET, HEAD, POSTX-Powered-By: ASP.NETDate: Wed, 25 Jun 2008 03:</summary><link rel='replies' type='application/atom+xml' href='http://techtots.blogspot.com/feeds/2696816064755039870/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4957742841515787198&amp;postID=2696816064755039870' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/2696816064755039870'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4957742841515787198/posts/default/2696816064755039870'/><link rel='alternate' type='text/html' href='http://techtots.blogspot.com/2008/06/using-curl-to-obtain-superflous-http.html' title='Using CURL to obtain superflous HTTP verbs'/><author><name>Mike</name><uri>http://www.blogger.com/profile/12828408134779227322</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
