Using an API in bash

I’ve continued to work on my create server script from time to time. The latest update was checking that we could connect to the Hetzner API using the key that is given and bailing out if we cannot. curl is a interesting and useful tool. curl has been around since 1996 and it is ubiquitous. curl is simple to use: curl https://l10systems will download this website. It’s also very powerful with many, many options.

Read More

Hetzner server creation script revisited

I’ve written a couple of scripts to create servers on Hetzner over the years to facilitate small projects and experiementation. My older scripts used the Hetzner CLI which was fine but I wanted a version without that dependency or any other dependencies. So, I rewrote it in bash without the CLI by using curl to call the webservices. Initially, I had used jq to work with the returned JSON but since the requirements were pretty simple, I refactored that out.

Read More

Very handy

This is a very nice write up about LXD and Multipass by Jon Seager. He’s not exactly neutral as a Canonical employee, but I agree with just about everything he says about LXD. It’s a really nice system for running containers and virtual machines. I haven’t used it much of late, but I found it to be a powerful and flexible. I was concerned that it would lose mometum when one of the principal developers left Canonical and forked the project, but LXD seems to be progressing quite well as does Incus.

Read More

Minty again

I upgraded my ancient but still working Lenovo X1 Carbon yesterday to the latest version of Linux Mint 21.3 from 20.3 yesterday. The name of the release, Virginia, is particularly appropriate here in the Old Dominion. It went well but took quite a while to get everything downloaded from my local mirror. The only hiccup was some confusion about what version was actually installed from the instructions. It seemed like the base 21, but on reboot was 21.

Read More

Fun with upgrades

I’m usually in the habit of keeping my Linux desktop up to date. Normally, it’s pretty uneventful to run the Ubuntu updater or do it on the command line. However, today something interesting happened. I ran the update, noted that there was a kernel update from 6.2.0-34 to 6.2.0-36 and let it run. The fun started when I rebooted my computer. On reboot, the WiFi network was gone. I’m using a pretty crappy USB network adapter that required some special drivers and apparently the update borked the driver.

Read More

Smaller than I would have thought

In the same vein as my post yesterday, I was very impressed by this description of how small you can make a simple ELF binary. Starting with the generic output of compiling one of the simplest possible C programs from gcc at 3998 bytes, the article outlines how you can slim it down. The first steps are using the features in gcc to optimize the size. That gets it down to 2616 bytes.

Read More

There is a lot going on

The title is generally true, but in this case, I’m talking about an interesting article about the steps that happen when you run python3 hello.py. It’s a really nice breakdown of all the steps from figuring out the path to the python executable to mapping that file on the disk to creating a new process to finding the ELF file to linking to libraries to printing out “Hello World!”. The detail is nice.

Read More

Going private with open source

In a continuation of recent changes to open source businesses, SUSE has decided to go back to being a private company. SUSE’s foray as a public company was certainly not profitable for investors who bought in at the IPO (thankfully, not me) but represents a good deal for current shareholders. My experience with SUSE has been very positive. I used it to deploy some SAP HANA databases about ten years ago and it was a very nice distro with some interesting configuration and management tools.

Read More

It's alive!

I recently enabled Kernel Livepatch on my Ubuntu 22.04.3 desktop system. Livepatch is intended for systems that you don’t want to reboot. It’s completely overkill for a desktop that I can reboot whenever I need to but I wanted to understand it better. Kernel Livepatch is part of the Ubuntu Pro offering that is free for a limited number of systems - five systems currently. That seems like a pretty smart play by Ubuntu to differentiate their offering a little bit and get a premium service into the hands of more users who might then go on to buy a package later.

Read More

Rusty Linux

I’m intrigued that the Linux kernel is moving beyond C and allowing Rust in the 6.1 kernel. It seems like a 30 year run of using C is long enough. Times change and the kernel has to change as well. I don’t know much about Rust, but this makes me interested in taking a deeper look. Writing really solid C code is notoriously hard even using modern techniques to avoid buffer overflows and the like.

Read More