double nat sip with asterisk
rene — Tue, 03/09/2010 - 20:21
This config works by port forwarding RTP traffic to the asterisk and ATA on both ends. From what I've seen SIP does not handle RTP traffic well with double NAT when port forwarding of RTP it not used.
I've got the following network topology. The far left is an asterisk box I terminate all my VOIP calls through. The far right is my ATA and desk phone, a sipura spa2000.

This is how I do double nat sip with asterisk.
On the asterisk end far left, sip.conf has this in the general section
localnet=10.20.20.0/255.255.255.0
For the account I have for my ATA to authenticate I have this
nat=yes
canreinvite=yes
In rtp.conf I lock RTP traffic to ports 10000 through to 10100
rtpend=10100
On the far left Linux router I port forward the following
process 4 weeks of vacation email in less than 20 seconds
rene — Tue, 02/23/2010 - 09:14
Have you been away from work for more than a week and returned finding yourself at your desk for a couple of hours (or days) processing a tonne of obsolete email?
I recently went on 4 weeks leave and left this as my 'vacation' auto response email.
I will be out of the office starting 04/01/2010 and will not return until 01/02/2010.
When I return I will NOT be reading the hundreds of emails that have accumulated in my absence. I WILL be assuming that if your issue is urgent you will have discussed it with one of the people below ;
Joe Bloggs
Fred Bloggs
If you haven't spoken to them, and still want my input on something, you will need to resend your email on or after 01/02/2010. When I return I will be deleting ALL emails without reading them.
Processing email when I got back involved selecting all email in my inbox and pressing delete. 4 weeks of email processed in less than 20 seconds.
why task lists are broken
rene — Sun, 02/21/2010 - 22:26
Task lists are broken. Tasks within a task lists are just that. Tasks.
But tasks need to be associated with time. Without allocating time to specific tasks within a list, the list will accumulate more tasks. One way people deal with the accumulating task list is by removing tasks. Another way is by ignoring your task list. Neither gets shit done.
I threw out task lists many years ago when I saw mine grow and grow. I stopped the delusional 'gee, im important, i have so many tasks to do' mindset and started Getting Things Done by putting tasks into a calender.
More specifically Google Calendar. It syncs with my mobile, works with any PC that has a browser, integrates nicely into services such as tungle.me, hooks into other public calendars and allows me to invite others to see my calendar status.
I live in my calendar. If an alarm goes off and says I need to start task X, I start X. Having the discipline to follow your calendar alarms and triggers is not hard. The discipline lies in scheduling your tasks within your calendar appropriately to be able foresee any time allocation or location issues. For example I would not schedule a technical conf over skype whilst I'm trying to get some non-tech time in walking my dog. A calendaring system clearly points this out. A list of tasks does not.
When asked if I could do something for someone I immediately reply back with "Let me check my calendar" from which I can tell whether I have the bandwidth or not to take on the task. A sincere polite response of "My calendar has me booked in from Tuesday to Thursday. I can slot this task in at 11am Friday morning. Hows that sound?" is always received well.
a screenshot of my calendar in its day view

release safely and Iterate quickly with git branches
rene — Sun, 01/10/2010 - 20:58
Branches are cheap in git. This is how I use branches to release safely and iterate quickly
I commit a fix in a dev branch
$ git commit -v -m 'closes #101' $ git branch * dev master
I create a branch called dev-master which will be a new branch where I will do the actual merging of 2 branches. The parent of the dev-master branch will be the dev branch.
$ git checkout -b dev-master Switched to a new branch "dev-master" $ git branch dev * dev-master master
I then merge master
$ git merge master
I change to the master branch and merge dev-master
$ git checkout master Switched to branch "master" $ git merge dev-master
Push to origin and clean up
$ git push origin master $ git branch -d dev-master
If there is a conflict or if I need to back out of the merge I can do all the hard work in the dev-master branch without impacting any other branches.
Query an IBM ServeRAID adapter on the CLI
rene — Sun, 01/10/2010 - 20:40
I quickly needed to determine the status of a RAID array that sat on an IBM ServeRAID adapter. The boxen was running Ubuntu 9.04 x86_64, I didnt want to install RaidManager nor did I want to install a debian package. Here's how.
$ wget http://hwraid.le-vert.net/debian/pool-lenny/arcconf_6.10.18451-1_amd64.deb $ ar -x arcconf_6.10.18451-1_amd64.deb $ tar zxvf data.tar.gz $ sudo ./usr/sbin/arcconf GETCONFIG 1
Install the debian package if you need.































