Linux virtualization with QEMU/KVM and libvirt

Linux kernel features the Kernel-based Virtual Machine – a hardware-based virtualization infrastructure (a type-I hypervisor). QEMU is an emulator/virtualizer software that, when used together with KVM, allows you to run virtual machines at a near-native speed. Using these together with Libvirt library, which, apart from the programming API, provides virt-manager or virsh (libvirt shell) tools makes virtual machine management a breeze. This duet is used by many successful open-source commercial projects like OpenStack or CC1.

In this post I’ll describe how to get all of these going, showing you how easy it is to create and run virtual machines that are almost as fast as your own hardware host using professional grade tools – QEMU/KVM and Libvirt

Read more

A crash course in GNU Debugger – A GDB tutorial

A GNU Debugger, originally created by Richard Stallman in 1986, is a standard debugger for the GNU operating system and an essential tool for software developers. Being a portable application, it is widely used on many Unix-like operating systems as well. In this article I’ll show some basic commands and techniques for debugging software with GDB. I’ll be using GDB version 7.9 under Arch Linux on x86-64, unless noted otherwise. Source code for this article is available on my GitHub site.

Read more

Memory allocation debugging with glibc – heap consistency checks

Although there are many great tools to debug memory allocation errors, like Valgrind or Electric Fence, sometimes these tools aren’t available or it’s not feasible to use them. In this post I want to show you a debugging technique that doesn’t require any other software beside GNU C library. All of the examples were created and ran on a standard x86-64 machine.

Read more

Memory allocation debugging with glibc – tracing

Although there are many great tools to debug memory allocation errors, like Valgrind or Electric Fence, sometimes these tools aren’t available or it’s not feasible to use them. In this post I want to show you a  debugging technique that doesn’t require any other software beside GNU C library. All of the examples were created and ran on a standard x86-64 machine.

Read more