Blog

Creating a Virtual Java RPM
Java java rpm
Published: 2013-05-29
Creating a Virtual Java RPM

Some RPMs (e.g. jpackage.org’s tomcat7-7.0.39-1.jpp6.noarch.rpm) express their dependency upon Java by requiring a RPM that provides capability java (as opposed to, for example, depending on the existence of a file /usr/bin/java). On CentOS, this capability is normally provided by the java-*-openjdk RPM. Therefore, if you execute # yum install tomcat7 on a clean install of CentOS, yum will install OpenJDK in addition to Tomcat 7.

Some people prefer to run the Oracle JRE/JDK instead of OpenJDK. Oracle provides RPMs named jre-<em>version</em>-linux-x64.rpm and jdk-<em>version</em>-linux-x64.rpm to make installing them easier. Unfortunately, these RPMs do not provide the capability java. This means that if you already have the Oracle JRE installed, and you install a RPM which requires the capability java, the OpenJDK will be unnecessarily installed (and might even become the default!).

Read more...
Pronounciation of GIF
Technology gif
Published: 2013-05-21
Pronounciation of GIF

The Oxford English Dictionary accepts both pronunciations [of the word GIF]. They are wrong. It is a soft ‘G,’ pronounced ‘jif.’ End of story.

Booting an Acer Aspire easyStore H340 from External USB
Technology easystore nas
Published: 2013-05-19
Booting an Acer Aspire easyStore H340 from External USB

A couple of years ago I bought a Acer Aspire easyStore H340 to use as a home NAS device. While the H340 came with Windows Server, I decided to replace it with Debian Linux running on an external USB stick. Besides using it for basic file storage, I use Nginx to stream MP4s to Roku devices throughout my home using Roksbox; I use forked-daapd to stream FLACs to iTunes (albeit with limited success – foobar2000 pointing to the CIFS file share works better); and I use CrashPlan to back up my important data (e.g. pictures) to the Internet.

Read more...
Passive Indexing Wins Again
Finance / Investing finance indexing
Published: 2013-04-09
Passive Indexing Wins Again

I’m a bit of a Boglehead, and the data appears to back me up. From http://www.cbsnews.com/8301-505123_162-57578430/active-managers-lost-again-in-2012/

In 2012, 63 percent of large-cap funds, 80 percent of mid-cap funds and 67 percent of small-cap funds underperformed [relative to their benchmark]. The only asset class to see the majority of active funds outperform was large-cap growth, with 54 percent beating their benchmarks. The worst performance came in mid-cap growth funds where 87 percent failed to outperform.

Read more...
Scaling Varnish
Varnish varnish
Published: 2013-04-08
Scaling Varnish

As seen on varnish-misc@varnish-cache.org:

I read one web testimony of a person who used Varnish to scale a site up to almost 200 million page views a month.

I’d like to find someone who has that level of expertise.

At work we have a Varnish cluster which, during the month of March, served over 17 billion requests for an average of 6,400 requests/second.

This cluster contains two physical machines with 24 cores and 192GB of RAM apiece. These machines have tons of spare capacity; their load average peaked at approximately 4. We’ve even considered virtualizing the cluster.

Read more...
Unix File Extension
Unix sed unix
Published: 2013-04-05
Unix File Extension

This useful little snippet can be used to find the unique list of extensions for all files in a directory and all its subdirectories. I can never remember the precise awk incantation for this:

1
% find . -type f | awk -F. '{print $NF}' | tr '[:upper:]' '[:lower:]' | sort -u