티스토리 뷰
Xenserver Metadata Backup 하기
방법:
12월 5일 VM VDI 삭제 장애 발생
미리 메타데이터 백업을 해놓았다면 살렸을 가능서도 있음
생각했으면 바로 실행을 해야 함.
- Un-map the Logical Units (LUNs) on the switch from the host during the installation.
- Disconnect the Fiber cables during the installation.
- Ensure you are mapping the LUNs to the correct host.
- If virtual machines are currently running, back up all the virtual machine data because they might not boot up or data might not be retrievable after making a recovery attempt.
- Use your existing backup solution to back up the virtual machines as a whole to try and recover data if needed.
- Open the command line in the XenServer host.
- Run the following command:
xe sr-list name-label=<Name of your SR>. - Make note of your UUID.
- Scan your SR with the following command and see if you get an error like the screen shot below:
xe sr-scan=<UUID of your SR> - Change to directory /etc/lvm/backup with the command:
cd /etc/lvm/backup. - Identify the file which has the UUID of your SR from the previous step.
- Open the file and identify the physical volume for the logical volume using the cat <filename> | more command.
- Identify your physical volume.
- Use the command fdisk –l and identify what disk the SR should be located.
- Run the following command:
pvdisplay /dev/<device where your think the SR should be> - The UUID of the physical volume should be the same as the UUID for the physical volume displayed in the file from the previous step.
- If the physical volume UUIDs are not the same then the physical volume has changed; run the procedure below to recover the logical volume on the new physical volume.
- Back up the file VG_XenStorage-<UUID of your SR> in /etc/lvm/backup directory with the following command:
cp /etc/lvm/backup/<filename> /etc/lvm/backup/orig.<filename> - Use a text editor like VI to modify the file with a new PV UUID that is presented in the format identified from previous step.
- Restore the LVM using the followings commands:
Back up the current LVM:
# cd /etc
# cp –dpR lvm lvm-<YEAR><MONTH><DAY>-<HOUR><MINUTE> (Actual Date)
# vgcfgbackup
# cd /etc/backup
Test Recovery:
# vgcfgrestore VG_XenStorage-<UUID of the volume to be restored> --test –f VG_XenStorage-<UUID of the volume to be restored>
Recover the Volume:
# vgcfgrestore VG_XenStorage-<UUID of the volume to be restored> –f VG_XenStorage-<UUID of the volume to be restored>
Scan the SR:
#xe sr-scan uuid=<UUID of the SR to be restored> - Attempt to plug your Physical Block Device (PBD) on your SR.
XenServer Virtual Machine Storage Recovery
Document ID: CTX128097 / Created On: 2011. 3. 28 / Updated On: 2012. 3. 10
Average Rating:
(1 ratings)
View products this document applies to
Symptoms
You install XenServer on a host and cannot start any virtual machines after the XenServer reboots.
This article provides background and a simple workaround to avoid or resolve this issue.
IMPORTANT!! This procedure should be fully tested and understood in a development environment prior to implementing it on a production environment. Restoring a volume on a working volume can result in virtual machines not booting or data loss.
Background
During the XenServer installation, if you present a volume through the Host Bus Adapter (HBA) to the XenServer, you are given the selection during the installation to select the disks to use for virtual machine storage. If you select the secondary disk, which might be used already by other hosts in a pool, it results in a complete removal of the existing Storage Repository (SR) with virtual machines.
Installing XenServer on a host with attached storage through an HBA is not recommended. If your host uses an HBA, you can install XenServer with the HBA installed, but the following recommendations are made:
Workaround
If you currently have virtual machines running in a shared volume, the change in the logical or physical volume is not recognized until you scan the volume or reboot the XenServer.
Identify your SR’s Universally Unique Identifier (UUID)
Identify your logical volume
Note: This screen shot show the output as XSLocalEXT; it is normally VG_XenStorage-<UUID>.
Make note of the disk (/dev/sda) and partition where your SR is located (/dev/sda4).
Recovery
Once you have identified that your physical volume is different than the one noted in the logical volume file, you must recover the logical volume on the physical volume using the following steps.
More Information
Refer to the procedure in CTX117508 – How to Recover a Deleted XenServer Virtual Machine as a guide for this recovery process.
This document applies to:
'IS' 카테고리의 다른 글
2013-03-06 junos pulse SSL VPN - IPhone 호환문제 (1) | 2013.03.06 |
---|---|
2013-01-11 Juniper SSL VPN Access Management-Realm, Role, Policy, Rules (0) | 2013.01.12 |
스토리지 IOPS 실측 (0) | 2012.03.27 |
[XenDesktop] DesktopStudio에서 작업 중 손상된 Catalog 삭제 (0) | 2012.01.31 |
Xenserver Pool Shutdown 가이드 (0) | 2012.01.17 |
- Total
- Today
- Yesterday
- NMS
- IOPS
- IDS
- 삶의 진리
- RAID
- Security Onion
- nagios
- 가상화
- 욕망
- Virtualization
- 자식
- 상속
- 도덕
- SAS
- 가정
- 스토리지
- 덕의 기술
- SSD
- 독서
- SATA
- 일기
- Xen
- 욕구불만
- opsview
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | ||||
4 | 5 | 6 | 7 | 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 | 22 | 23 | 24 |
25 | 26 | 27 | 28 | 29 | 30 | 31 |