A collection of Linux Systems Administration articles

The Archives

Using salt-ssh to install Salt

Published on: 2016-07-19 17:30:00 | 9 min read

Using SaltStack's ability to run agentless over SSH to install the salt-minion agent

Creating a swap file for tiny cloud servers

Published on: 2016-05-18 03:30:00 | 5 min read

What is swap, and how to use a swap file to add memory to low memory cloud servers


Create self-managing servers with Masterless Saltstack Minions

Published on: 2016-03-22 14:30:00 | 13 min read

Using Saltstack's Masterless Minion architecture to create self-managing infrastructure


Using Travis CI to test Docker builds

Published on: 2016-01-11 14:00:00 | 9 min read

Walk-through on getting started with Travis CI and how to use Travis CI to test Docker builds


Getting started with Docker by Dockerizing this Blog

Published on: 2015-12-01 10:00:00 | 15 min read

This article covers the basic concepts of Docker and how to Dockerize an application by creating a custom Dockerfile

Preventing duplicate cron job executions

Published on: 2015-09-22 13:20:00 | 9 min read

This article will show both BASH code and utilities that can be used to prevent a cron job from having multiple running instances

Building Self-Healing Applications with Saltstack

Published on: 2014-12-30 14:50:00 | 7 min read

This article will explore creating an application that detects errors and corrects them by integrating Saltstack's API


A Quick and Practical Reference for tcpdump

Published on: 2014-10-13 14:50:00 | 19 min read

This article is a quick and practical reference for tcpdump, it covers the basics and dives a little bit into advanced usage. This article should cover everything a systems or network administrator needs to get started and troubleshoot issues quickly


Understanding Exit Codes and how to use them in bash scripts

Published on: 2014-09-02 14:45:00 | 4 min read

When writing a script that calls other commands, how do you know if they were successful or not? The answer is exit codes, exit codes are important and this article describes how to use them in your scripts and understand them in general.

Removing packages and configurations with apt-get

Published on: 2014-08-18 14:45:00 | 5 min read

Removing an installed package with apt-get isn't as straight forward as you would think. This article walks you through removing a package the right way to allow for re-installation later and how to fix when an install will not deploy configuration files.

Using salt-api to integrate SaltStack with other services

Published on: 2014-07-17 00:00:00 | 5 min read

This article will walk you through using salt-api as an entry point for other services to call SaltStack to initiate actions within your infrastructure.


8 Tips for creating better bash scripts

Published on: 2014-06-06 07:00:00 | 8 min read

This article covers some simple bash scripting best practices that can be used to improve the quality of your shell scripts.


Using Saltstack to update all hosts, but not at the same time

Published on: 2014-05-19 05:20:00 | 12 min read

This article describes several methods of updating salt minions and how to roll out those updates at different times to avoid taking down all hosts at the same time.


Using sysdig to Troubleshoot like a boss

Published on: 2014-04-18 09:30:00 | 6 min read

An introduction to sysdig, a new tool for advanced system troubleshooting.

Understanding the kill command, and how to terminate processes in Linux

Published on: 2014-04-01 08:55:00 | 5 min read

This article covers the Linux kill command and how it sends signals to terminate processes. Also why you should avoid using kill -9.

Getting around the Linux directory structure with the cd command

Published on: 2014-03-05 08:30:00 | 3 min read

An overview of the Linux directory structure and how to move around it with the cd command.

Sending redis traffic through an SSL tunnel with stunnel

Published on: 2014-02-18 08:50:00 | 6 min read

This article covers how to secure and encrypt redis traffic by using stunnel. Redis does not by default support SSL encryption, by using stunnel you can forward all redis traffic through a specified SSL tunnel.

Converting files from Windows format to Unix format with dos2unix

Published on: 2014-02-11 08:00:00 | 3 min read

This article explains what end of line characters are and how to use dos2unix to convert files that contain Windows EOL characters to a Unix format.

SaltStack: Getting redundancy and scalability with multiple master servers

Published on: 2014-02-04 08:00:00 | 7 min read

A how to article on setting up multiple saltstack master servers for redundancy and scalability. With SaltStack you can easily setup 2 or more master servers in a round robin configuration to provide high availability and scalability to your infrastructure automation tools.


8 examples of Bash if statements to get you started

Published on: 2014-01-27 08:00:00 | 5 min read

This article shows examples of how to use BASH if statements in scripts and command line. This is a good starter tutorial for those who haven't quite mastered BASH yet.

Using rsync to synchronize a local and remote directory

Published on: 2014-01-07 08:00:00 | 4 min read

An introduction to rsync and instructions on how to setup an automated rsync copy between two hosts

Yum Plugins: Verifying packages and configurations with Yum Verify

Published on: 2013-12-23 08:00:00 | 2 min read

An introduction to Yum Plugins and Yum Verify


