Jump to content
Welcome to our new Citrix community!
  • 0

Xenserver LUN Clone UUID Change

Carsten Schulz




i would like to use your desaster recovery option ( realy nice feature ) in Xencenter for restoring vm´s from a storage LUN clone´s for a quick vm restore ( Xenserver 7 ).


We snapshot our complete FC LUN ( Storage Based ).


The Problem is connect the cloned FC LUN to Xencenter.


The UUID of a clone already exist, if you try to insert the clone in Xencenter, because of the same UUID.


Could you implement a option that you changes the clone LUN UUID to a new UUID ??


The best way is:


If you detect that a LUN with same uuid exist then asking to Import as a clone with a new uuid or not. This would be a awesome Feature. Like VMWare LUN.reasigment.


Manuel steps i´m thinking about is:


uuidgen for a new LUN UUID

vgimportclone to Import the clone LUN

metadata Change

lvrename to rename the Lun


Would be nice if you could do that. Then you would help a lot of People around here, because of importing each vm in desaster spends a lot of time.


A work arround for other guys is to have a Restore Xenserver out of the Pool. Attach the LUN and restore and move it to original pool. But it is a bit awesome.


Who could tell me the right manual steps in order to change the LUN UUID ( maybe a example ) I know there is a script  arround but i need it for fibre channel lun.I´m examine it right now.


Best Regards

Link to comment

5 answers to this question

Recommended Posts

  • 0

I want to keep my original LUN with all VM´s on it.


I have a LUN where the VM´s are hosted, let´s call Produktiv LUN with 100 VM´s.

Now i´m taking snapshots hourly or daily from this LUN ( Storage Based )


For a quick restore to get only one or two vm back you could attach a LUN Snapshot Clone to the pool and Restore the vm quickly. But not in the same Pool, because the UUID id already exist. So you have to Change the ID or import it to a different pool.


Import and Export Vm´s takes long time. The disadvantage is that you must check consistency.


The SR is introduced for restore purpose only. After you could deleted it.


You are thinking about restoring the whole LUN. I hope i never have to do this :)

Link to comment
  • 0

Hi guys,

trying the same story and I am failing too.

I was able to determine my $pv_device=/dev/sdn and generate $new_sr_uuid=3fa0f110-a4c1-418e-904b-6d1471b4efeb


[root@citrix-gjgtmwst ~]# vgimportclone --basevgname VG_XenStorage-$new_sr_uuid --import $pv_device
  WARNING: Not using device /dev/sdn for PV M5tyCF-6j3V-OcxY-l1IO-F0lc-KXlP-IFVdjq.
  WARNING: PV M5tyCF-6j3V-OcxY-l1IO-F0lc-KXlP-IFVdjq prefers device /dev/sdg because device is used by LV.
  Device open /dev/sdn 8:208 failed errno 30
  Device open /dev/sdn 8:208 failed errno 30
  Device open /dev/sdn 8:208 failed errno 30
  Device open /dev/sdn 8:208 failed errno 30
  VG info not found after rescan of VG_XenStorage-af4361a0-2117-a713-1e14-2350b044cdcf
  Volume group "VG_XenStorage-af4361a0-2117-a713-1e14-2350b044cdcf" not found
  Cannot process volume group VG_XenStorage-af4361a0-2117-a713-1e14-2350b044cdcf

Any hints on how to proceed - running on version 8 with Freenas Iscssi attached.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...