Showing posts with label ESXi. Show all posts
Showing posts with label ESXi. Show all posts

10/26/11

Inside Apple iTunes, Sharing music on your home network


I've been trying (and still am) to figure out the best way to manage and share a large library of .mp3 files, I never cared much for iTunes but considering I have iPhone/iPads I thought I should at least look into it.

The sharing features of iTunes leave much to be desired but I am going to attempt to configure it so that I have an iTunes server with a library that can be shared throughout my network.

What I decided to do was to install iTunes on a virtual machine running in my VMWare ESXi environment, this way I could add iTunes into the startup folder and it would always be open and available. One of the things I don't like about iTunes is that to share a library iTunes has to be open and if you setup sharing and want to add or edit music or playlists, you have to do it from one computer.

So I wanted to come up with a way where any one of the computers could add or edit music or playlists and it would propagate to all the other iTunes computers in the house.

First on the iTunes server I pointed the media folder to my network share that contains all of my .mp3 files, I also checked the copy files to iTunes Media folder when adding to library checkbox. This way any new music added to the library will be copied into a central location.


Import Music

To import my music I selected File - Add Folder and proceeded to browse to my mapped drive where all my .mp3 files are located. Note this can be a very slow process if you have several GB of music.


Once all the music has been added to the library, I'm ready to look at how iTunes keeps track of the library and what files are important to know about.

iTunes Library Files - Library.itl and Library.xml


The iTunes library is a database iTunes uses to organize your music. Two iTunes library files are created and maintained by iTunes for different purposes. They're both in the iTunes folder.

Location of the iTunes library files:


Mac OS X:
/Users/username/Music/iTunes/iTunes Library.itl
/Users/username/Music/iTunes/iTunes Library.xml


Windows XP
\Documents and Settings\username\My Documents\My Music\iTunes\iTunes Library.itl 
\Documents and Settings\username\My Documents\My Music\iTunes\iTunes Library.xml


Windows Vista
\Users\username\Music\iTunes\iTunes Library.itl 
\Users\username\Music\iTunes\iTunes Library.xml


Windows 7
\Users\username\My Music\iTunes\iTunes Library.itl
\Users\username\My Music\iTunes\iTunes Library.xml



About the iTunes Library.itl file
This file is a database of the songs in your library and the playlists you've created. Some song-specific data is saved in this file. If you delete the file, iTunes creates a new, empty copy when you open the application, but any playlists, song ratings, comments, or other information you created is lost. The iTunes Library file is only used by iTunes, and is the only one backed up by Time Machine on OS X.



About the iTunes Library.xml file
This file contains some (but not all) of the same information stored in the iTunes Library file. The purpose of the iTunes Library.xml file is to make your music and playlists available to other applications on your computer. In Mac OS X other iLife applications (like iPhoto, iDVD, and iMovie) use this file to make it easier for you to add music from your iTunes library to your projects.




The point of this tutorial is to let several computers share the same iTunes library so after all of my music has been successfully added to my iTunes server I need to share the library files on the server. On the iTunes server, I navigated to the folder containing the iTunes library metadata. By default (see locations above) you can typically find this in \Users\username\My Music\iTunes. I see a file called iTunes Library.itl so I know I'm in the right location. I need to share this folder on the network, so I right-click the iTunes folder, select Sharing and security and select Share. Now I add the users that I would like to give share access and select the share button.



Grant permissions to all user accounts that will need access to the iTunes library



Next I connected all of my networked computers to the iTunes share, I mapped a drive on each. To do this, access a networked Windows computer, right-click on My Computer, and select "Map network drive" Choose a drive letter, then I browse to the share I created on the iTunes server. When I'm done, I click Finish. 






Now on all of my networked computers, I launch iTunes while holding the Shift key. This let me change the default iTunes library. I Clicked on Choose library, then navigated to the mapped drive (W:) that I just created. Select the iTunes Library.itl file and I'm done.


This completes the shared iTunes library, I'll continue to test how this works and if I find any improvements I'll update the post.


9/30/11

VMWare ESXi Lab Improvements, separate storage network with Jumbo Frames enabled

I recently decided to upgrade my VSphere 5 Lab and move my storage off to a separate network. The following diagram describes my new topology.


Before doing this I had everything on the same network, by isolating all of the storage traffic I was able to enable Jumbo Frames and bring this environment a bit closer to VMWares best practices for NFS storage.

To create the new network first I changed the Iomega IX4 200D's network settings,


I put each Gigabit network card on a seperate network, the 192.x.x.x network is for managing the ESXi environment and the 10.x.x.x network is the storage network. Next I enabled Jumbo Frames on the NIC and set the size to 9000.

Following this change I created a new VMKernel on each ESXi host using the VSphere Client, I added 2 physical network cards to each VMKernel. 



I made sure to enable Jumbo Frames on both the new vSwitch that is created for the VMKernel and the VMKernel itself, I set them both to 9000 to match the Iomega settings.


