ZFS NAS using CentOS 7 from tmpfs

Published Tuesday, October 24, 2017 (700 words, 4 minutes to read).

Following up on the CentOS 7 root filesystem on tmpfs post, here comes a guide on how to run a ZFS enabled CentOS 7 NAS server (with the operating system) from tmpfs. Hardware HP ProLiant MicroServer HP ProLiant MicroServer Remote Access Card AMD Turion™ II Neo N54L Dual-Core Processor 2x 8 GB 1333 MHZ ECC memory modules 4x 4 TB SATA hard drives (HGST, Western Digital and Seagate) Built-in Broadcom Limited NetXtreme BCM5723 Gigabit Ethernet adapter Preparing the build environment The disk image is built in macOS using Packer and VirtualBox.... read more

CentOS 7 root filesystem on tmpfs

Published Friday, January 6, 2017 (700 words, 4 minutes to read).

Several years ago I wrote a series of posts on how to run EL6 with its root filesystem on tmpfs. This post is a continuation of that series, and explains step by step how to run CentOS 7 with its root filesystem in memory. It should apply to RHEL, Ubuntu, Debian and other Linux distributions as well. The post is a bit terse to focus on the concept, and several of the steps have potential for improvements.... read more

Filebin upgrade

Published Sunday, May 29, 2016 (600 words, 3 minutes to read).

https://filebin.net is a public and free file upload/sharing service. Its main design principle is to be incredibly simple to use. It has been in production for several years, and has more or less been unmodified until now. Today it has been upgraded in several ways, and this post aims to elaborate on some of the changes. Complete rewrite The previous version of Filebin was written in Python and kept meta data in MongoDB.... read more

Gofer - Simple notification IRC bot

Published Friday, January 8, 2016 (300 words, 1 minutes to read).

Gofer is an notification type of IRC bot which is simple to deploy and super easy to integrate with existing services. It serves two main purposes: Process messages in IRC channels and execute commands to trigger actions based on pre-defined patterns. A good use case is to look for messages matching #\d+ (for example #1337), look up the title and status in a issue tracker and print the information back in the IRC channel:... read more

Monitor stand / tabletop table IKEA hack

Published Wednesday, September 16, 2015 (300 words, 2 minutes to read).

Background I needed something that would put my desktop monitors at the proper height on my desk. Instead of simply placing the monitors on some cardboards boxes, I decided to pick up something from IKEA to make a custom tabletop table / monitor stand. Hardware Article # Item Price 102.678.95 CAPITA 4 pack of stainless steel legs, with a length of 16 cm NOK 95,- 301.... read more

Dummy API, Go rewrite

Published Saturday, May 16, 2015 (500 words, 3 minutes to read).

Dummy API was originally written in Lua for running on top of OpenResty. Reasons were high performance and simplicity. The most common Linux distributions do not provide packages for OpenResty in their repositories, which means that it has to be installed from source. This is straight forward, but it adds up - both in time required and extra build dependencies. The purpose of Dummy API is to be that web application that can be rapidly installed and started when it is necessary to test API managers and web caches with a proper web application.... read more

Varnish goes upstack with varnish modules and varnish configuration language

Published Thursday, May 7, 2015 (2100 words, 10 minutes to read).

This post was first published at High Scalability. Varnish Software has just released Varnish API Engine, a high performance HTTP API Gateway which handles authentication, authorization and throttling all built on top of Varnish Cache. The Varnish API Engine can easily extend your current set of APIs with a uniform access control layer that has built in caching abilities for high volume read operations, and it provides real-time metrics.... read more

Dummy API

Published Saturday, May 2, 2015 (500 words, 3 minutes to read).

Update: Dummy API has been rewritten in Go. The purpose of Dummy API to act as a performant, simple and flexible HTTP API to use when testing API gateway performance. Put it behing a API gateway and generate responses to it from a set of consumers/clients. The Dummy API will read the request headers and query parameters and generate the responses accordingly. Some examples are custom cache-control header, response status and response delays.... read more

Remote console on HP ProLiant MicroServer G7 N54L

Published Saturday, August 30, 2014 (200 words, 1 minutes to read).

I bought the HP ProLiant MicroServer G7 N54L a while ago. I threw in a HP MicroServer Remote Access Card Kit to get remote console and power management. While the power management, web UI and CLI (over ssh) works fine out of the box, the remote console (KVM) does not. What happens is that the KVM client shows the following Out of range message: To fix this, go into the BIOS.... read more

Altibox, TV- og datatrafikk over samme nettverkskabel

Published Thursday, May 22, 2014 (300 words, 2 minutes to read).

Altibox leverer en hjemmesentral hvor man henter ut TV-signal og internettilgang fra to (eller flere) forskjellige RJ45-porter. Som trådløs router har hjemmesentralen kun et minimum av funksjonalitet, og man skal ikke være en veldig avansert bruker før man vil rekonfigurere hjemmesentralen som en bridge og heller ha en egen trådløs router på baksiden. Dette gir også mening dersom boligen har flere etasjer, og hjemmesentralen ikke er kraftig nok til å levere god nok trådløs dekning.... read more

Temperature trend monitoring at home

Published Wednesday, February 19, 2014 (600 words, 3 minutes to read).

