After installation or upgrade to XenServer 6.0, user experiences issues with any storage related operations. The following error message appears:
“SR_BACKEND_FAILURE_181 Error In metadata Volume Operation For SR.”
The following entries appears in the log /var/log/SMlog file:
Error code: SR_BACKEND_FAILURE_181 Error parameters: , Error in Metadata volume operation for SR. opterr=VDI delete operation failed for parameters: /dev/VG_XenStorage-427796a3-6891-dcb7-681f-cc7c5463ea0a/MGT, 7b496cd3-9d9c-4cb4-b510-4613e65e7141. Error: not well-formed (invalid token): line 1, column 99, [10146] 2011-11-27 08:05:10.977985 Raising exception [181, Error in Metadata volume operation for SR. [opterr=VDI delete operation failed for parameters: /dev/VG_XenStorage-511f729e-0f0e-a679-9b8e-4d7ed28f6537/MGT, 65f8e675-9416-4909-8cd1-b7d75af06762. Error: not well-formed (invalid token): line 1, column 65]] [10146] 2011-11-27 08:05:10.978109 lock: released /var/lock/sm/511f729e-0f0e-a679-9b8e-4d7ed28f6537/sr [10146] 2011-11-27 08:05:10.979583 ***** sr_scan: EXCEPTION SR.SROSError, Error in Metadata volume operation for SR. [opterr=VDI delete operation failed for parameters: /dev/VG_XenStorage-511f729e-0f0e-a679-9b8e-4d7ed28f6537/MGT, 65f8e675-9416-4909-8cd1-b7d75af06762. Error: not well-formed (invalid token): line 1, column 65]
As a workaround, you can remove all special characters from the virtual machine name-label and description fields. Contact Citrix Technical Support to assist you in resolving the issue.
Note: Special character should not be used for the storage repository and description field.
In situation where the preceding workaround is unsuccessful, rebuild the SR MGT volume after removing the special characters:
Run lvscan and search for the MGT volume for the respective Storage Repository (SR).
Example: ACTIVE '/dev/VG_XenStorage-c14bee2a-44da-656a-5b99-865818c0a700/MGT' [4.00 MB] inherit
Run a test to verify that the lv can be renamed:
lvrename -t /dev/VG_Xenstorage- <SR-uuid>/MGT /dev/VG_Xenstorage- <SR-uuid>/MGT.bak
When the preceding test is successful, run lvrename without the “-t” option:
lvrename /dev/VG_Xenstorage- <SR-uuid>/MGT /dev/VG_Xenstorage-< SR-uuid>/MGT.bak
Restart the master host in the pool or unplug and re-plug the Physical Block Device (PBD) on the Master Host for the respective SR to build a new MGT volume.
Example:
Find the Master Host UUID > xe pool-list params=master
master ( RO) : 9079cff1-c457-4e51-b924-8a9e1ec24179
To find the master PBD, run > xe pbd-list sr-uuid= c14bee2a-44da-656a-5b99-865818c0a700 host-uuid=9079cff1-c457-4e51-b924-8a9e1ec24179
uuid ( RO) : 99c6d7ec-75ef-1071-d925-5ff6b4667ecc
host-uuid ( RO): 9079cff1-c457-4e51-b924-8a9e1ec24179
sr-uuid ( RO): 20daa9a1-a9b2-ddc9-30a7-c4e15999a284
device-config (MRO): device: /dev/sdb
currently-attached ( RO): true
Unplug the PBD for the master (using the PBD UUID from Step 5):
xe pbd-unplug uuid=99c6d7ec-75ef-1071-d925-5ff6b4667ecc
Re-Plug the PBD to attach the host to the SR again:
xe pbd-plug uuid=99c6d7ec-75ef-1071-d925-5ff6b4667ecc
This process will rebuild the MGT volume with the updated information without the special characters in the virtual machine name or description that was previously causing the errors.
Refer to the following Knowledge Center articles for the current updates that address this issue as of 01/02/2013:
CTX135411 - Hotfix XS60E022 - For XenServer 6.0
CTX135623 - Hotfix XS602E013 - For XenServer 6.0.2
XenServer does not properly store the incoming virtual machine name-label and description fields in management VDI (MGT).