8-bit Crafts

8-bit Crafts

A long time ago, in a work place far far away, a co-worker gave me some Perler beads. They’ve been sitting in my game cupboard for years, but my wife finally found something fun for me to do with them: make re-creations of 8-bit sprites!

For my first attempt, I’ve made a fire flower from Mario. It took an hour or so, mainly because the red I thought I was digging out of the tub of mixed beads was actually a translucent pink, so I had to start over part way through.

Anyways, I think it turned out great! I think I’m going to create a 1-up mushroom next.

Read More

Making my Android faster

I got an Android phone a while back (a Samsung Intercept). I like it a lot, except it started getting slower and slower and slower.

After yelling at my phone profusely and spending an hour or so Googling, I discovered that a process called akmd2 was the culprit.

This process is what automatically switches the screen from portrait to landscape mode when you rotate the phone. Seeing as I actually hate that feature, I solved my problem by disabling it:

  1. Go to Settings
  2. Then Display
  3. Then uncheck Auto-rotate screen

That is it! My phone is now instantly super fast!

My phone has a slide out keyboard, so I can still get my screen to rotate by opening the keyboard.

Anyways, I hope this helps someone that runs into the same problem.

Read More

Water Storage

Water Storage

My wife and I have been working hard on building up a good supply of food and water. This is partially because we hate going shopping all the time, but mainly because it is good to have extra food in case of an emergency.

Last summer we were without clean water for a few days. Luckily we had stored some water in old juice containers so we had something to drink. It is difficult though to store a lot of water one gallon at a time, so we decided to buy a water drum.

A lot of people recommended getting a single 55 gallon drum, but we decided to buy two 15 gallon drums instead. We got this drum and this drum combo (which comes with a siphon and a bung wrench, which you need to open/close the drums and conveniently get the water out).

Here is my reasoning for going with 15 gallon drums instead of 55 gallon drums:

Weight. Water is heavy. A full 55 gallon drum weighs about 470 pounds. Despite my athletic appearance, there is no way I could move a 470 pound drum. A 15 gallon drum weighs about 130 pounds, which is still heavy, but at least I have a hope of moving it.

Portability. In an emergency, I don’t think I’ll be able to get a 55 gallon drum into the back of my car. I could probably get both 15 gallon drums in it though if I really felt I needed to. It is also a lot easier to pull a 15 gallon drum out of the basement to refresh the water than it is a 55 gallon drum.

Storage. I live in an apartment. I really don’t have a convenient place to store a giant 55 gallon drum.

Redundancy. If one barrel gets contaminated somehow, I at least still have 15 gallons of clean water in the other.

To keep our water fresh, we’ve put 1 tablespoon of bleach in each 15 gallon drum. It is recommended to change the water after the first 6 months, and then every 12 months after that.

We bought a couple cinder blocks from Lowe’s (these things are cheap, maybe $1 – $2 max) and put a board on them so our drums won’t be resting on the floor of our basement. When we need the water, we’ll go down with a smaller bucket and siphon some out.

Read More

Poor man’s process monitor

I lost some money a few days ago because Apache crashed on my VPS that is running the Fake Mail Generator. I’m too cheap to pay for web monitoring, so I had no idea it happened until I noticed my earnings were down.

So I had a few options:

  1. Pay for a web monitoring service. Knowing that Apache crashed would have been nice, but I still might have to get up in the middle of the night to start it back up.
  2. Roll my own web monitoring service. This is something I really want to do, and perhaps host on a couple of cheap VPS servers, but it still has the problem of not magically starting Apache for me if it dies.
  3. Install daemontools. This is probably the best option, as it would let me use supervise to make sure Apache restarts if it dies for some reason. But I’m lazy and just want a quick solution.
  4. Rig something together in 2 minutes that will get the job done.

I went with option #4, and this is what I came up with:

string=`ps ax | grep -v grep | grep httpd`

if [ -z "$string" ]
/usr/local/apache2/bin/apachectl start

I saved that to a file called keepApacheRunning and made it writable using chmod +x keepApacheRunning.

Basically this little script will see if httpd is in the process list, and if it isn’t, it will start Apache. Pretty straight forward.

To make it run, I added this entry to crontab:

* * * * * /www/keepApacheRunning

This will run it every minute. So my max downtime is about a minute. I can live with that.

Read More

Postfix with MySQL support on CentOS

I had the need to get Postfix working with MySQL support today on CentOS 5. The version of Postfix that is in the CentOS yum repo, unfortunately, doesn’t have MySQL support, and I didn’t want to compile from source.

Luckily, there is a way to get Postfix with MySQL installed using yum:

Caution: These instructions will reset your Postfix config files to the defaults. Make sure you have backups first!

First, add a few lines to your /etc/yum.repos.d/CentOS-Base.repo. The section headers should already exist, so add the additional lines immediately under the existing section header:




This tells yum to ignore the Postfix package in the normal base and update repos, and instead get it from the centosplus repo.

Next, uninstall your existing Postfix and install the new one:

yum remove postfix
yum install postfix

At this point I ran into an issue that was causing yum to refuse to install the new Postfix. I’m using the latest MySQL server RPM from MySQL.org, which isn’t compatible with this new version of Postfix. To fix this, I downloaded/installed the MySQL compatibility RPM that matches my version of MySQL server. This allowed Postfix to install without any problems.

Voila! You are done! You can make sure things worked by running postconf -m and verifying that mysql is listed.

Read More