Background I’ve got balanced ventilation in my apartment. It works OK, but I don’t fully understand how it behaves if knobs are pushed and pots are turned, and I’m definitely not sure if its performance is as good as I should expect. I’m going to do some measurements to see how the system reacts to changes in the outside temperature and tuning of the various settings. The first parameter to measure is the temperature in the air intake, exhaust air and some of the ventilation valves in the different rooms in the apartment.... read more

CentOS/RHEL/SL 6: root filesystem on tmpfs, UPDATE #2

Published Sunday, June 23, 2013 (700 words, 4 minutes to read).

Update 2017-06-30: Please see the updated guide which is more generic. In a previous post, I’ve explained how to boot EL6 from memory without having / needing a physical disk. A bright reader, Jeff, came up with an alternative method. This alternative method does not involve dd’ing the image into a loop device, but instead copying the contents of the disk image directly into tmpfs. The result is higher write/read performance and generally lower memory requirements.... read more

CentOS/RHEL/SL 6: root filesystem on tmpfs, UPDATE

Published Thursday, March 21, 2013 (500 words, 3 minutes to read).

Update 2017-06-30: Please see the updated guide which is more generic. In EL6.4, the file /usr/share/dracut/modules.d/90dmsquash-live/dmsquash-live-root was updated so that the previous patch no longer works as it should. I’ve updated the patch, and here it is: --- original 2013-03-20 16:25:23.698846581 +0100 +++ new 2013-03-21 08:58:11.175339694 +0100 @@ -24,6 +24,8 @@ getarg readonly_overlay && readonly_overlay="--readonly" || readonly_overlay="" overlay=$(getarg overlay) +getarg toram && toram="yes" + # FIXME: we need to be able to hide the plymouth splash for the check really [ -e $livedev ] & fs=$(blkid -s TYPE -o value $livedev) if [ "$fs" = "iso9660" -o "$fs" = "udf" ]; then @@ -132,7 +134,10 @@ BASE_LOOPDEV=$( losetup -f ) losetup -r $BASE_LOOPDEV $EXT3FS - do_live_from_base_loop + # Create overlay only if toram is not set + if [ -z "$toram" ] ; then + do_live_from_base_loop + fi fi # we might have an embedded ext3 on squashfs to use as rootfs (compressed live) @@ -163,13 +168,66 @@ umount -l /squashfs - do_live_from_base_loop + # Create overlay only if toram is not set + if [ -z "$toram" ] ; then + do_live_from_base_loop + fi +fi + +# If the kernel parameter toram is set, create a tmpfs device and copy the +# filesystem to it.... read more

KVM/Xen and libvirt: currentMemory, memory and ballooning. Where did my memory go?

Published Monday, September 24, 2012 (500 words, 2 minutes to read).

KVM and Xen provide a method to change the amount of memory in use by guests at runtime. The method is called memory ballooning [1, 2], and it must be supported by the guest operating system to work. In libvirt, memory allocation (and hence the ballooning capability) for a guest can be configured using the memory, currentMemory and memballoon tags: <domain type='kvm'> [...] <memory unit='KiB'>16777216</memory> <currentMemory unit='KiB'>1048576</currentMemory> [...] <devices> <memballoon model='virtio'/> </devices> </domain> The guest can never use more memory than specified in the memory tag and it is the amount of memory the guest will use at boot time.... read more

Filebin available on http://filebin.net

Published Friday, July 27, 2012 (100 words, 1 minutes to read).

Filebin.net was created to try out the new File API features in HTML5. Filebin is a web application that is somewhat similar to a pastebin, except that it’s for files. It is written in Python, and the code is available on Github.... read more

CentOS/RHEL/SL 6: root filesystem on tmpfs

Published Monday, April 30, 2012 (600 words, 3 minutes to read).

Update 2017-06-30: Please see the updated guide which is more generic. UPDATE: The patch below has been updated here. There are several scenarios where conventional hard drives are not really needed. Examples are HPC cluster nodes, virtualization nodes, home theater streaming PCs, silent desktops, internet cafés and embedded systems. Hard drives tend to fail, they are slow, they consume power, they generate heat and noise, and they are quite expensive if you need/want something faster and more reliable than SATA.... read more

KVM with iPXE in RHEL6

Published Wednesday, November 2, 2011 (500 words, 3 minutes to read).

A while ago I discovered the amazing iPXE project. It is a complete PXE implementation with lots of nifty features, based on the gPXE project. Redhat ships the gPXE firmware for qemu and KVM, and you might want to use iPXE instead as the iPXE project currently seems to be more active. The major features (copied from ipxe.org): boot from a web server via HTTP boot from an iSCSI SAN boot from a Fibre Channel SAN via FCoE boot from an AoE SAN boot from a wireless network boot from a wide-area network boot from an Infiniband network control the boot process with a script First, download the source code:... read more


Published Monday, August 16, 2010 (300 words, 2 minutes to read).

Munincollector-ng is a perl script that collects graphs from multiple munin installations to display them in one page. A scenario where this is helpful is when you have (too) many munin clients on (too) many munin masters, and you want to look through some of the graphs - i.e. the Disk usage in percent (aka df) plugin - without spending/wasting too much time browsing through the less important graphs. It consists of one perl script and one configuration file.... read more