Linux Mint 18.1 + i915: Updating the Intel Graphics stack

Running Linux Mint 18.1 (kernel 4.4.0-53) on a Gigabyte Brix BACE-3160 (with an i915 graphics controller) , I had all kind of minor graphics artifacts (in particular a sluggish mouse pointer and Kodi felt heavy). So obviously, I went for updating the graphics stack. Intel supplies an tool for doing this automagically on a selected [...]

Script for fixing a lot of git tags

I needed to update a lot of releases, each designated by a tag, with a single fix, which took the form of a commit. This commit was marked with the tag “this”. #!/bin/bash for i in $(git tag | grep 2.0) ; do git checkout $i git cherry-pick this git tag -d $i git tag [...]

My golden Makefiles for compiling C programs

Single-source utilities This is the Makefile I use for compiling a lot of simple utility programs, one .c file per utility: CC=    gcc FLAGS=  -Wall -O3 -g -fno-strict-aliasing ALL=    broadclient broadserver multicastclient multicastserver all:    $(ALL) clean: rm -f $(ALL) rm -f `find . -name “*~”` %:    %.c Makefile $(CC) $< -o $@ $(FLAGS) The ALL [...]

Password-less SSH remote login demystified

This is documented everywhere, and still, I always find myself messing around with this. So once and for all: The files In any user’s .ssh/ directory, there should be (among others) two files: id_rsa and id_rsa.pub. Or maybe with dsa instead of rsa. Doesn’t matter too much. These are the keys that are used when [...]

Linux Malware Detect for occasional non-root use

Intro This is a minimal HOWTO on installing Linux Malware Detect for occasional use as a regular non-root user. Not that I’m so sure it’s worth bothering, given that contemporary exploit code seems to be able to go under its radar. Background One not-so-bright afternoon, I got a sudden mail from my web hosting provider [...]

LVM volume resizing jots

These are my jots as I resized a partition containing an encrypted LVM physical volume, and then took advantage of that extra space by extending a logic volume containing an ext4 file system. The system is an Ubuntu 14.04.1 with a 3.13.0-35-generic kernel. There are several HOWTOs on this, but somehow I struggled a bit [...]

systemd jots

I not an expert on this These are just my what-on-earth-is-going-on-here notes as I tried to understand how my Debian 8.2 (“Jessie”) machine boots up. Conclusion: It’s a mess. More specifically, it’s a weird mix between good-old SystemV init scripts and a nasty flavor of upstart. And they say it’s here to stay. Maybe. But [...]

Cursor control characters in a bash script

To control the cursor’s position with a plain bash “echo” command, use the fact that the $’something‘ pseudo-variable interprets that something more or less like a C escape sequence. So the ESC character, having ASCII code 0x1b, can be generated with $’0x1b’. $’\e’ is also OK, by the way. There are plenty of sources for [...]

Using Linux’ setpci to program an EEPROM attached to an PLX / Avago PCIe switch

Introduction These are my notes as I programmed an Atmel AT25128 EEPROM, attached to a PEX 8606 PCIe switch, using PCIe configuration-space writes only (that is, no I2C / SMBus cable). This is frankly quite redundant, as Avago supplies software tools for doing this. In fact, in order to get their tools, register at Avago’s [...]

Hexdump notes

General notes For plain byte-per-byte hex dump, $ hexdump -C To dump a limited number of bytes, use the -n flag: $ hexdump -C -n 64 /dev/urandom 00000000  9c 72 b0 43 da 6e 27 2f  f9 f1 34 06 60 d5 71 ad  |.r.C.n’/..4.`.q.| 00000010  cc 07 89 02 f7 f9 5f 85  f6 [...]