<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>cyborgworkshop.org &#187; VMWare</title>
	<atom:link href="http://cyborgworkshop.org/category/vmware/feed/" rel="self" type="application/rss+xml" />
	<link>http://cyborgworkshop.org</link>
	<description>Blurring the line</description>
	<lastBuildDate>Wed, 22 Feb 2012 14:31:06 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>My ESXi Whitebox</title>
		<link>http://cyborgworkshop.org/2011/01/16/my-esxi-whitebox/</link>
		<comments>http://cyborgworkshop.org/2011/01/16/my-esxi-whitebox/#comments</comments>
		<pubDate>Mon, 17 Jan 2011 03:38:18 +0000</pubDate>
		<dc:creator>jason</dc:creator>
				<category><![CDATA[VMWare]]></category>

		<guid isPermaLink="false">http://cyborgworkshop.org/?p=690</guid>
		<description><![CDATA[Now that I have the LAN almost 100% virtual, I thought I would put a little post together on my ESXi 4.1 whitebox. Most of you won&#8217;t care, but ESXi whitebox info is kinda hard to come by, so maybe someone on google will find this useful someday. First, the VM Load. I&#8217;m currently running [...]]]></description>
			<content:encoded><![CDATA[<p>Now that I have the LAN almost 100% virtual, I thought I would put a little post together on my ESXi 4.1 whitebox. Most of you won&#8217;t care, but ESXi whitebox info is kinda hard to come by, so maybe someone on google will find this useful someday.  First, the VM Load. I&#8217;m currently running 7 VMs.</p>
<p>Boomer      ubuntu 10.04 utility box that lives in my DMZ<br />
Hybrid                pfSense firewall with 4 physical NICs and 1 virtual attached<br />
GLaDOS         OpenFiler NAS with 3 2TB drives setup for raw sata access<br />
Vault                   ubuntu 10.10 server with 3 1TB drives setup for raw sata access for backups of GLaDOS<br />
Serenity          XP VM that I use when I&#8217;m oncall<br />
Sleven             Windows 7 that I use for nefarious deeds<br />
DC1                      Windows 2008 Server setup as a DC to experiment with.</p>
<p>The ESXi server itself (Jane, Ender fan anyone?) is a quad core Xeon X3220 with 16 gigs of DDR3 RAM on a gigabyte motherboard that has an ICH10 chipset allowing for local SATA storage. I&#8217;ve had to add in an additional SIL3114 SATA 1 PCI controller to support the additional drives that are attached to the vault. SATA 1 drive performance hasn&#8217;t really been an issue since backups are mostly occurring over a WAN link anyhow.  I was given an Intel quad port gigabit PCIEx4 adapter, so that&#8217;s my primary NIC and then I have a few old Intel dual 10/100 cards installed just in case. The server itself boots off of a USB thumbdrive and everything is stored in a 4U case with 7 Kingwin trayless racks holding the drives in place.  Here are the actual parts I&#8217;m using</p>
<p>GIGABYTE GA-P43T-ES3G motherboard<br />
Intel X3220 Quad core Xeon CPU<br />
GSkill RipJaws DDR3 1333 4GB DIMMS x 4 (16GB)<br />
Seagate 2TB SATA drive x3<br />
Seagate 1TB SATA Drive x3<br />
Vantec 6 port SATA II 150 PCI SATA card<br />
Intel EXPI9404PTG2L20 quad port ethernet adapter (freebie)<br />
Intel Dual port 10/100 ethernet adapter (junk parts store)<br />
Kingwin SATA hotswap rack x7<br />
generic 4U 7 5.25 bay rack mount enclosure</p>
<p>The whole system was put together piece by piece over time, but if I had to buy it all again, I would anticipate around $900 if you had no parts at all.  My CPU load is almost always below 25% and RAM is around 50%. The amazing part though is that this setup has replaced at least 7 physical machines and very likely more around 10 when you figure in the &#8220;I want to try out solaris again&#8221; whims.  I literally have a 7 foot rack in my basement that has a single server in it. Looks kinda sad really. I have only 1 upgrade planned for the year and that is to replace the USB boot drive with an SSD that I have, but otherwise this server is setup to carry my needs for a good long time. </p>
]]></content:encoded>
			<wfw:commentRss>http://cyborgworkshop.org/2011/01/16/my-esxi-whitebox/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Install ESXi 4.1 onto a thumbdrive</title>
		<link>http://cyborgworkshop.org/2011/01/13/install-esxi-4-1-onto-a-thumbdrive/</link>
		<comments>http://cyborgworkshop.org/2011/01/13/install-esxi-4-1-onto-a-thumbdrive/#comments</comments>
		<pubDate>Thu, 13 Jan 2011 20:53:08 +0000</pubDate>
		<dc:creator>jason</dc:creator>
				<category><![CDATA[VMWare]]></category>

		<guid isPermaLink="false">http://cyborgworkshop.org/?p=685</guid>
		<description><![CDATA[This is the easiest esxi thumb install yet. Just download the iso file, grab a thumbdrive and dd a single file onto the drive. Assuming that your thumbdrive is /dev/sdd, just run the following. mount -t iso9660 -o loop VMware-VMvisor-Installer-4.1.0-260247.x86_64.iso /mnt/cdrom/ bzip2 -d /mnt/cdrom/imagedd.bz2 -c &#124; dd of=/dev/sdd Done, boot it up!]]></description>
			<content:encoded><![CDATA[<p>This is the easiest esxi thumb install yet. Just download the iso file, grab a thumbdrive and dd a single file onto the drive.  Assuming that your thumbdrive is /dev/sdd, just run the following.<br />
<code><br />
mount -t iso9660 -o loop VMware-VMvisor-Installer-4.1.0-260247.x86_64.iso /mnt/cdrom/<br />
bzip2 -d /mnt/cdrom/imagedd.bz2 -c | dd of=/dev/sdd<br />
</code></p>
<p>Done,  boot it up!</p>
]]></content:encoded>
			<wfw:commentRss>http://cyborgworkshop.org/2011/01/13/install-esxi-4-1-onto-a-thumbdrive/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Enabling raw SATA access in ESXi free</title>
		<link>http://cyborgworkshop.org/2011/01/08/enabling-raw-sata-access-in-esxi-free/</link>
		<comments>http://cyborgworkshop.org/2011/01/08/enabling-raw-sata-access-in-esxi-free/#comments</comments>
		<pubDate>Sun, 09 Jan 2011 02:56:55 +0000</pubDate>
		<dc:creator>jason</dc:creator>
				<category><![CDATA[VMWare]]></category>

		<guid isPermaLink="false">http://cyborgworkshop.org/?p=671</guid>
		<description><![CDATA[I have recently moved us from having two boxes, the ESXi server and a file server, down to just the ESXi host. This is a great thing because what used to be 14 servers in a rack in the basement, all with howling fans and clunking harddrives, has been reduced to a single quad core [...]]]></description>
			<content:encoded><![CDATA[<p>I have recently moved us from having two boxes, the ESXi server and a file server, down to just the ESXi host. This is a great thing because what used to be 14 servers in a rack in the basement, all with howling fans and clunking harddrives, has been reduced to a single quad core chassis sitting lonely in a 7 foot rack. Where I&#8217;m not as comfortable though is with running a vm as my file server and having all of my data tied up in vmdks without a solid, enterprise storage array behind it.  If something goes wrong I want the peace of mind of being able to rip the drives out of my server, pop them into another box and be back on my feet in a matter of minutes. I&#8217;m not certain I can do that if I have all of my data spread across 9 or 10 vmdk files on 3 drives, but I know I can pop a linux based, 3 disk RAID-5 set into any old linux machine and be online. My solution is to create a linux file server in vmware, but give it raw access to some attached SATA drives so the drives end up looking and working just like they had come out of a physical machine. No vmware vmdk or other info anywhere in sight. VMWare will allow you to setup raw disk maps to storage that is located  on a SAN using the VI client, but not to local SATA storage. Fortunately  it&#8217;s a very simple process to hack and works like a charm.</p>
<p>You&#8217;ll need ssh access to your esxi host, a vmfs that you are not doing raw access to in order to store a mapping file and drives to map.</p>
<p>First, ssh into your esxi server and run fdisk -l to get a listing of all of the drives that you esxi host sees. The format will look something like this</p>
<p>~ # fdisk -l</p>
<p>Disk /dev/disks/t10.ATA_____ST32000542AS________________________________________5XW205BS: 2000.3 GB, 2000398934016 bytes<br />
255 heads, 63 sectors/track, 243201 cylinders<br />
Units = cylinders of 16065 * 512 = 8225280 bytes</p>
<p>The key being &#8220;/disks/t10.ATA_____ST32000542AS________________________________________5XW205BS&#8221; . That is how ESXi uniquely identifies your drive. I believe it breaks down to something along the lines of /disks/controler.interface_Drive-model_Drive-serial-number, but I&#8217;m mostly making that up as I go.</p>
<p>Now that we have the drive identified, we need to take that information and create a drive map file.  cd over to a datastore that is NOT a raw mapping (i.e. I have a 500 gig drive in my box that hosts most of my vms called SATA-500 in /vmfs/volumes/SATA-500, so I would cd into there) and run the following, replacing with your own information as needed. Note that I use buslogic adapters on my VMs, if you use lsilogic, replace buslogic with lsilogic.  The name &#8220;RAW-2TB.vmdk&#8221; is free form, but I would try to make it descriptive and it must be a .vmdk extension.</p>
<p>vmkfstools -z /vmfs/devices/disks/t10.ATA_____ST32000542AS________________________________________5XW205BS RAW-2TB.vmdk -a buslogic</p>
<p>Two files get created after you run that command.  The RAW-2TB.vmdk file that we specified and a RAW-2TB-rdmp.vmdk  .  You can cat the RAW-2TB.vmdk file to get a look at how vmware saw your drive and what kind of information it&#8217;s passing back to the hypervisor on how to use it, but I would not mess with that rdmp file. Think of it as the actual disk, doing a cat on that file is going to give you nothing but a messy terminal if the console will allow you to do it at all.</p>
<p>At this point, switch into your vcenter client and go to the VM that you want to assign these drives to. Go into Edit Settings, Add a Hard Disk, Use an Existing Virtual Disk and browse to the RAW-2TB.vmdk file that was just created.  When you select that file, ESXi reads all of the information in it and grants that VM access to that drive without any additional vmware specific info ever getting written to the disk. You can pop that disk into a physical machine and it would read it just as if it came out of a physical machine.</p>
]]></content:encoded>
			<wfw:commentRss>http://cyborgworkshop.org/2011/01/08/enabling-raw-sata-access-in-esxi-free/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Enabling SNMP on an ESXi 4 free edition</title>
		<link>http://cyborgworkshop.org/2010/08/01/enabling-snmp-on-an-esxi-4-free-edition/</link>
		<comments>http://cyborgworkshop.org/2010/08/01/enabling-snmp-on-an-esxi-4-free-edition/#comments</comments>
		<pubDate>Sun, 01 Aug 2010 18:05:05 +0000</pubDate>
		<dc:creator>jason</dc:creator>
				<category><![CDATA[VMWare]]></category>

		<guid isPermaLink="false">http://cyborgworkshop.org/?p=633</guid>
		<description><![CDATA[ESXi doesn&#8217;t include a lot of the management functions that the licensed product carries (see my previous post on doing backups in ESXi) but most of those functions are already installed, just disabled.   Here is how to enable SNMP queries and traps on an ESXi server. Enable ssh on your server I&#8217;m assuming you have [...]]]></description>
			<content:encoded><![CDATA[<p>ESXi doesn&#8217;t include a lot of the management functions that the licensed product carries (see my previous post on doing <a href="http://cyborgworkshop.org/2010/07/31/backing-up-an-esxi-4-server/">backups in ESXi</a>) but most of those functions are already installed, just disabled.   Here is how to enable SNMP queries and traps on an ESXi server.</p>
<ol>
<li><a href="http://www.vm-help.com/esx40i/ESXi_enable_SSH.php">Enable ssh</a> on your server</li>
<li>I&#8217;m assuming you have already licensed your server, we&#8217;re going to need to back that out so ssh to the server as root</li>
<li>run the following commands</li>
<p><code>mv /etc/vmware/vmware.lic /etc/vmware/vmware.lic.orig<br />
mv /etc/vmware/license.cfg /etc/vmware/license.cfg.orig<br />
services.sh restart<br />
</code></p>
<li>That will temporarily put you back into an eval license, you will be disconnected from your vsphere client while the services restart</li>
<li>Now you need access to the ESX remote command line. You can do that by either downloading and installing the <a href="http://www.vmware.com/downloads/eula.do">appliance</a> or you can install it locally on your machine.</li>
<li>Configure SNMP for your environment. -c is the snmp community you want to set for queries and -t is the trap destination</li>
<p><code>vicfg-snmp.pl –server 192.168.1.1 -c public -t 192.168.1.2@162/public</code></p>
<li>enable snmp</li>
<p><code>vicfg-snmp.pl –server 192.168.1.1 -E</code></p>
<li>Test your new snmp config</li>
<p><code>vicfg-snmp –server 192.168.1.1 -T </code></p>
<li> and lastly, download the <a href="http://downloads.vmware.com/d/details/esx40_snmp_mib_dt/ZHcqYmQqaCViZHdlZQ==">snmp MIBs</a> for your management platform</li>
<li>Now move your license keys back</li>
<p>         <code>mv /etc/vmware/vmware.lic.orig /etc/vmware/vmware.lic<br />
mv /etc/vmware/license.cfg.orig /etc/vmware/license.cfg<br />
services.sh restart
</ol>
<p>And that's it, you have snmp queries and traps on your ESXi server now. </p>
]]></content:encoded>
			<wfw:commentRss>http://cyborgworkshop.org/2010/08/01/enabling-snmp-on-an-esxi-4-free-edition/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Backing up an ESXi 4 server</title>
		<link>http://cyborgworkshop.org/2010/07/31/backing-up-an-esxi-4-server/</link>
		<comments>http://cyborgworkshop.org/2010/07/31/backing-up-an-esxi-4-server/#comments</comments>
		<pubDate>Sat, 31 Jul 2010 15:21:17 +0000</pubDate>
		<dc:creator>jason</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[VMWare]]></category>

		<guid isPermaLink="false">http://cyborgworkshop.org/?p=630</guid>
		<description><![CDATA[ESXi is one of my favorite products on the market and is really excellent for home use. It&#8217;s missing out on a few enterprise features like SNMP (I&#8217;ll show you how to get around that in a later post) but is otherwise very complete. I had previously been using a separate storage server using iscsi [...]]]></description>
			<content:encoded><![CDATA[<p>ESXi is one of my favorite products on the market and is really excellent for home use.  It&#8217;s missing out on a few enterprise features like SNMP (I&#8217;ll show you how to get around that in a later post) but is otherwise very complete.  I had previously been using a separate storage server using iscsi for my vmfs, but the dependency of the two boxes kept me from shutting down either server as needed. So, I converted everything back to local SATA storage (another post) and went on a hunt for how to backup my VMDKs.  My iSCSI SAN had dual power supplies, 2 hot standby drives and I could do snapshot based backups whenever I wanted. My ESXi server has two SATA drives, one power supply and no easy way to backup. Enter <a href="http://communities.vmware.com/docs/DOC-8760">GhettoVCB</a>. <a href="http://communities.vmware.com/docs/DOC-8760">GhettoVCB</a> is a brilliant little shell script that runs on the ESXi server and performs backups of your vms using snapshots that can be stored on local, attached or network storage.  Getting <a href="http://communities.vmware.com/docs/DOC-8760">GhettoVCB</a> up and running isn&#8217;t difficult at all, you just need to make sure you have a few things in place first.</p>
<ul>
<li>A place to store the backups (NFS, iSCSI, Local storage and potentially DAS)</li>
<li>Decide how many backups you want to have available</li>
<li>Decide How you want to store the files (thin, thick, etc) This consideration will impact how many backups you have available because of the different space requirements.</li>
<li>And lastly when you want your backups to run.</li>
</ul>
<p>I&#8217;ve decided to take thin copies of my vmdks at midnight every night and store them on an NFS share with 5 backups available before the older ones get replaced.  I&#8217;m not going to try to replicate the excellent instructions that already exist for <a href="http://communities.vmware.com/docs/DOC-8760">GhettoVCB</a>,  but here is how I did it.</p>
<ol>
<li>Create an NFS mount on my <a href="https://help.ubuntu.com/community/SettingUpNFSHowTo">NFS server</a> with the following options</li>
<p><code>/mnt/raid5/VMWare       10.0.0.0/24(rw,async,all_squash,anonuid=99,anongid=99)</code></p>
<li>Mount the NFS share in vSphere and call it Backups</li>
<li><a href="http://www.vm-help.com/esx40i/ESXi_enable_SSH.php">enable ssh </a>on your ESXi server</li>
<li>scp ghettovcb.tar.gz to your ESXi server</li>
<li>untar ghettovcb.tar.gz to /usr/ghettovcb</li>
<li>edit ghettoVCB.sh and change VM_BACKUP_VOLUME to be VM_BACKUP_VOLUME=/vmfs/volumes/Backups</li>
<li>edit DISK_BACKUP_FORMAT to be DISK_BACKUP_FORMAT=thin</li>
<li>edit VM_BACKUP_ROTATION_COUNT to VM_BACKUP_ROTATION_COUNT=5</li>
<li>edit EMAIL_LOG to EMAIL_LOG=0  unless you want to setup logs to be emailed to you.</li>
<li>edit cron by running this command</li>
<p><code>echo "0 6 * * * /usr/ghettoVCB/ghettoVCB.sh -a &gt; /var/log/ghettoVCB-backup-$(date +\%s).log" &gt;&gt; /var/spool/cron/crontabs/root<br />
kill $(cat /var/run/crond.pid)<br />
busybox crond </code></p>
<li>My cron is set for 6am because my clock is set to UTC, to 6am is midnight for me</li>
<li>Wait until midnight for the cron to run or run it by hand yourself.</li>
</ol>
<p>Logs will be stored in /var/log/  .  I&#8217;m backing up 8 VMs in roughly an hour using about 60GB of space (thin provisioned) and have tested restores successfully. Good luck and let me know if you have any issues!</p>
]]></content:encoded>
			<wfw:commentRss>http://cyborgworkshop.org/2010/07/31/backing-up-an-esxi-4-server/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

