today's howtos
-
XDA ☛ How to change the hostname on Ubuntu
If you've ever set up a Linux distribution like Ubuntu, you may have noticed the installer prompts you to enter a name for your machine. Commonly called the hostname, it's the name that identifies your Linux system every time you connect to another device over a network or Bluetooth connection.
After reviewing all the settings, toggles, and options during the installation procedure, you may have accidentally entered the wrong hostname. But don't worry — Ubuntu lets you change your system's hostname via GUI and a variety of terminal commands.
-
Gabriel Simmer ☛ Migrating Mastodon S3 Providers
So! With that decided, it was time to figure out our migration path. The plan was simple - using rclone, setup two remotes on a temporary virtual machine (or LXC container, in this case), and run a bulk transfer overnight. Once complete, we run one more sync then quickly swap the configuration on the Mastodon instance. The window of time between the last sync and Mastodon instances picking up the new configuration should be small enough that we don't miss any new media. Finally, we swap over the DNS to point to our R2 bucket, which should update quickly as the DNS was already proxied through Cloudflare.
-
Dedoimedo ☛ How to edit MP3 metadata and cover art using VLC
If you're old enough to have purchased music on CDs and alike, then you probably care about having and do have an offline collection of songs, usually in the form of MP3 files, on your computer somewhere. It ain't all about the streaming, right guv. Well, some of these songs may have incomplete metadata - they may not have cover art, the artist or the album information may be wrong or missing. This is often the case with songs bought a long long time ago. Or perhaps you've ripped your own CDs for backup, and didn't care about all them extra fields. Whatever the case, we want to fix this problem. Add, edit metadata and cover art for our music. How do we do that?
VLC. It's always VLC. No matter what media task you may have at hand, you should always ask yourself, can the lovely, free, open-source player called VideoLAN (VLC) do it? And by and large, the answer is yes. This phenomenal piece of software has been in my arsenal for a good two decades, and recently, I had a chance to try yet another superb feature it has. Let's continue.
-
University of Toronto ☛ Some notes about the Cloudflare eBPF Prometheus exporter for Linux
I've been a fan of the Cloudflare eBPF Prometheus exporter for some time, ever since I saw their example of per-disk IO latency histograms. And the general idea is extremely appealing; you can gather a lot of information with eBPF (usually from the kernel), and the ability to turn it into metrics is potentially quite powerful. However, actually using it has always been a bit arcane, especially if you were stepping outside the bounds of Cloudflare's canned examples. So here's some notes on the current version (which is more or less v2.4.0 as I write this), written in part for me in the future when I want to fiddle with eBPF-created metrics again.
-
University of Toronto ☛ A realization about shell pipeline steps on multi-core machines
Even when doing on the fly shell pipelines, I've tended to reflexively use 'sed -e ... -e ...' when I had multiple separate sed transformations to do, instead of putting each transformation in its own 'sed' command. Similarly I sometimes try to cleverly merge multi-command things into one command, although usually I don't try too hard. In a world where you have enough cores (well, CPUs), this isn't necessarily the right thing to do. Most commands are single threaded and will use only one CPU, but every command in a pipeline can run on a different CPU. So splitting up a single giant 'sed' into several may reduce a single-core bottleneck and speed things up.