I enabled NIC Teaming on the two network cards


Note: Although NIC Teaming will not increase speed for a single NFS Datastore, it will help when there are multiple NFS Datastores, VMWare recommends using multiple NFS Datastores.


Once the network and NAS settings are complete the NFS datastores can be created normally.









9/8/11

GATEWAY DX4200-09 VMWare VSphere Whitebox


I built a VMware VSphere environment using 2 Gateway DX4200 machines, the machines were relatively inexpensive in 2009 and provide enough horsepower for my home lab. First thing I upgraded was the memory in each machine from 4GB to 8GB, then I disabled the on-board NICS and purchased Intel Pro 1000 Dual Port NICS. I purchased the 64 bit server NICS and found that you can use them on your 32bit non server motherboards, this is great because the server cards are far less expensive.

I recently upgraded the processors from the stock 1.8 GB Phenoms to 3.2 GHZ Phenom II's, found the procs on sale at Microcenter for about $95 a piece. I was worried that the procs would not work because the motherboards have socket AM+ and the new procs are AM3. The processors work fine but I do get a message from the BIOS stating AMD unknown processor and so ESXi reports the same thing. Unfortunately Foxconn never released any newer updates for the BIOS so I will always see this message but everything works perfectly.

The Gateway offers no on-board RAID controller which is good because most non-server motherboards on-board RAID controllers will not work with VMWare ESX. I used 2 Kingston 4GB USB drives to install ESXi 5.0 on and have no hard drives in my Gateway machines, this provides a very low power solution when combined with my IOMEGA IX4-200D NAS storage.

The machines currently host about 10 Virtual Machines, most running Windows Server 2008R2, I host a couple of websites in this environment but for the most part pretty low traffic. Performance is acceptable for me, I do get the occasional stutter or slowness but for the most part it runs great, I've never taxed the hosts so much that I was seeing performance degradation. 

IOMEGA IX4-200D Thoughts

I've owned the Iomega IX4 200D for almost 2 years now, since this is a core piece of my home infrastructure, I felt some feedback would be appropriate.

The NAS is not designed for speed, in most reviews I've read it's usually ranked near the bottom of the pack. That said I still think it's a great device with a ton of functionality, the unit ships with Seagate Barracuda hard drives that spin at 5900 RPM, they are the low power edition of the product line. I use mine (I actually own 2) for a VMWare ESXi 5.0 environment that I run, my environment consists of 2 - 3.2 GHZ Quad Core Phenom II white boxes each with 8GB of RAM and 5 Intel Pro 1000 NIC cards. The NAS comes with 2 Gigabit NICS that can be teamed for performance or used individually for redundancy, I found this to be pretty rare for most home NAS devices on the market.

The Iomega is certified with VMWare to run VSphere and supports both iSCSI and NFS. I purchased the unit with 4 500GB Seagate Barracudas and quickly ordered 4 2TB Barracudas to replace the original drives. Switching out the drives is actually not supported by Iomega and will void the warranty however, I kept the 500 GB drives so if I ever have to ship it back, I can put the original drives back in.

The operating system of the NAS is actually striped across all disks in the device so you must be careful to only switch one drive at a time until the array is completely rebuilt. I have had a drive fail once and it was very easy to install a new drive and let it rebuild the array, on an 8TB RAID 5 array about half full it takes about 24 hours to rebuild but the nice thing is that the array is still accessible during the reconstruction.

That's all I can think of right now, I'll keep adding to this post as I have time...

8/28/11

Install ESXi 5 on a USB drive



To install ESXi on a USB drive simply plug the drive into your host, put the installation media (CD) in the drive and reboot the server. The install will start and you can select the USB drive as the installation path, the installer will format and partition the drive for you.

I used a Kingston 4GB drive because I read DELL was actually shipping these with their pre-configured ESX servers, no issues with these USB drives. I was able to free up 2 640GB hard drives from my ESX hosts that were only being used to hold the small ESXi footprint.

You will have to modify your BIOS setting (Boot Order) to ensure that USB - HDD is your first boot device, I changed my Gigabyte motherboard setting to USB-HDD, CDROM, Harddrive and it works great.

Apparently you don't even need any drives in your ESX host(s) now with ESXi 5 you can install Auto Deploy on your VCenter machine and pxe boot your hosts but I like the idea of having these portable USB drives for my installation.

I'm still curious when ESXi actually commits configuration changes to the USB device because I have tried switching the USB drive from one host to another. The issue I came across was switching the USB drive, booting up a host, changing the configuration options and then shutting down. When I tried booting up again it seemed that none of the new configuration options were persisted to the USB drive.

I'll do more testing to try and resolve this but so far I'm real happy with these devices. I have noticed that after ESXi installs on the device, my Windows 7 box will not recognize the drive when I plug it in, I just wanted to format and start over but no luck. What worked for me was plugging the device into my Synology DS1010 NAS and choosing external devices and format. I noticed that there were at least three separate partitions created by ESXi.