mysqldump without table locks and single line inserts June 16, 2010 Comments Off
Since I always forget:
mysqldump –extended-insert=false –host <host> –skip-lock-tables -u <user> –password <database> <table> > file.sql
SSH Tunnelling June 15, 2010 Comments Off
ssh -f user@HOST -L from_port:to_ip:to_port -N
eg:
ssh -f blah@home.chear.ca -L 8080:192.168.1.1:80 -N
Simple MySQL export/import February 25, 2010 Comments Off
mysql -e 'SELECT * FROM table' > out.txt
load data local infile 'out.txt' into table 'some_table'
Linux (Ubuntu) + OSX April 28, 2009 Comments Off
At home I have a Macbook Pro that acts as my everyday desktop computer and a headless (no monitor) Ubuntu Linux server that acts as a development testbed. The Ubuntu server has Apache, MySQL and PHP installed for development. My Mac has that too, but I prefer turning those services off and let the Linux machine do the heavy lifting. Usually, it’s sufficient to log into the Linux machine through SSH and hack around with vi. However, there are times that you may want to log into the Linux GUI. That’s a pain in the arse for me, since I would have to connect a monitor and keyboard to the server. The simplest solution is to log in through X and XDMCP.
Read the rest of this entry »
Free Tools for the Mac Hacker April 27, 2009 Comments Off
I use the Mac OSX daily for my job as a developer. It’s a Unix based OS so it has a very ‘hackerish’ feel to it if you get past the shiny GUI. In fact, Leopard has PHP, perl and python installed and ready for use from the get-go. Here are some tools that I use for the Mac to make my life easier.
Read the rest of this entry »