Installing Redis and setting up Master - Slave Replication

Published on: 2013-11-12 08:00:52 | 3 min read

A guide on how to install Redis and setup Master - Slave replication between two or more Redis instances

Managing DNS locally with /etc/hosts

Published on: 2013-10-29 13:27:14 | 3 min read

An article that explains what the heck the /etc/hosts file is and how you can use it to manage DNS locally


5 Bash for loop examples to make command line tasks more efficient

Published on: 2013-10-21 08:15:26 | 4 min read

Examples of bash for loops that can make any shell users life easier

Install RackTables and start tracking your IP address inventory

Published on: 2013-10-14 07:20:46 | 4 min read

RackTables is an interesting IT inventory tracking system that can be used to track IP addresses as well as the hardware they are attached to.

Symlinks vs Hardlinks and how to create them

Published on: 2013-10-10 13:00:08 | 4 min read

An article that explains the differences between symlinks and hardlinks and how to create them

Changing the default nice value for a user or group

Published on: 2013-09-30 14:53:19 | 1 min read

How to make a niceness value default for any user or group using /etc/security/limits.conf

Remote Command Execution with SaltStack

Published on: 2013-09-23 09:49:08 | 4 min read

A guide on using the Remote Command Execution abilities of SaltStack

Understanding a little more about /etc/profile and /etc/bashrc

Published on: 2013-09-16 09:00:13 | 2 min read

What is the /etc/profile and /etc/bashrc files? What do they do? Read more to find out.

Setting process CPU priority with nice and renice

Published on: 2013-09-09 09:24:03 | 3 min read

How to set a CPU priority (niceness) value with the nice and renice commands


Getting started with SaltStack by example: Automatically Installing nginx

Published on: 2013-09-03 08:00:23 | 8 min read

A walkthrough on installing and setting up SaltStack using nginx as an example usecase

Finding the OS version & Distribution in Linux

Published on: 2013-08-28 06:08:03 | 0 min read

A simple trick on finding out the OS version and Distribution of a Linux system you have command line access to

Reading files in reverse with tac

Published on: 2013-08-26 06:00:40 | 1 min read

A cool trick that shows how to read files in reverse with the tac command

Grepping a file without using cat, and other grep tricks

Published on: 2013-08-19 08:00:43 | 2 min read

A lot of sysadmins don't realize you can use grep without cat, this article should settle that. It also shows some other grep tricks.

SSH: Disable Host Checking for Scripts & Automation

Published on: 2013-07-22 14:00:26 | 1 min read

How to disable SSH host checking for both scripts and lazy users

Adding and Modifying Users and Groups in Linux

Published on: 2013-06-24 14:00:20 | 3 min read

An indepth guide on how to create and modify users and some simple tips that make user administration less of a nightmare

mkisofs: Repackaging a Linux Install ISO

Published on: 2013-06-12 12:39:19 | 0 min read

Repackaging a Linux installation DVD using mkisofs

ssh-keygen: Creating SSH Private/Public Keys

Published on: 2013-06-10 12:00:33 | 1 min read

A how to on generating SSH Private and Public keys and using them for passphrase less logins

EMC PowerPath: superblock could not be read

Published on: 2013-06-05 01:55:38 | 1 min read

How to get around a simple setup issue where fsck tries to check a SAN disk before EMC PowerPath starts

Packing and Unpacking files with GNU Tar

Published on: 2013-05-23 15:07:37 | 5 min read

Simple guide on using a basic Unix and Linux tool GNU tar

Securely backing up your files with rdiff-backup and sudo

Published on: 2013-05-20 16:10:30 | 9 min read

A guide on setting up rdiff-backup and using sudo to run rdiff-backup without running it as the root user

Removing Files and Directories with rm and rmdir

Published on: 2013-05-13 04:16:25 | 2 min read

A simple guide on using rm and rmdir some of the basic Shell commands in Linux and Unix environments


Adding and Troubleshooting Static Routes on Red Hat based Linux Distributions

Published on: 2013-05-12 00:44:01 | 4 min read

Walkthrough on what Static Routes are and how to add them on Red Hat based Linux Distributions

Websphere MQ Cheat Sheet for System Administrators

Published on: 2013-04-22 23:50:22 | 2 min read

A simple cheat sheet that shows commands every sysadmin managing WebSphere MQ could use

Creating a local Yum Repository

Published on: 2013-04-15 12:30:44 | 2 min read

A walkthrough on creating your own local Yum Repository and keeping it synchronized automatically

How to force GPFS (or other tools) to connect via an alternate ssh port

Published on: 2013-03-19 19:56:24 | 2 min read

A simple solution to force SSH clients to default to a port other than 22


10 nmap Commands Every Sysadmin Should Know

Published on: 2013-02-25 18:45:41 | 5 min read

A cheat sheet list of 10 nmap commands that are extremely useful for every Systems or Network Administrator


