How to restart management services for VMware ESX / ESXi via console or cmdline

Let’s face it, there are times when our ESX / ESXi hosts simply stop responding to vCenter for one reason or another, which requires a management agent restart. But how do you do that you ask? Well I’m going to tell you. Please note that you’ll need the root password for the host and need to be logged in.

read more

General error: 2006 MySQL server has gone away

I recently ran into an issue while updating my copy of Owncloud from version 6.0.1 to 6.0.3 and while the error occured while this specific update the error is common to MySQL so I figured why not share the love.

So in a nutshell when I tried to update the application I received the following error;

read more

Enabling slow queries for Mysql in Linux

Handy tip for enabling the slow query log for MySQL for Centos / Redhat linux.

Stop MySQL by typing either “service mysqld stop” or “/etc/init.d/mysqld stop” Edit the my.cnf file, usually found at “/etc/my.cnf” Under [mysqld] add the following line; 
log-slow-queries=/var/lib/mysql/slow.log
  • Save the updated my.cnf file.
  • Do not start MySQL yet. We need to add the slow log file and location. To do this tpye the following into the command prompt; 
    touch /var/lib/mysql/slow.log
    chmod 660 /var/lib/mysql/slow.log
    chown mysql:mysql /var/lib/mysql/slow.log
  • With the slow log file and location created with the proper permissions, now you can restart MySQL with “service mysqld start” or “/etc/init.d/mysqld start”
  • After some time review the log you created at “/var/lib/mysql/slow.log” using a text editor (Nano, Pico,Vi / VIM).
  • There you go! Hopefully this helps you drill down if you’re noticing slow performance due to MySQL.

    read more

    How to use Crashplan to backup mapped drives in Windows

    Having changing my environment I found my self moving from iSCSI to NFS and of course since NFS is a mapped drive, I found that Crashplan doesn’t support mapped drives out of the box. To get around this I had to implement the fix below. This was something I found on the Crashplan website and wasn’t easily accessible via a google search, so I’m re-posting it for anyone else who finds themselves in the same situation.

    read more

    Useful list PowerCLI one liners

    Just a handy list of useful VMware PowerCLI commands. Keep in mind that many of these are examples and can be tweaked / adjusted as needed. This is just for your benefit and mine :)

    Basic Commands

    Connect-viserver – This will connect you to the ESX / ESXi server. An example would be Connect-viserver 192.168.1.1 -user myname -password mypassword

    read more