Iligan, my hometown, is featured in Living Asia

Check out this video about my hometown iligan

Categories: Uncategorized | Leave a comment

Best Buy Ever

For the lack of good bookstore in Iligan City, I scavenge used books at booksale at Gaisano Mall.  I found “More Joel on Software” sold for 10 Philippine Peso.  I immediately grabbed the book, pay the cashier and went hope happily.

Oh I wouldn’t find the book if there were no brownouts in Iligan.  So perhaps brownouts are not a bad thing after all

*Snickers*

Best Buy Ever

Bought for 10Php at BookSale

 

Categories: Uncategorized | Leave a comment

Welcome Nginx!

Due to a lot of OOM errors from Apache,  I finally decided to move to Nginx.

This was not a desperate move, I use Apache because its just easier to configure LAMP than Nginx especially on rewrites(SEO purposes).  Also, not the reason why I’m using Apache.

Im using Apache simply because I’m sharing my web server with some clients to cut down cost on hosting.  Now I’m using separate cloud instance for my clients who prefers Apache over Nginx.

Next up varnish!

Cheers,
Wardy

Categories: Uncategorized | Leave a comment

Power Interruption in Iligan City

I hate power interruptions!  It’s interferring with work! with reading! with progress! with water supply! With business! and of course online perks!
It messes everything up!

Categories: Uncategorized | Leave a comment

Dorward is excited

17 Dragonlance books and 5 Forgotten Realms will be arriving today courtesy of Ms. Tess Po.

Thank you very much Ms. Tess

Categories: Uncategorized | Leave a comment

Make Dorward Happy

Send him your Dragonlance, Wheel of Time, Forgotten Realms, Magic the Gathering and Any Margaret Weis and Tracy Hickman Fantasy books

Categories: Book | Tags: , , , , | Leave a comment

LAMP and memory issues in digitalocean 5$ droplets

I recently move cloud hosting of my domain and some other personal domains from ec2 to digitalocean.
installed softwares, did hardening on security and installed LAMP configure my domain and other some other domains.

I noticed that after 20-30 minutes MySQL flat out died, resulting to all domains using mysql to issue an error regarding database connectivity.

MySQL died due to oom killer killing it , having garnered the top score prior to the kill.
This lead me to adjust oom_score_adjust to a very low value to prevent oom killer from killing MySQL.   Below is my script to adjust mysqld oom_score

#!/bin/bash

OOM_SCORE=`cat /proc/$(pidof mysqld)/oom_score`
if [ "$OOM_SCORE" -gt 20 ]
then
 OOM_ADJUST=$((OOM_SCORE - 20))
 echo "adjust oom_score_adj by $OOM_ADJUST"
 echo "-$OOM_ADJUST" > /proc/$(pidof mysqld)/oom_score_adj
fi

It basically did what I want and now MySQL works as expected.  But that’s not the root of the issue.  Basically if oom killer kicks in, it means you ran out of memory.

By default the cheapest plan for digitalocean does not have a configured swap space.  In a nutshell, Swap space are used when the OS ran out of memory.

Ideally,  you do not want mysql to swapped out of memory because it lowers performance especially on high traffic websites.  But for my needs its ok.

Installing a swap space.

There are two methods of having a swap space.  The most popular is installing a swap partition and another method is installing a swap file.

unlike amazon ebs back t1.micro instances 8GB disks, digitaloceans cheapest droplents have 20GB.  Its big enough that I can use some as a swap file.

1) Create a 1GB file called swapfile

#dd if=/dev/zero of=/swapfile bs=1024 count=1048576

2) Prepare the file to be used as a swap file

#mkswap /swapfile

3) Activate the swap file

#swapon /swapfile

4) Check the newly activated swap

# free -m

5) Make changes permanent activate swap during the boot process

#echo "/swapfile swap swap defaults 0 0" >> /etc/fstab

Categories: Linux, Tutorial | Tags: | Leave a comment

Koans

Koan - A paradoxical anecdote or riddle, used in Zen Buddhism to demonstrate the inadequacy of logical reasoning and to provoke enlightenment.

A story about a Zen master and his student, sometimes like a riddle, other times like a fable, which has become an object of Zen study, and which, when meditated upon, may unlock mechanisms in the Zen student’s mind leading to satori; A riddle with no solution, used to provoke reflection on the … en.wiktionary.org/wiki/koan

One way to learn programming languages is through koans,  learning through koans are now widespread and is made possible mostly because of unit testing.  Through these koans, one can learn the programming language, its application and best practices.

Here is a list of Programming Languages and their koans.

Ruby, Java, Javascript, Clojure, CoffeeScript, Python, Objective C, C++ , Scala,  PHP, C#,  F# , Go, Haskell, lua, PHP UnitMongoDB

The last two in the list are not Programming Languages are are still good koans for those who wish to learn them.

 

Categories: Programming Languages, Tutorial, Uncategorized | Tags: , , , , , , , , , , , , , , , , | Leave a comment

The Duct Tape Programmer

I bought the book “Coders at Work” at BookSale last year.

It’s a great book, a compilation of interviews by Peter Siebel with the great programmers of all time.  If you are in cebu and a close friend(One of those who used to slept at my grandma’s house), I would gladly lend you this book.

The first chapter is a very rewarding read, It features Jamie Zawinski.  Reading about him in the net lead me to a post by Joel Spolsky, a notable figure in the IT industry, with blog Joel On Software, he created Stack Overflow sometime 2008 together with Jeff Atwoood, also a notable figure in the IT industry with blog Coding Horror 

This is the post . It features what Joel called as “The Duct Tape Programmer”, He goes on with describing the qualities and skills required to become a duct tape programmer.

Categories: Blog, Book, Famous People, Uncategorized | Tags: , , , , , , , , , , , , , | 1 Comment

Jessica Sanchez Sings And I am Telling You gets to Top 3

Have you been reading my posts,  You should now by now that I am a Jennifer Holliday fan.

Jessica Sanchez sang the song  beautifully, she was able to hit most of the notes, from Jennifer Holliday, I can truly say this is by far the best rendition of the song of course after the original performance rightfully gaining her one of the top 3 spots.

Jessica is really superb, she can sing with the same intensity and voice at par with  Jennifer’s.  Without a doubt she is the most versatile and most talented contestant for American Idol 2012.

She deserved to win.

However, being a Jennifer Holliday fan,  I can’t help but notice that Jessica was not able to deliver the emotion of the song,  Perhaps she was not able to watch the original performance.

The original artist of any song normally sang them filled with emotion,  It would be worthwhile to watch how they did it and truly grasp the emotion they are trying to convey.

Jessica sang a great rendition of the song, but it could have been better.

Categories: Entertainment | Tags: , , , , , | Leave a comment