Before Host Profiles there was vicfg-cfgbackup.pl

This last weekend I was reminded of a RCLI command that creates a backup of your ESXi Host configuration.  A client had an ESXi host where the USB drive failed.  The system didn’t entirely crash, it pinged so HA didn’t kick-in however hostd and vpxa weren’t responding so management from vCenter was impossible. Performing a reboot of the host proved it was a USB failure when it failed to boot.

So, HA kicked in finally when the host was powered off - however the remaining hosts in their cluster did not have adequate resources to power everything back on.  We needed to get this failed ESX host back online and quick!

Brought in new USB stick with fresh ESXi 4.0 installed, plugged in and powered up.  In the TUI configured the Management Port IP address/gateway/DNS, etc.    But now what, all of the (NFS) Datastores, vSwitch configuration and advanced settings were toast…and they didn’t have Enterprise Plus.

Say Hello to vicfg-cfgbackup.pl — a RCLI command which could be found in the vMA.  This utility will allow you to create a backup and restore a full ESXi configuration.  Luckily we had this (backup) command running on a nightly basis so we knew the configuration was complete.  A simply command and the host was online.

Seeing that ESX is going to be phased out, this RCLI command is a valid alternative for those ESXi users that do not have Enterprise Plus licensing.

The commands vicfg-cfgbackup.pl (esxcfg-cfgbackup.pl) allow you to backup and restore the configuration of your ESXi host.

To backup the host you would run the command.

vicfg-cfgbackup.pl –server <server_name> -s <backup_file_name>

To restore your backup configuration to your host you would run. This will cause the host to reboot once the process is complete. NOTE: The host must be in Maintenance Mode for this to work. The backup configuration must also match the patch level of the ESXi install. You can add a -f to force if needed.

vicfg-cfgbackup.pl –server <server_name> -l <backup_file_name>

Posted under Backup & Recovery, ESXi 3.5 Tips, vSphere

This post was written by Rick Scherer on October 12, 2009

Tags: , , , , ,

ESXi Free Edition & The RCLI

Well a few days back there were a lot of posts in regards to the Free Edition of ESXi and how in U3 the RCLI is now writable.  This unfortunately was a bug, per Duncan over at Yellow-Bricks this was done unintentionally by the ESXi programmers attempting to resolve an API-related bug.   So, enjoy the writable RCLI while it last Free ESXi users, your next update will most likely remove the feature.

This only applies to customers who downloaded the free version of ESXi. VirtualCenter and VI (Foundation, Standard, Enterprise) customers are not affected.

For those of you that do not know what the RCLI is, here is an except from VMware;

VMware Infrastructure Remote CLI
The VMware Infrastructure Remote CLI provides a command-line interface for datacenter management from a remote server.

Posted under ESXi 3.5 Tips, VMware

This post was written by Rick Scherer on December 15, 2008

Tags: , , , ,

ESX Reference Cards

A customer asked if I had a reference card with common ESX commands (RCLI, etc) so I sent him three cards, which I’m posting here now for you.

First is the vmreference VI3 card by Forbes Guthrie over at www.vmreference.com

Second and third are VI3 Command References and Linux Command References from the VMware Deploy, Secure & Analyze class.

Enjoy!

Posted under ESX 3.5 Tips, ESXi 3.5 Tips, VMware

This post was written by Rick Scherer on December 12, 2008

Tags: , , , , , ,