Mitigating DoS Attacks with a null (or Blackhole) Route on Linux

Published on: 2013-01-14 13:15:03 | 2 min read

A guide on how to lessen the damage of a DoS attack by using a null route in Linux

Installing MySQL on Ubuntu/Debian

Published on: 2012-12-05 22:35:34 | 1 min read

How to install MySQL on Ubuntu or Debian based Linux Systems using apt-get

NFS: Setting up a basic NFS file system share

Published on: 2012-11-23 14:30:04 | 4 min read

Cheat Sheet: Cutting Text with cut

Published on: 2012-10-22 16:30:01 | 1 min read


iptables: Linux firewall rules for a basic Web Server

Published on: 2012-09-17 13:55:10 | 12 min read

A walkthrough on setting up a basic Linux Firewall for Webservers with FTP, SSH, MySQL and DNS services

Cheat Sheet: Crontab by Example

Published on: 2012-09-03 23:30:16 | 3 min read

Advanced Linux System Statistics and Diagnostics with SystemTap

Published on: 2012-08-20 12:25:41 | 4 min read

xargs: Build and Execute Commands with Arguments from Standard Input

Published on: 2012-08-13 11:30:38 | 5 min read


Troubleshooting High I/O Wait in Linux

Published on: 2012-08-06 14:45:13 | 5 min read

A walkthrough on how to find processes that are causing high I/O Wait on Linux Systems

Cheat Sheet: 21 useful find commands

Published on: 2012-07-22 16:54:23 | 1 min read

tc: Adding simulated network latency to your Linux server

Published on: 2012-07-16 15:00:53 | 1 min read


Sar & Sysstat: Linux Performance Statistics with Ease

Published on: 2012-07-08 00:22:24 | 6 min read

Tutorial on installing the sysstat package and using sar to identify performance statistics

When Zombies Invade Linux: What are Zombie Processes and What to do about them

Published on: 2012-07-02 16:55:46 | 3 min read


ACL: Using Access Control Lists on Linux

Published on: 2012-05-27 21:00:33 | 7 min read

A tutorial showing how to enable Linux Access Control Lists as well as how to use ACL's to go beyond basic permissions

Stat: Detailed information about a file

Published on: 2012-05-24 15:46:31 | 1 min read

Unix Shell: The Art of I/O Redirection

Published on: 2012-04-16 15:38:12 | 3 min read

Sysadmin Tools: Managing Linux from a Windows Desktop

Published on: 2012-04-01 19:28:31 | 3 min read

Linux Troubleshooting with strace

Published on: 2012-03-24 19:33:45 | 3 min read

Sudoedit: Securely allow users to edit files

Published on: 2012-02-26 18:04:56 | 2 min read

Why you should avoid running applications as root

Published on: 2012-02-20 15:24:29 | 1 min read


Cheat Sheet: systemctl vs chkconfig

Published on: 2012-01-19 15:20:54 | 0 min read

A simple cheat sheet that shows how to perform the same task with both systemctl and chkconfig


When it's Ok and Not Ok to use rc.local

Published on: 2011-12-30 09:30:25 | 2 min read

An article that discusses when it is appropriate and when it is not appropriate to use the rc.local file. A file that has been depreciated in some Linux distributions.

MySQL: tee saving your output to a file

Published on: 2011-12-26 16:00:21 | 0 min read

Learn to use the MySQL tee command to save the MySQL CLI output to a file and to your tty


Creating a new filesystem with fdisk, lvm, and mkfs

Published on: 2011-12-19 18:30:24 | 3 min read

Simple walkthrough on how to create a new Linux filesystem using LVM, fdisk and mkfs

Creating a read-only backup user for mysqldump

Published on: 2011-12-12 23:08:38 | 1 min read

How to create a read-only user that can be used for MySQL backups with mysqldump


How to check if a cron job ran

Published on: 2011-11-02 20:00:06 | 2 min read

This article shows a simple method to validate whether or not a cronjob ran on both Red Hat/Fedora based and Debian based Linux Systems

dscacheutil: Clearing DNS cache on OSX

Published on: 2011-10-25 20:00:00 | 0 min read

mysql: Creating a db and user

Published on: 2011-10-19 07:11:25 | 1 min read

How to setup a basic mysql database and database user with privileges to only the newly created database

gzip: Restoring original filename

Published on: 2011-10-14 20:30:06 | 1 min read

VirtualBox: Mom please stop getting spyware (Cheap VDI)

Published on: 2011-10-12 01:11:00 | 4 min read

bind: Checking a zone record for errors

Published on: 2011-10-06 19:32:39 | 0 min read

kill: Creating a core dump

Published on: 2011-09-22 22:24:55 | 1 min read

bash: Field Separator Variable

Published on: 2011-09-20 20:01:05 | 0 min read

