Author: virantha

09 Mar

Migrating XenServer Virtual Machine VDIs to KVM

After having worked with Xenserver 6.2 for over a year now, I've decided to migrate away from it. It just wasn't stable enough with SATA pass-through on my machine, and it had some really annoying bugs with the way snapshots and backups were handled:

  • Under load, my SATA 8-bay …

26 Jan

Building a low-power home file server using Intel's Avoton platform

In this post I'll detail the hardware I used to upgrade my 2 year old home server that was getting a little bit long in the tooth. I wanted to replace a Core i7 based XenServer host connected to an external 8-bay SATA enclosure that had an idle power consumption …


22 Aug

Setting up the Edgemax EdgeRouter Lite (ERLite-3) in a Home Environment

This is just my cheat sheet on setting up the EdgeRouter ERLite-3 in a home environment. I recently migrated to this after a long search for a low-power firewall and router solution. Prior to getting this beauty, I'd migrated my stand-alone PC running Ipcop/Smoothwall to a Xen virtual machine …


21 May

Installing Ubuntu 14.04 LTS (Trusty Tahir) VM on a XenServer 6.2 host

I had a hard time getting Xenserver 6.2 to install a new VM with the latest long-term-support version of Ubuntu (14.04). The process documented below, pieced together from several posts, leads to a fairly straight-forward install.

Fix your pygrub on the Xenserver host

Based on this post, do …


12 May

Changing tab stops in Vim

I normally use spaces in my files instead of tabs for indentation, with 4 being my default indent width. Sometimes, I need to change this on existing files to 2, so for the most part, the following sequence works. First,

set ts=4 sts=4 noet
retab!

This changes every …


08 May

Setting up Google Oauth2 API

This documents the steps necessary to enable Google Oauth in your web application for authentication.


07 May

Example of how to authenticate using Oauth2 in Ember.js using Implicit Grant (client-side)

This post will show a quick and complete example on how to authenticate someone using their Google credentials in your Ember.js web application. This uses the implicit-grant scheme in Oauth2, so everything happens on the client side, without exposing the user's Google credentials or requiring a back-end server. Obviously …


15 Apr

Replacing a Noisy Broan Bathroom Fan (Builder's grade 688)

Here are my quick notes on replacing noisy contractor grade fans in bathrooms. The Broan 688 and variants are common installations in new and rehabbed homes because they're relatively cheap. But boy, at 4 sones sound output, they're very loud and irritating to leave running for a long time.


30 Mar

Detecting color vs greyscale and blank pages during scanning

Recently, I needed a way to detect if a color scanned image was actually color or just contained greyscale/BW content. I also wanted to detect if an image was "blank", or just a continuous shade of one color. I couldn't really find a simple solution on the web, so …


30 Mar

ScanPDF - Usage guide

If you're looking for a simple way to use a multi-page scanner and get your document into a PDF in Linux without any proprietary or commercial software, then ScanPDF might be the solution. I wrote it to quickly take the Linux SANE scanner system output image files, and process them …


24 Mar

Getting around Xcode 5.1 clang -mno-fused-madd error

Recently updated to Xcode 5.1 on my Mavericks install, and when I went to update a few Python PyPI packages like reportlab and fabric, I started hitting this error on the compile step:

clang: error: unknown argument: '-mno-fused-madd' [-Wunused-command-line-argument-hard-error-in-future]

After a little bit of googling, it seems like the …


17 Mar

One-touch scan enabling in Ubuntu Linux for the Fujitsu ScanSnap S1500

Here's how I managed to get Linux to recognise scan button presses on the S1500, and automatically initiate a scan to a pdf file. You first need to download Scanbd and install it. Unfortunately, there doesn't seem to be any apt repository for Scanbd, so I had to download the …


11 Mar

Font rendering fix in Chrome

Seems like there was a reason Chrome rendered the text on this web page rather poorly at first go: See this page, but basically you need to set the anti-aliasing for Chrome:

-webkit-font-smoothing: antialiased;

08 Mar

Pound reverse proxy and simpler URLs for webapps (Sickbeard, Plex, CouchPotato, Headphones, SABNZBD)

I run a plethora of local web applications that each listen on different ports, and I wanted to simplify their URLs so I could just type a hostname to access them:

Hostname mapping
Application Default URL Desired URL
Sickbeard http://linux-server:8081 http://sickbeard
SabNZBD http://linux-server:8080 http://sabnzbd …

02 Mar

Fix your Breville Smart Oven by replacing the thermal fuse

Breville Smart Oven BOV 450XL

In this post, I'll dicuss how I was able to quickly and inexpensively replace the thermal fuse on our Breville digital toaster oven. There were a few scattered forum posts from which I pieced together this information, even though this appears to be a common issue, and applies to the …


02 Feb

Digital Toaster Oven Options

Breville Smart Oven BOV 450XL

One of the best kitchen upgrades we did was replacing our old twist-a-dial toaster oven with one that integrates a digital control panel. This gives us precise toasting time control (just dial in the exact number of minutes and seconds you want) and avoids ending up with burnt toast because …


10 Jan

AirFrame: Usage guide

Download images from an authenticated Flickr account (or local filesystem) and push them wirelessly to a Toshiba FlashAir Wifi SD card mounted in a digital photo frame.

Features

  • Authenticates to Flickr to get …

09 Jan

AirFrame: Hacking together a WiFi photo frame with a Toshiba FlashAir SD card and Flickr

I'm going to describe AirFrame, a Python script I wrote that's available on GitHub under ASL2 open-source, that can automatically pull photos matching a given set of tags from an authorized Flickr account, and wirelessly push them to a WiFi enabled SD card sitting inside an inexpensive digital photo frame …


14 Nov

Starting a simple Flask app with Heroku

Flask and Heroku

Inspired by this article on Python Weekly, I thought I'd look into deploying a simple hello world application to Heroku, built on the Flask micro framework.

Here's my workflow:

  • Create a new directory and Python virtualenv (make sure virtualenvwrapper is installed!):

    cd ~/dev
    mkdir proj
    cd proj
    mkvirtualenv proj
    
  • At …


04 Nov

Creating new notes and attaching files using Evernote's Python API

Documents to Evernote

I managed to piece together how to attach a new PDF file to an Evernote note using their Python API, so I thought it might be useful to have a post that has all of this information together in one place.  I've put together a complete example that will:

  1. Authenticate …

© Virantha Ekanayake. Built using Pelican. Modified svbhack theme, based on theme by Carey Metcalfe