check_mk: Monitor Nginx Status

On the Check_mk web UI visit:WATO menu > Monitoring Agents In the list on check agents you should find the nginx_status. Clicking on it shows the code for the check. Copy that code to the client server. The location on web001 for the check (for me... » More

check_mk: Add Custom Notes to Services

The scenario here is that I would like to add a 'custom notes' link to any services with the word 'postfix' in the name of the service. I started by visiting WATO and drilling down to a host and one of the services I was interested in adding notes... » More

check_mk: Customise Icon Visibility

By default check_mk places icons under a 'hamburger' icon as shown below. I wanted the 'Custom Notes' icon to be visible at all times rather than being located under the actions icon. To do that visit the 'Global Settings' menu item and under... » More

Reboot Linux Server

On a server where normal reboot commands such as 'shutdown -r now' are not working and if you don't have access to an iDrac or similar the following worked: echo 1 > /proc/sys/kernel/sysrq echo b > /proc/sysrq-trigger

Bash to Python – Playing with CSV

In the past I have been too willing to use bash scripts for grepping and awking CSV files. The code snippet below is a starter for doing similar with python and while far from perfect, demonstrates calling another system command and manipulating... » More

Laravel Passport Oauth

With a basic CRUD Laravel app containing API routes I wanted to protect the API behind Oauth. So I followed the instructions on the Laravel documentation and a great video by Andre Madarang on Youtube. After following the steps of requiring... » More

Rename Files with Python

Simple wee python script for renaming files in a directory. I had a bunch of mp4 files that had a reference code at the end rather than the front so renaming to put the reference code at the front would keep them in order e.g. myfile-m6-03.mp4 to... » More