mysql: Backup your user privileges

Published on: 2011-09-15 20:01:06 | 0 min read

How to backup your mysql privileges to a CSV file

find: Print type of file, inode #, filename and link destination

Published on: 2011-09-13 20:01:05 | 0 min read

mount: Disabling execution of scripts

Published on: 2011-09-08 20:01:06 | 0 min read

fsck: Force a filesystem check on next reboot

Published on: 2011-09-06 20:02:06 | 0 min read

grep: Counting Results

Published on: 2011-09-01 20:01:05 | 0 min read

Top: Show CPU Usage on all cores

Published on: 2011-08-28 20:31:05 | 0 min read

time: Tracking execution time

Published on: 2011-08-27 20:33:05 | 0 min read

dpkg: Listing installed packages

Published on: 2011-08-27 05:47:00 | 0 min read

Debian Packages: Installing

Published on: 2011-08-24 07:39:47 | 0 min read

apt: Searching for packages

Published on: 2011-08-24 20:32:05 | 0 min read

Websphere MQ: saveqmgr

Published on: 2011-08-21 13:33:06 | 0 min read

Sudo: Running as a specific user

Published on: 2011-08-20 20:32:05 | 0 min read

Find broken Links

Published on: 2011-08-19 20:32:06 | 0 min read

find: Remove files modified more than 31 days ago

Published on: 2011-08-18 20:31:00 | 0 min read

Sudo: List available commands

Published on: 2011-08-17 20:32:06 | 0 min read

ulimit: Checking the user limits of running processes

Published on: 2011-08-16 20:32:06 | 0 min read

Find: Print Size, Modify Date, Type, and Filename

Published on: 2011-08-15 20:30:00 | 0 min read

Find the biggest directories with du

Published on: 2011-08-14 20:30:05 | 0 min read

pstree: Associating Child Processes

Published on: 2011-08-13 20:30:06 | 0 min read

sar: System statistics

Published on: 2011-08-12 20:30:06 | 1 min read

yes: Repeated Text

Published on: 2011-08-11 20:33:06 | 0 min read

runlevel: Check your current runlevel. Then change it

Published on: 2011-08-10 20:30:06 | 0 min read

ssh: X11 Forwarding

Published on: 2011-08-09 20:30:05 | 0 min read

showmount: See available NFS Shares

Published on: 2011-08-08 20:00:05 | 0 min read

Counting with sort and uniq

Published on: 2011-08-06 02:20:00 | 0 min read

Filename manipulation with sed, awk and cut

Published on: 2011-08-05 06:27:48 | 1 min read

Bash: Repeated tasks with seq and for loops

Published on: 2011-08-04 00:41:00 | 1 min read

Yum: Search and Install

Published on: 2011-08-03 03:44:00 | 0 min read

Finding what installed a binary with YUM and RPM

Published on: 2011-08-03 07:05:00 | 0 min read

SMF: Enable apache [Solaris]

Published on: 2011-08-01 03:50:00 | 0 min read

tar: Exclude directories/files

Published on: 2011-07-26 08:00:32 | 0 min read

Checking your running kernel version

Published on: 2011-07-23 07:00:00 | 0 min read

Truncating a large log file

Published on: 2011-07-22 08:21:00 | 1 min read

rpm: Finding dependencies

Published on: 2011-07-22 07:51:00 | 0 min read

Quickly creating a CSV file

Published on: 2011-07-19 00:24:51 | 0 min read

sudoers: Syntax Checking

Published on: 2011-07-16 02:43:59 | 0 min read

Tar: Don't touch existing files

Published on: 2011-07-14 23:02:06 | 0 min read

Find files created today

Published on: 2011-07-14 02:54:48 | 0 min read

Create/Extract a tar file using contents of a file

Published on: 2011-07-14 21:00:06 | 0 min read

Argument list too long

Published on: 2011-07-13 03:40:22 | 1 min read

Editing big files on systems with little memory

Published on: 2011-07-09 06:08:00 | 0 min read

usermod: Appending to Additional Groups

Published on: 2011-07-08 02:08:00 | 1 min read

oom-killer: If you see this you should reboot

Published on: 2011-07-07 03:21:00 | 1 min read

mdadm: Manually fail a drive

Published on: 2011-07-06 01:20:30 | 2 min read

Do Symlinks use up Inodes?

Published on: 2011-07-01 02:11:00 | 0 min read


Published on: 2011-07-01 23:11:38 | 0 min read

The safest way to deploy a crontab

Published on: 2011-06-28 04:16:00 | 2 min read

sfdisk Goodies

Published on: 2011-06-25 01:24:57 | 0 min read

setfacl: Invalid argument near character

Published on: 2011-06-25 01:24:54 | 0 min read

Checking the number of LWP (threads) in Linux

Published on: 2011-06-25 01:24:50 | 1 min read