Posts Tagged ‘Linux’

CentOS: clvmd startup timed out

I received the following error, on CentOS 6.5, when configuring a High Availability cluster. This also cause the computer to freeze on the os boot. clvmd startup timed out The fix was found here and involved an edit of /etc/lvm/lvm.conf. This required a minor change to the library_dir line as the location of these libraries […]

Planning the cluster configuration

This post is part of a series that will deal with setting up a MySQL shared storage cluster using VirtualBox & FreeNAS. In this post we specify some brief details of the cluster configuration. Please note this post will be updated in the near future.  

Monitor /tmp usage on Linux

Just a quick post to show how to monitor usage of /tmp on a Linux system. Setup a cron job as follows… ?View Code BASH* * * * * df -h | grep "/tmp" >> /tmp/tmp.log This job will run every one minute logging details of /tmp usage to a file called tmp.log. To report […]

Linux Tip: Output error messages to syslog from cron

I wanted to find a way of running a script in cron and output the exit code, and error message, to syslog if it failed. Here’s what I came up with… ?View Code BASHoutput=`/usr/bin/scripts/ 2>&1`; code=$?; if [ "$code" -ne 0 ]; then err_msg=`echo "$output" | tail -1`; logger -t "CRONERROR" "Exit Code = $code: […]

Check disk space with Bash

Now I’m working mainly with Linux and MySQL I’ve had to learn how to accomplish basic tasks in entirely new ways. As a DBA I like to keep an eye on disk space. I wanted something like my Check disk space with Powershell script, but this only works with Windows, so naturally I turned to […]