Do I once again training with XenServer on small hardware ? keep Mostly yes the disk is too small - 250 GB, but the rich must be, and SAS hard drives. Beautiful, fast, but indeed.
Windows 7 will, according to template already have 24 GB on its own, two provisioning servers to VMs, two DDCs based on 2003s, a DC per participant and at least one large virtual hard disk to accommodate the vdisk for PVS. Set up by XenServer Standard storage repository on LVM base can quickly come to its limits, allocated mainly because it does not use thin-provisioning (which is entirely possible) but for a 24 GB hard drive for Windows 7 VM full 24 GB.
remedy here, the Citrix KB Article CTX116324 - How To Change the Default Storage Repository to File-based VHD-on-EXT3
problem here is: Will I have to type the whole course this stuff? Probably only after the participants have become fit in dealing with the console - and can distinguish PBD from SR and VDI. Then it is too late, because everything dies during the procedure, which is already set up on the SR.
The best time is thus directly to the XenServer installation. But I have a pretty (ok, no, it is not pretty) shell script, but again we need winscp in order to transfer to the control domain, also exhausting for the faculty.
Have therefore, this evening in a hotel near Stuttgart rewritten the existing bash script into a batch file for Windows (and wow, this is me again noticed that you have crutches trying to how to achieve a few simple operations ... I variables It is essential to learn to script something better!)
The script requires a few adjustments, so open first with Notepad / Notepad and change the variables (line 10ff).
existence, the IP of the XenServer host, user name (if different from the root) and password, if it deviates from the standard rate.
Oh, and because the script do inexperienced natures hurt can I have a "safety catch" is installed. Only after a modification is to use this script. It's easy. It should really stop anyone who has seen a batch file, but it should prevent that someone "by mistake" with this script sets the cards. whether there should be yes. If the child safety intentionally removed and armed to the script, then it goes around - but now can no longer be any question of an unintended execution.
blogged enough, here is the script to copy and paste - Download:
@ echo off rem # # # contact
daniel.wipperfuerth @ adn.de for info / improvements.
echo ######
echo ### script to transform the default lvm based sr of
echo ### freshly installed (!) xenserver 5.5 / 5.6 to ext3
echo ### YOU WILL LOSE DATA! BE SURE YOU UNDERSTAND WHAT THIS SKRIPT IS DOING!
echo ######
setlocal
rem ### declaring windows specific variables
rem ### you should customize these
set pass=Password1
set host=192.168.0.21
set user=root
set xecmd="c:\program files (x86)\citrix\xencenter\xe.exe"
set xeparms=-s %host% -u %user% -pw %pass%
set handbrake=on
if %handbrake%==on goto bailout
rem ### SECTION ONE - gathering info
rem ### find our lvm sr
for /F "usebackq" %%n in (`%xecmd% %xeparms% host-list params^=uuid --minimal`) do set host-uuid=%%n
rem ### find our lvm sr
for /F "usebackq" %%n in (`%xecmd% %xeparms% sr-list type^=lvm params^=uuid --minimal`) do set sr-uuid=%%n
rem ### find the pbd of this sr
for /F "usebackq" %%n in (`%xecmd% %xeparms% pbd-list sr-uuid^=%sr-uuid% params^=uuid --minimal`) do set pbd-uuid=%%n
rem ### find the current device config (ie harddrive) of pbd
for /F "usebackq tokens=2" %%n in (`%xecmd% %xeparms% pbd-list uuid^=%pbd-uuid% params^=device-config --minimal`) do set deviceconfig=%%n
rem ### SECTION TWO - wreak havok
rem ### erasing all vdis from sr that would prevent deletion
for /F "usebackq delims=," %%n in (`%xecmd% %xeparms% vdi-list sr-uuid^=%sr-uuid% params^=uuid --minimal`) do %xecmd% %xeparms% vdi-destroy uuid=%%n
rem ### unplugging pbd
%xecmd% %xeparms% pbd-unplug uuid=%pbd-uuid%
rem ### destroying sr
%xecmd% %xeparms% sr-destroy uuid=%sr-uuid%
rem ### SECTION THREE - rebuild sr
%xecmd% %xeparms% sr-create host-uuid=%host-uuid% type=ext device-config:device=%deviceconfig% shared=false name-label="Ext3 SR"
rem ### cleaning up
endlocal
goto end
:bailout
echo handbrake error. try www.disney.com for help.
:end
pause
0 comments:
Post a Comment