Alexa Thumbnail Service

Amazon offers some pretty cool services: S3, EC2, Alexa Site Thumbnail, and others. A while back I wanted to use AST with Django, so ended up writing the Python bindings to the REST API (they didn’t previously exist. I even wrote up a quick tutorial. Update: Amazon no longer maintains AST. I’ve decided to archive a few of the old sites, so no longer need to take thumbnails. However, a few other thumbnail services seem to have crept up, including SnapCasa", and WebSnapr.
Read Alexa Thumbnail Service

Charting the Hackers

A normal internet connection gets attacked, a lot. The majority of attacks are of the form “hello, anybody there?” – where most people just don’t answer. But sometimes, just sometimes, the question gets an answer. Depending on the answer, the attacker will start to explore. A few weeks back I was a little bored and started fiddling. I wanted to play with my Cisco, but also wanted to play with OSSEC, but also has a GIS craving. In the end I decided to create a map of the people who ask, “hello”.
Read Charting the Hackers

NetFlow into MySQL with flow-tools

I’ve been side-tracked on another little project, and keep coming back to NetFlow. For this project I’ll need to access NetFlow data with Django, but this is a bit tricky. First, I’m sort of lazy when it comes to my own project; maybe not lazy, I just like taking the most direct route. The most up-to-date NetFlow collector I noticed was flow-tools, and there is even a switch to export the information into MySQL. Sweet! However, I wanted to insert the flows into MySQL automatically, or at least on a regular basis. I first started writing a python script that would do the job, but after a few minutes noticed flow-capture had a rotate_program switch, and started investigating. Since I somehow …
Read NetFlow into MySQL with flow-tools

Zenoss Default Password

I’ve evaluated Zenoss before, but forgot the default password, and searching for it didn’t come up with anything quickly. I tried everything under the sun: password, 1234, admin, God, Sex, but alas, grep to the rescue: kelvin@monitor:/usr/local/zenoss/zenoss/etc$ grep admin * hubpasswd:admin:zenoss Update: it is listed on page 4 of the Admin PDF :)
Read Zenoss Default Password

Install ESX from a USB (no CDROM)

My little server doesn’t have a cdrom, but I didn’t want to actually run ESX from a USB (i.e. esx-on-a-stick). Here are my notes of configuring a flash disk to boot the ESX installer (so you can install it onto a local disk). For this demo, my USB is /dev/sdb Install the syslinux utils to your computer (apt-get install syslinux mboot) Install the MBR sudo install-mbr /dev/sdb Copy all the files from the ISO to your fat32 formated partition Install syslinux sudo syslinux /dev/sdb1 Move isolinux.cfg to syslinux.cfg, and try booting. If it doesn’t work, edit syslinux.cfg says something like: default menu.c32 menu title ESXi Boot timeout 100 label ESXi menu label Boot VMware ESXi kernel mboot.c32 …
Read Install ESX from a USB (no CDROM)

Migrating large disks into ESXi

I recently had the need to move a rather large (450GB) VMDK file from an external hard drive into ESXi. Since ESXi doesn’t support external hard drives, this makes things quite a bit more difficult. At first I tried using SCP to copy the file over (after enabling SSH access for ESXi). However, when I tried to do this the time left was almost 20 hours – a tad too long!
Read Migrating large disks into ESXi

OpenFiler Permission Issue

I’ve had issues before with OpenFiler where doesn’t update the permissions, although they appear correct in the UI. To rectify that, I stumbled upon a one liner that fixed it. Let’s say you have a group called “Trusted” that you want to have full access to your music folder. Here’s the one-liner: [root@files data]# pwd /mnt/openfiler/data [root@files data]# setfacl --recursive -m u:nobody:rwx,g:Trusted:rwx music
Read OpenFiler Permission Issue

Speeding Up VMWare Server

I found VMWare Server to have very slow I/O, and sought to improve it. Below are a list of tests I performed, the change, and the results. ### Host OS ### /dev/sdb1: Timing buffered disk reads: 220 MB in 3.05 seconds = 72.17 MB/sec kelvin@gorilla:~$ sudo hdparm -t /dev/sdb1 /dev/sdb1: Timing buffered disk reads: 266 MB in 3.01 seconds = 88.33 MB/sec kelvin@gorilla:~$ sudo hdparm -t /dev/sdb1 /dev/sdb1: Timing buffered disk reads: 310 MB in 3.01 seconds = 102.99 MB/sec ### Before Changes ### /dev/mapper/openfiler-data: Timing buffered disk reads: 8 MB in 3.36 seconds = 2.38 MB/sec [root@files etc]# hdparm -t /dev/mapper/openfiler-data /dev/mapper/openfiler-data: Timing buffered disk reads: 24 MB in 3.63 seconds …
Read Speeding Up VMWare Server

Out Camping

I’ve been a little delinquent in sharing my life stories, so hopefully this weekend will make up for the past few months. I decided it was time to go camping again, so on Friday night I met Remko and Daisy and drove north towards Colo: the middle of nowhere, yet only 45 minutes from the outskirts of Sydney. I set up my tent and started cooking dinner: curry! That’s right, I was not exactly roughing it. Soon after dinner, I curled up in my new two-person tent and quickly fell asleep.
Read Out Camping