→ Link to the library on Github
I’m writing C++ code for Unix environments for almost a decade now.
And the funny thing is that in the last five years, while working for three different companies, I had to write a new procfs parsing library every time.
All those companies were developing security products monitoring applications running on Linux machines, so using the procfs was inevitable.
But over time, necessity became great admiration. I simply grew very fond of the amazing creation called procfs. …
One of the best aspects of my day to day work is that I get to discover many hidden Linux gems, and this case was no different.
I was toying around with some ideas when I stumbled upon what seemed to be a relatively insignificant feature, yet another esoteric method some hardcore file-systems developer added when he needed an extra flag to tweak and squeeze some extra mips. I would’ve probably skipped it without looking back and overthinking it, but by now I’ve learned that this is the best way to explore the mysteries of my beloved OS.
The name…
The target of the following stream of ASCII characters is to shed some light on an area that is probably not common knowledge even for experienced system developers: loaders, libraries and executables in the ELF Linux ecosystem.
First, we’ll try to understand what happens when we run a basic program on our Linux machine. Then we’ll discuss libraries and what they bring to the table. Cover the differences between static and dynamic libraries and executables, and finally dive into the inner-works of the dynamic loader, learning how to control, configure and manipulate it.
Hopefully, we can cover enough concepts, tools…
Every time I read about a new system-programming language, I’m enthused about the possibility of learning cool concepts. Those languages are designed from scratch by groups of super-capable engineers with an accumulated experience of hundreds of years in order to create the “best” eco-system possible for this kind of programming.
This was exactly the reason that made me learn Go some time ago. Go is a very-cool language, conceived in 2007 at Google and aiming to ease the development process for applications that involve multi-core machines and/or elaborate networks. …
Have you ever tried to dwell into the mysteries of Unix’s User IDs? Well if you have, I guess you probably found yourself with a headache. Every conversation I recall having in the office about edge cases and weird scenarios related with UIDs concluded with the phrase “Is this even possible?”.
Today, we’ll try to make some sense out of it, including some interesting examples & suggestions. But first, we owe ourselves a quick recap to paint a complete picture.
Recap:
…
Lately, I found myself building a CI/CD infrastructure using Vagrant. If this the first time you work with Vagrant, just like it was for me, you can also find my Introduction to Vagrant article, to get yourself up-to-speed.
During the development process, I found myself re-designing my solution multiple times as requirements evolved and the infrastructure grew and became more complex.
In this article I will discuss one of the more esoteric tasks I stumbled upon: Moving an existing Vagrant environment that uses VirtualBox as a provider from one directory to the other. One of the steps when preparing one…
As a Linux Low-Level developer, I always find myself in need for multiple Linux VMs to fiddle with.
Whether because I need to check something on multiple distributions, or simply because my newest hack to probe something in the Kernel will probably burn the VM and anything else around it.
After using native VirtualBox for many years, creating, managing and deploying machines, reverting to snapshots or whatever I decided to try out Vagrant, which seems quite mature and widely used nowadays. So what is Vagrant? By their own words:
“Vagrant enables users to create and configure lightweight, reproducible, and portable…
A software specialist passionate about elegant and efficient technology. I Love learning and sharing my knowledge.