Citrix XenServer

How to use an external USB drive as a storage repository in XenServer 5.6

on

I’m building out a quick test lab environment at home tonight using XenServer 5.6 SP2. Unfortunately the server I happened to be using for this is a 1U box with only two 73 GB drives inside. El cheapo Dell. Even striped, I needed just a bit more storage for what I was intending to use it for. Luckily I had a 250 GB external Western Digital USB drive handy. It was formatted as NTFS since I pulled it from a Windows desktop. I figured why not use it as a local storage repository? It’s a temporary test lab after all.

1. Plug the USB drive to your XenServer and turn it on if it’s not on already.

2. Once it finishes booting, enter the Local Command Shell (type your root credentials)

3. Now type:

fdisk –l

this will list all the drives. Typically your USB drive will the best last one. Mine was /dev/sdb1 and under the System column, listed as HPFS/NTFS.

4. Now create a storage repository by typing:

xe sr-create name-label="USB drive" content-type=user type=lvm device-config:device=/dev/sdb1

When it completes, it will give you a UUID (long alpha numeric string). Don’t worry, no need to write it down.

5. Now open up XenCenter, and check the storage available on the XenServer you are working on. You should see one called “USB drive” or whatever you decided to name the SR. The UUID you saw above on the console will also be displayed if you click the storage repository in the resources pane and look under the General section. Click the screenshot below for a bigger version:

About Jason Samuel

Jason Samuel lives in Houston, TX with a primary focus on strategic advisory and architecture of end-user computing, security, enterprise mobility, virtualization, and cloud technologies from Citrix, Microsoft, & VMware. He also has an extensive background in web architecture and networking over his 20+ year career in IT. He is an Author, Speaker, and Local User Group Community Leader. He is certified in several technologies and is 1 of 63 people globally that is a recipient of the prestigious Citrix Technology Professional (CTP) award. He is 1 of 42 people in the world that has been awarded as a VMware EUC Champion and VMware vExpert. He is a featured author on DABCC which provides the latest IT Community News on Cloud, Data Center, Desktop, Mobility, Security, Storage, & Virtualization. In his spare time Jason enjoys writing how-to articles and evangelizing the technologies he works with. Disclaimer: The content and opinions expressed in articles and posts are his own and are by no means associated with his employer.

Recommended for you

1 Comment

  1. Brian

    October 22, 2013 at 9:39 AM

    This worked great on the first try! Thanks much.

Leave a Reply

Your email address will not be published.