Bash
Windows 11 and WSL 2 DevOps environment
In this post I describe some of the settings and changes I made to make my Windows 11 and Ubuntu WSL2 into a fully fledged development environment. Here are the settings and tools I use for DevOps / SysOps on Windows.
Managing KVM VMs with virt-manager on Windows
In this post, I will show you how to connect to your KVM VMs (virtual machines) in Windows 10 via SSH using virt-manager (Virtual Machine Manager) and qemu+ssh://. This allows you to manage your virtual machines from Windows.
Bash function to generate a secure random alphanumeric string
You can use this Bash function in your .bashrc file to generate a random alphanumeric string easily. This comes in handy when you need to generate a long, secure password for example. Adjust to your needs.
Setting up Monit monitoring in Windows Subsystem for Linux WSL
A couple of years ago, I wrote a blog article about setting up Monit monitoring on an Ubuntu VM on Hyper-V. Now it’s time to do the same, but then in Windows Subsystem for Linux, or WSL. So, without further ado, here is how to install and configure Monit monitoring in Windows 10 WSL.
Release hold queue email in Postfix – postsuper
The postsuper command controls different types of queues in the Postfix mail system, like the deferred or hold queue. This post shows you some Postfix queue operations to maintain your mail servers.
Restore single MySQL table from a full mysqldump backup file
Learn how to restore a single table from a full MySQL mysqldump backup file using Bash shell in Linux
Generate pseudorandom passwords with OpenSSL
OpenSSL comes in handy when you need to generate passwords or random strings. For example for system accounts and services. In this short post I'll give you a quick example on how to generate random passwords with OpenSSL in Linux (Bash), Windows and PHP.
Tunnel RDP through SSH & PuTTY
Have you ever been in a situation where you needed to perform remote administration on a Windows Server, and the RDP port 3389 is blocked on a firewall? You can tunnel RDP over SSH with PuTTY
Turn off swap
Learn how to turn off swap in Bash, because when a swap partition is enabled Linux starts swapping, which may degrade (MySQL) system performance
Monit monitoring on Ubuntu 14.04 VM on Hyper-V
In this post you’ll learn about setting up a Monit monitoring service for your websites and services. Monit is a free and open source service monitoring application which can perform various event-based actions. Monit can send email notifications, restart a service or application, or take other responsive actions. We set Monit up on a Ubuntu 14.04 VM, built on Hyper-V. And we use Monit to monitor several websites, and send out notifications on downtime.
Convert decimal to hex in Bash, hexadecimal to decimal and dates to Unix timestamp
Cconvert decimal to hex hexadecimal to decimal and Unix timestamps in Linux Bash. A quicky for my archives.
Delete all MAILER-DAEMON emails in Postfix queue
How to delete all MAILER-DAEMON emails from your Postfix queue, when it matches a sender or recipient email address condition. In Postfix, there are various similar commands to delete messages from the Postfix mail queue, based on the Message-ID and/or email address for example...
Test SMTP authentication and StartTLS
Investigate SMTP authentication issues like a boss! When using TLS encrypted SMTP connections, it's always handy if you are able to create a SMTP logon credentials and test SMTP authentication over a TLS/StartTLS connection. Preferably from your command-prompt.
Bash: Grep through a large number of files – “Argument list too long”
/bash/grep and /bash/rm give me an error Argument list too long. Here is how to overcome this error with Bash grep and rm.
Check IP address blacklist status in Bash
Here is a Linux Bash shell script to check whether an IP address is listed in a DNSBL blacklist, or RBL. Using this script in Bash you can quickly test if an IP address is blacklisted.