Extreme problem - HyperV is not saving machine config files properly. I've encountered a problem with HyperV which involved the system performing a save state for a reboot.<br><br>Other machines saved and closed up fine.  However one of our machines must have had changes or something strange.<br><br>The changes weren't the problem.  It was the way hyperv saved the file.<br><br>The file was not truncated first, so if the configuration file's size shrinks, it leaves a whole bunch of extra garbage at the end of the config file.  (Unparsable XML Code).<br><br>Event ID 18160<br><font size=1> <p>The requested operation cannot be performed on a file with a user-mapped section open. (0x800704C8)</p></font><br><br><br><br>You can inspect your XML files by opening them with something like internet explorer.  If it cuts out near the bottom with a parse error at the end, then that was the cause (bad data still left at the end of the config).<br><br><br>This can make the configuration just disappear from the HyperV manager.  Honestly, why isn't this at least brought to attention with something more english like.<br><br><br>Microsoft, please get someone on fixing this ASAP.  It can be a huge issue if notes in a config file are changed and the file becomes smaller.<br><br><br><br>&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-16&quot; standalone=&quot;yes&quot;?&gt;<br>&lt;configuration&gt;<br>  &lt;_2497f4de-e9fa-4204-80e4-4b75c46419c0_&gt;<br>    &lt;EnabledState type=&quot;integer&quot;&gt;3&lt;/EnabledState&gt;<br>  &lt;/_2497f4de-e9fa-4204-80e4-4b75c46419c0_&gt;<br>  &lt;_83f8638b-8dca-4152-9eda-2ca8b33039b4_&gt;<br>    &lt;controller0&gt;<br>      &lt;drive0&gt;<br>        &lt;pathname type=&quot;string&quot;&gt;E:\Hyper-V\vm-Prod-SQL\VM-Prod-SQL-disk1.vhd&lt;/pathname&gt;<br>        &lt;type type=&quot;string&quot;&gt;VHD&lt;/type&gt;<br>      &lt;/drive0&gt;<br>      &lt;drive1&gt;<br>        &lt;pathname type=&quot;string&quot;&gt;E:\Hyper-V\vm-Prod-SQL\VM-Prod-SQL-disk2.vhd&lt;/pathname&gt;<br>        &lt;type type=&quot;string&quot;&gt;VHD&lt;/type&gt;<br>      &lt;/drive1&gt;<br>    &lt;/controller0&gt;<br>    &lt;controller1&gt;<br>      &lt;drive0&gt;<br>        &lt;pathname type=&quot;string&quot;&gt;E:\ISO\en_office_sharepoint_server_2007_EE_and_SE_DVD_X13-38823.iso&lt;/pathname&gt;<br>        &lt;type type=&quot;string&quot;&gt;ISO&lt;/type&gt;<br>      &lt;/drive0&gt;<br>      &lt;drive1&gt;<br>        &lt;pathname type=&quot;string&quot;&gt;E:\Hyper-V\vm-Prod-SQL\VM-Prod-SQL-Disk3.vhd&lt;/pathname&gt;<br>        &lt;type type=&quot;string&quot;&gt;VHD&lt;/type&gt;<br>      &lt;/drive1&gt;<br>    &lt;/controller1&gt;<br>    &lt;enable_track_cache type=&quot;bool&quot;&gt;True&lt;/enable_track_cache&gt;<br>    &lt;version type=&quot;integer&quot;&gt;5&lt;/version&gt;<br>  &lt;/_83f8638b-8dca-4152-9eda-2ca8b33039b4_&gt;<br>  &lt;_8e3a359f-559a-4b6a-98a9-1690a6100ed7_&gt;<br>    &lt;port0&gt;<br>      &lt;connection type=&quot;string&quot;&gt;&lt;/connection&gt;<br>    &lt;/port0&gt;<br>    &lt;port1&gt;<br>      &lt;connection type=&quot;string&quot;&gt;&lt;/connection&gt;<br>    &lt;/port1&gt;<br>    &lt;version type=&quot;integer&quot;&gt;2&lt;/version&gt;<br>  &lt;/_8e3a359f-559a-4b6a-98a9-1690a6100ed7_&gt;<br>  &lt;_8f0d2762-0b00-4e04-af4f-19010527cb93_&gt;<br>    &lt;controller0&gt;<br>      &lt;drive0&gt;<br>        &lt;pathname type=&quot;string&quot;&gt;&lt;/pathname&gt;<br>        &lt;type type=&quot;string&quot;&gt;VFD&lt;/type&gt;<br>      &lt;/drive0&gt;<br>    &lt;/controller0&gt;<br>    &lt;version type=&quot;integer&quot;&gt;1&lt;/version&gt;<br>  &lt;/_8f0d2762-0b00-4e04-af4f-19010527cb93_&gt;<br>  &lt;_a8a21672-99a4-4bcd-bb67-e7d90764f4fc_&gt;<br>    &lt;ChannelInstanceGuid type=&quot;string&quot;&gt;{6044c5f6-9c29-43d7-ac25-7a3e4a68ca26}&lt;/ChannelInstanceGuid&gt;<br>    &lt;FriendlyName type=&quot;string&quot;&gt;Network Adapter&lt;/FriendlyName&gt;<br>    &lt;IsConnected type=&quot;bool&quot;&gt;True&lt;/IsConnected&gt;<br>    &lt;MacAddress type=&quot;string&quot;&gt;00-15-5D-64-1A-09&lt;/MacAddress&gt;<br>    &lt;MacAddressIsStatic type=&quot;bool&quot;&gt;False&lt;/MacAddressIsStatic&gt;<br>    &lt;PortName type=&quot;string&quot;&gt;8a8da045-3833-413f-ace1-cfb3927908df&lt;/PortName&gt;<br>    &lt;SwitchName type=&quot;string&quot;&gt;1467cd13-468f-4360-96b0-4f5d975544ad&lt;/SwitchName&gt;<br>  &lt;/_a8a21672-99a4-4bcd-bb67-e7d90764f4fc_&gt;<br>  &lt;_ac6b8dc1-3257-4a70-b1b2-a9c9215659ad_&gt;<br>    &lt;base_board&gt;<br>      &lt;serial_number type=&quot;string&quot;&gt;0479-0232-3489-3094-8015-3472-48&lt;/serial_number&gt;<br>    &lt;/base_board&gt;<br>    &lt;bios_guid type=&quot;string&quot;&gt;{503CE3AB-CABB-4A0C-96EB-D03D14CEE6F8}&lt;/bios_guid&gt;<br>    &lt;bios_serial_number type=&quot;string&quot;&gt;0479-0232-3489-3094-8015-3472-48&lt;/bios_serial_number&gt;<br>    &lt;boot&gt;<br>      &lt;device0 type=&quot;string&quot;&gt;Optical&lt;/device0&gt;<br>      &lt;device1 type=&quot;string&quot;&gt;HardDrive&lt;/device1&gt;<br>      &lt;device2 type=&quot;string&quot;&gt;Network&lt;/device2&gt;<br>      &lt;device3 type=&quot;string&quot;&gt;Floppy&lt;/device3&gt;<br>    &lt;/boot&gt;<br>    &lt;chassis&gt;<br>      &lt;asset_tag type=&quot;string&quot;&gt;0991-4035-2547-6297-7322-3795-21&lt;/asset_tag&gt;<br>      &lt;serial_number type=&quot;string&quot;&gt;0479-0232-3489-3094-8015-3472-48&lt;/serial_number&gt;<br>    &lt;/chassis&gt;<br>    &lt;num_lock type=&quot;bool&quot;&gt;False&lt;/num_lock&gt;<br>    &lt;version type=&quot;integer&quot;&gt;2&lt;/version&gt;<br>  &lt;/_ac6b8dc1-3257-4a70-b1b2-a9c9215659ad_&gt;<br>  &lt;_db8b9818-b4bb-4725-b99d-b4612716b6b4_&gt;<br>    &lt;SPD_A0 type=&quot;integer&quot;&gt;4181387501&lt;/SPD_A0&gt;<br>    &lt;SPD_A2 type=&quot;integer&quot;&gt;2264515423&lt;/SPD_A2&gt;<br>    &lt;SPD_A4 type=&quot;integer&quot;&gt;2703485784&lt;/SPD_A4&gt;<br>    &lt;SPD_A6 type=&quot;integer&quot;&gt;1107243157&lt;/SPD_A6&gt;<br>    &lt;version type=&quot;integer&quot;&gt;0&lt;/version&gt;<br>  &lt;/_db8b9818-b4bb-4725-b99d-b4612716b6b4_&gt;<br>  &lt;global_settings&gt;<br>    &lt;disk_merge_pending type=&quot;bool&quot;&gt;False&lt;/disk_merge_pending&gt;<br>    &lt;owner&gt;<br>      &lt;sid type=&quot;string&quot;&gt;S-1-5-21-1935655697-1606980848-1957994488-2651&lt;/sid&gt;<br>    &lt;/owner&gt;<br>    &lt;power&gt;<br>      &lt;host_shutdown&gt;<br>        &lt;action type=&quot;integer&quot;&gt;1&lt;/action&gt;<br>      &lt;/host_shutdown&gt;<br>      &lt;host_startup&gt;<br>        &lt;action type=&quot;integer&quot;&gt;2&lt;/action&gt;<br>        &lt;delay type=&quot;integer&quot;&gt;600000000&lt;/delay&gt;<br>      &lt;/host_startup&gt;<br>    &lt;/power&gt;<br>    &lt;snapshots&gt;<br>      &lt;list&gt;<br>        &lt;size type=&quot;integer&quot;&gt;0&lt;/size&gt;<br>      &lt;/list&gt;<br>    &lt;/snapshots&gt;<br>    &lt;unexpected_termination&gt;<br>      &lt;action type=&quot;integer&quot;&gt;1&lt;/action&gt;<br>    &lt;/unexpected_termination&gt;<br>  &lt;/global_settings&gt;<br>  &lt;manifest&gt;<br>    &lt;size type=&quot;integer&quot;&gt;8&lt;/size&gt;<br>    &lt;vdev001&gt;<br>      &lt;device type=&quot;string&quot;&gt;58f75a6d-d949-4320-99e1-a2a2576d581c&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;58f75a6d-d949-4320-99e1-a2a2576d581c&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Synthetic Mouse&lt;/name&gt;<br>    &lt;/vdev001&gt;<br>    &lt;vdev002&gt;<br>      &lt;device type=&quot;string&quot;&gt;f3cf6965-e8d3-44a9-9b7d-a04245ea7525&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;f3cf6965-e8d3-44a9-9b7d-a04245ea7525&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Synthetic Video&lt;/name&gt;<br>    &lt;/vdev002&gt;<br>    &lt;vdev003&gt;<br>      &lt;device type=&quot;string&quot;&gt;84eaae65-2f2e-45f5-9bb5-0e857dc8eb47&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;84eaae65-2f2e-45f5-9bb5-0e857dc8eb47&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Heartbeat Component&lt;/name&gt;<br>    &lt;/vdev003&gt;<br>    &lt;vdev004&gt;<br>      &lt;device type=&quot;string&quot;&gt;2a34b1c2-fd73-4043-8a5b-dd2159bc743f&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;2a34b1c2-fd73-4043-8a5b-dd2159bc743f&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Key-Value Pair Exchange Component&lt;/name&gt;<br>    &lt;/vdev004&gt;<br>    &lt;vdev005&gt;<br>      &lt;device type=&quot;string&quot;&gt;9f8233ac-be49-4c79-8ee3-e7e1985b2077&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;9f8233ac-be49-4c79-8ee3-e7e1985b2077&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Shutdown Component&lt;/name&gt;<br>    &lt;/vdev005&gt;<br>    &lt;vdev006&gt;<br>      &lt;device type=&quot;string&quot;&gt;2497f4de-e9fa-4204-80e4-4b75c46419c0&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;2497f4de-e9fa-4204-80e4-4b75c46419c0&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Time Synchronization Component&lt;/name&gt;<br>    &lt;/vdev006&gt;<br>    &lt;vdev007&gt;<br>      &lt;device type=&quot;string&quot;&gt;5ced1297-4598-4915-a5fc-ad21bb4d02a4&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;5ced1297-4598-4915-a5fc-ad21bb4d02a4&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft VSS Component&lt;/name&gt;<br>    &lt;/vdev007&gt;<br>    &lt;vdev008&gt;<br>      &lt;device type=&quot;string&quot;&gt;2fc216b0-d2e2-4967-9b6d-b8a5c9ca2778&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;a8a21672-99a4-4bcd-bb67-e7d90764f4fc&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Synthetic Ethernet Port&lt;/name&gt;<br>    &lt;/vdev008&gt;<br>    &lt;version type=&quot;integer&quot;&gt;260&lt;/version&gt;<br>  &lt;/manifest&gt;<br>  &lt;properties&gt;<br>    &lt;global_id type=&quot;string&quot;&gt;E021A095-7D94-4A1F-8A08-5AB3AFCA7354&lt;/global_id&gt;<br>    &lt;last_powered_off_time type=&quot;integer&quot;&gt;128586783435736417&lt;/last_powered_off_time&gt;<br>    &lt;last_powered_on_time type=&quot;integer&quot;&gt;128570559531931085&lt;/last_powered_on_time&gt;<br>    &lt;last_state_change_time type=&quot;integer&quot;&gt;128586785989740834&lt;/last_state_change_time&gt;<br>    &lt;name type=&quot;string&quot;&gt;vm-Prod-SQL&lt;/name&gt;<br>    &lt;notes type=&quot;string&quot;&gt;&lt;/notes&gt;<br>    &lt;type_id type=&quot;string&quot;&gt;Virtual Machines&lt;/type_id&gt;<br>  &lt;/properties&gt;<br>  &lt;savedstate /&gt;<br>  &lt;settings&gt;<br>    &lt;global&gt;<br>      &lt;logical_id type=&quot;string&quot;&gt;E021A095-7D94-4A1F-8A08-5AB3AFCA7354&lt;/logical_id&gt;<br>    &lt;/global&gt;<br>    &lt;memory&gt;<br>      &lt;bank&gt;<br>        &lt;size type=&quot;integer&quot;&gt;1200&lt;/size&gt;<br>      &lt;/bank&gt;<br>    &lt;/memory&gt;<br>    &lt;processors&gt;<br>      &lt;count type=&quot;integer&quot;&gt;2&lt;/count&gt;<br>      &lt;limit type=&quot;integer&quot;&gt;100000&lt;/limit&gt;<br>      &lt;reservation type=&quot;integer&quot;&gt;0&lt;/reservation&gt;<br>      &lt;weight type=&quot;integer&quot;&gt;100&lt;/weight&gt;<br>    &lt;/processors&gt;<br>    &lt;stopped_at_host_shutdown type=&quot;bool&quot;&gt;True&lt;/stopped_at_host_shutdown&gt;<br>  &lt;/settings&gt;<br>&lt;/configuration&gt;<font style="background-color:#cc0000">  &lt;memory&gt;<br>      &lt;bank&gt;<br>        &lt;size type=&quot;integer&quot;&gt;1200&lt;/size&gt;<br>      &lt;/bank&gt;<br>    &lt;/memory&gt;<br>    &lt;processors&gt;<br>      &lt;count type=&quot;integer&quot;&gt;2&lt;/count&gt;<br>      &lt;limit type=&quot;integer&quot;&gt;100000&lt;/limit&gt;<br>      &lt;reservation type=&quot;integer&quot;&gt;0&lt;/reservation&gt;<br>      &lt;weight type=&quot;integer&quot;&gt;100&lt;/weight&gt;<br>    &lt;/processors&gt;<br>    &lt;stopped_at_host_shutdown type=&quot;bool&quot;&gt;True&lt;/stopped_at_host_shutdown&gt;<br>  &lt;/settings&gt;<br>&lt;/configuration&gt;</font><br><br>Notice the extra garbage data left at the end of the file after it was supposed to be cleared and written shorter.<br><br><br>Ugh, it's almost 3 AM I'm really sorry if this post just sounds horribly bad in grammar.  <br><br><br>Essentially somewhere in the code you're just writting the bytes intead of deleting and re-writing the file.<br><hr size="1" align="left" width="25%">Alexi Nostavich© 2009 Microsoft Corporation. All rights reserved.Mon, 30 Jun 2008 01:07:42 Zd872c7a9-8755-4919-ba60-4bd42ebe0cc8http://social.technet.microsoft.com/Forums/en-US/winserverhyperv/thread/d872c7a9-8755-4919-ba60-4bd42ebe0cc8#d872c7a9-8755-4919-ba60-4bd42ebe0cc8http://social.technet.microsoft.com/Forums/en-US/winserverhyperv/thread/d872c7a9-8755-4919-ba60-4bd42ebe0cc8#d872c7a9-8755-4919-ba60-4bd42ebe0cc8AlexiNostavichhttp://social.technet.microsoft.com/Profile/en-US/?user=AlexiNostavichExtreme problem - HyperV is not saving machine config files properly. I've encountered a problem with HyperV which involved the system performing a save state for a reboot.<br><br>Other machines saved and closed up fine.  However one of our machines must have had changes or something strange.<br><br>The changes weren't the problem.  It was the way hyperv saved the file.<br><br>The file was not truncated first, so if the configuration file's size shrinks, it leaves a whole bunch of extra garbage at the end of the config file.  (Unparsable XML Code).<br><br>Event ID 18160<br><font size=1> <p>The requested operation cannot be performed on a file with a user-mapped section open. (0x800704C8)</p></font><br><br><br><br>You can inspect your XML files by opening them with something like internet explorer.  If it cuts out near the bottom with a parse error at the end, then that was the cause (bad data still left at the end of the config).<br><br><br>This can make the configuration just disappear from the HyperV manager.  Honestly, why isn't this at least brought to attention with something more english like.<br><br><br>Microsoft, please get someone on fixing this ASAP.  It can be a huge issue if notes in a config file are changed and the file becomes smaller.<br><br><br><br>&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-16&quot; standalone=&quot;yes&quot;?&gt;<br>&lt;configuration&gt;<br>  &lt;_2497f4de-e9fa-4204-80e4-4b75c46419c0_&gt;<br>    &lt;EnabledState type=&quot;integer&quot;&gt;3&lt;/EnabledState&gt;<br>  &lt;/_2497f4de-e9fa-4204-80e4-4b75c46419c0_&gt;<br>  &lt;_83f8638b-8dca-4152-9eda-2ca8b33039b4_&gt;<br>    &lt;controller0&gt;<br>      &lt;drive0&gt;<br>        &lt;pathname type=&quot;string&quot;&gt;E:\Hyper-V\vm-Prod-SQL\VM-Prod-SQL-disk1.vhd&lt;/pathname&gt;<br>        &lt;type type=&quot;string&quot;&gt;VHD&lt;/type&gt;<br>      &lt;/drive0&gt;<br>      &lt;drive1&gt;<br>        &lt;pathname type=&quot;string&quot;&gt;E:\Hyper-V\vm-Prod-SQL\VM-Prod-SQL-disk2.vhd&lt;/pathname&gt;<br>        &lt;type type=&quot;string&quot;&gt;VHD&lt;/type&gt;<br>      &lt;/drive1&gt;<br>    &lt;/controller0&gt;<br>    &lt;controller1&gt;<br>      &lt;drive0&gt;<br>        &lt;pathname type=&quot;string&quot;&gt;E:\ISO\en_office_sharepoint_server_2007_EE_and_SE_DVD_X13-38823.iso&lt;/pathname&gt;<br>        &lt;type type=&quot;string&quot;&gt;ISO&lt;/type&gt;<br>      &lt;/drive0&gt;<br>      &lt;drive1&gt;<br>        &lt;pathname type=&quot;string&quot;&gt;E:\Hyper-V\vm-Prod-SQL\VM-Prod-SQL-Disk3.vhd&lt;/pathname&gt;<br>        &lt;type type=&quot;string&quot;&gt;VHD&lt;/type&gt;<br>      &lt;/drive1&gt;<br>    &lt;/controller1&gt;<br>    &lt;enable_track_cache type=&quot;bool&quot;&gt;True&lt;/enable_track_cache&gt;<br>    &lt;version type=&quot;integer&quot;&gt;5&lt;/version&gt;<br>  &lt;/_83f8638b-8dca-4152-9eda-2ca8b33039b4_&gt;<br>  &lt;_8e3a359f-559a-4b6a-98a9-1690a6100ed7_&gt;<br>    &lt;port0&gt;<br>      &lt;connection type=&quot;string&quot;&gt;&lt;/connection&gt;<br>    &lt;/port0&gt;<br>    &lt;port1&gt;<br>      &lt;connection type=&quot;string&quot;&gt;&lt;/connection&gt;<br>    &lt;/port1&gt;<br>    &lt;version type=&quot;integer&quot;&gt;2&lt;/version&gt;<br>  &lt;/_8e3a359f-559a-4b6a-98a9-1690a6100ed7_&gt;<br>  &lt;_8f0d2762-0b00-4e04-af4f-19010527cb93_&gt;<br>    &lt;controller0&gt;<br>      &lt;drive0&gt;<br>        &lt;pathname type=&quot;string&quot;&gt;&lt;/pathname&gt;<br>        &lt;type type=&quot;string&quot;&gt;VFD&lt;/type&gt;<br>      &lt;/drive0&gt;<br>    &lt;/controller0&gt;<br>    &lt;version type=&quot;integer&quot;&gt;1&lt;/version&gt;<br>  &lt;/_8f0d2762-0b00-4e04-af4f-19010527cb93_&gt;<br>  &lt;_a8a21672-99a4-4bcd-bb67-e7d90764f4fc_&gt;<br>    &lt;ChannelInstanceGuid type=&quot;string&quot;&gt;{6044c5f6-9c29-43d7-ac25-7a3e4a68ca26}&lt;/ChannelInstanceGuid&gt;<br>    &lt;FriendlyName type=&quot;string&quot;&gt;Network Adapter&lt;/FriendlyName&gt;<br>    &lt;IsConnected type=&quot;bool&quot;&gt;True&lt;/IsConnected&gt;<br>    &lt;MacAddress type=&quot;string&quot;&gt;00-15-5D-64-1A-09&lt;/MacAddress&gt;<br>    &lt;MacAddressIsStatic type=&quot;bool&quot;&gt;False&lt;/MacAddressIsStatic&gt;<br>    &lt;PortName type=&quot;string&quot;&gt;8a8da045-3833-413f-ace1-cfb3927908df&lt;/PortName&gt;<br>    &lt;SwitchName type=&quot;string&quot;&gt;1467cd13-468f-4360-96b0-4f5d975544ad&lt;/SwitchName&gt;<br>  &lt;/_a8a21672-99a4-4bcd-bb67-e7d90764f4fc_&gt;<br>  &lt;_ac6b8dc1-3257-4a70-b1b2-a9c9215659ad_&gt;<br>    &lt;base_board&gt;<br>      &lt;serial_number type=&quot;string&quot;&gt;0479-0232-3489-3094-8015-3472-48&lt;/serial_number&gt;<br>    &lt;/base_board&gt;<br>    &lt;bios_guid type=&quot;string&quot;&gt;{503CE3AB-CABB-4A0C-96EB-D03D14CEE6F8}&lt;/bios_guid&gt;<br>    &lt;bios_serial_number type=&quot;string&quot;&gt;0479-0232-3489-3094-8015-3472-48&lt;/bios_serial_number&gt;<br>    &lt;boot&gt;<br>      &lt;device0 type=&quot;string&quot;&gt;Optical&lt;/device0&gt;<br>      &lt;device1 type=&quot;string&quot;&gt;HardDrive&lt;/device1&gt;<br>      &lt;device2 type=&quot;string&quot;&gt;Network&lt;/device2&gt;<br>      &lt;device3 type=&quot;string&quot;&gt;Floppy&lt;/device3&gt;<br>    &lt;/boot&gt;<br>    &lt;chassis&gt;<br>      &lt;asset_tag type=&quot;string&quot;&gt;0991-4035-2547-6297-7322-3795-21&lt;/asset_tag&gt;<br>      &lt;serial_number type=&quot;string&quot;&gt;0479-0232-3489-3094-8015-3472-48&lt;/serial_number&gt;<br>    &lt;/chassis&gt;<br>    &lt;num_lock type=&quot;bool&quot;&gt;False&lt;/num_lock&gt;<br>    &lt;version type=&quot;integer&quot;&gt;2&lt;/version&gt;<br>  &lt;/_ac6b8dc1-3257-4a70-b1b2-a9c9215659ad_&gt;<br>  &lt;_db8b9818-b4bb-4725-b99d-b4612716b6b4_&gt;<br>    &lt;SPD_A0 type=&quot;integer&quot;&gt;4181387501&lt;/SPD_A0&gt;<br>    &lt;SPD_A2 type=&quot;integer&quot;&gt;2264515423&lt;/SPD_A2&gt;<br>    &lt;SPD_A4 type=&quot;integer&quot;&gt;2703485784&lt;/SPD_A4&gt;<br>    &lt;SPD_A6 type=&quot;integer&quot;&gt;1107243157&lt;/SPD_A6&gt;<br>    &lt;version type=&quot;integer&quot;&gt;0&lt;/version&gt;<br>  &lt;/_db8b9818-b4bb-4725-b99d-b4612716b6b4_&gt;<br>  &lt;global_settings&gt;<br>    &lt;disk_merge_pending type=&quot;bool&quot;&gt;False&lt;/disk_merge_pending&gt;<br>    &lt;owner&gt;<br>      &lt;sid type=&quot;string&quot;&gt;S-1-5-21-1935655697-1606980848-1957994488-2651&lt;/sid&gt;<br>    &lt;/owner&gt;<br>    &lt;power&gt;<br>      &lt;host_shutdown&gt;<br>        &lt;action type=&quot;integer&quot;&gt;1&lt;/action&gt;<br>      &lt;/host_shutdown&gt;<br>      &lt;host_startup&gt;<br>        &lt;action type=&quot;integer&quot;&gt;2&lt;/action&gt;<br>        &lt;delay type=&quot;integer&quot;&gt;600000000&lt;/delay&gt;<br>      &lt;/host_startup&gt;<br>    &lt;/power&gt;<br>    &lt;snapshots&gt;<br>      &lt;list&gt;<br>        &lt;size type=&quot;integer&quot;&gt;0&lt;/size&gt;<br>      &lt;/list&gt;<br>    &lt;/snapshots&gt;<br>    &lt;unexpected_termination&gt;<br>      &lt;action type=&quot;integer&quot;&gt;1&lt;/action&gt;<br>    &lt;/unexpected_termination&gt;<br>  &lt;/global_settings&gt;<br>  &lt;manifest&gt;<br>    &lt;size type=&quot;integer&quot;&gt;8&lt;/size&gt;<br>    &lt;vdev001&gt;<br>      &lt;device type=&quot;string&quot;&gt;58f75a6d-d949-4320-99e1-a2a2576d581c&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;58f75a6d-d949-4320-99e1-a2a2576d581c&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Synthetic Mouse&lt;/name&gt;<br>    &lt;/vdev001&gt;<br>    &lt;vdev002&gt;<br>      &lt;device type=&quot;string&quot;&gt;f3cf6965-e8d3-44a9-9b7d-a04245ea7525&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;f3cf6965-e8d3-44a9-9b7d-a04245ea7525&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Synthetic Video&lt;/name&gt;<br>    &lt;/vdev002&gt;<br>    &lt;vdev003&gt;<br>      &lt;device type=&quot;string&quot;&gt;84eaae65-2f2e-45f5-9bb5-0e857dc8eb47&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;84eaae65-2f2e-45f5-9bb5-0e857dc8eb47&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Heartbeat Component&lt;/name&gt;<br>    &lt;/vdev003&gt;<br>    &lt;vdev004&gt;<br>      &lt;device type=&quot;string&quot;&gt;2a34b1c2-fd73-4043-8a5b-dd2159bc743f&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;2a34b1c2-fd73-4043-8a5b-dd2159bc743f&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Key-Value Pair Exchange Component&lt;/name&gt;<br>    &lt;/vdev004&gt;<br>    &lt;vdev005&gt;<br>      &lt;device type=&quot;string&quot;&gt;9f8233ac-be49-4c79-8ee3-e7e1985b2077&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;9f8233ac-be49-4c79-8ee3-e7e1985b2077&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Shutdown Component&lt;/name&gt;<br>    &lt;/vdev005&gt;<br>    &lt;vdev006&gt;<br>      &lt;device type=&quot;string&quot;&gt;2497f4de-e9fa-4204-80e4-4b75c46419c0&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;2497f4de-e9fa-4204-80e4-4b75c46419c0&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Time Synchronization Component&lt;/name&gt;<br>    &lt;/vdev006&gt;<br>    &lt;vdev007&gt;<br>      &lt;device type=&quot;string&quot;&gt;5ced1297-4598-4915-a5fc-ad21bb4d02a4&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;5ced1297-4598-4915-a5fc-ad21bb4d02a4&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft VSS Component&lt;/name&gt;<br>    &lt;/vdev007&gt;<br>    &lt;vdev008&gt;<br>      &lt;device type=&quot;string&quot;&gt;2fc216b0-d2e2-4967-9b6d-b8a5c9ca2778&lt;/device&gt;<br>      &lt;flags type=&quot;integer&quot;&gt;1&lt;/flags&gt;<br>      &lt;instance type=&quot;string&quot;&gt;a8a21672-99a4-4bcd-bb67-e7d90764f4fc&lt;/instance&gt;<br>      &lt;name type=&quot;string&quot;&gt;Microsoft Synthetic Ethernet Port&lt;/name&gt;<br>    &lt;/vdev008&gt;<br>    &lt;version type=&quot;integer&quot;&gt;260&lt;/version&gt;<br>  &lt;/manifest&gt;<br>  &lt;properties&gt;<br>    &lt;global_id type=&quot;string&quot;&gt;E021A095-7D94-4A1F-8A08-5AB3AFCA7354&lt;/global_id&gt;<br>    &lt;last_powered_off_time type=&quot;integer&quot;&gt;128586783435736417&lt;/last_powered_off_time&gt;<br>    &lt;last_powered_on_time type=&quot;integer&quot;&gt;128570559531931085&lt;/last_powered_on_time&gt;<br>    &lt;last_state_change_time type=&quot;integer&quot;&gt;128586785989740834&lt;/last_state_change_time&gt;<br>    &lt;name type=&quot;string&quot;&gt;vm-Prod-SQL&lt;/name&gt;<br>    &lt;notes type=&quot;string&quot;&gt;&lt;/notes&gt;<br>    &lt;type_id type=&quot;string&quot;&gt;Virtual Machines&lt;/type_id&gt;<br>  &lt;/properties&gt;<br>  &lt;savedstate /&gt;<br>  &lt;settings&gt;<br>    &lt;global&gt;<br>      &lt;logical_id type=&quot;string&quot;&gt;E021A095-7D94-4A1F-8A08-5AB3AFCA7354&lt;/logical_id&gt;<br>    &lt;/global&gt;<br>    &lt;memory&gt;<br>      &lt;bank&gt;<br>        &lt;size type=&quot;integer&quot;&gt;1200&lt;/size&gt;<br>      &lt;/bank&gt;<br>    &lt;/memory&gt;<br>    &lt;processors&gt;<br>      &lt;count type=&quot;integer&quot;&gt;2&lt;/count&gt;<br>      &lt;limit type=&quot;integer&quot;&gt;100000&lt;/limit&gt;<br>      &lt;reservation type=&quot;integer&quot;&gt;0&lt;/reservation&gt;<br>      &lt;weight type=&quot;integer&quot;&gt;100&lt;/weight&gt;<br>    &lt;/processors&gt;<br>    &lt;stopped_at_host_shutdown type=&quot;bool&quot;&gt;True&lt;/stopped_at_host_shutdown&gt;<br>  &lt;/settings&gt;<br>&lt;/configuration&gt;<font style="background-color:#cc0000">  &lt;memory&gt;<br>      &lt;bank&gt;<br>        &lt;size type=&quot;integer&quot;&gt;1200&lt;/size&gt;<br>      &lt;/bank&gt;<br>    &lt;/memory&gt;<br>    &lt;processors&gt;<br>      &lt;count type=&quot;integer&quot;&gt;2&lt;/count&gt;<br>      &lt;limit type=&quot;integer&quot;&gt;100000&lt;/limit&gt;<br>      &lt;reservation type=&quot;integer&quot;&gt;0&lt;/reservation&gt;<br>      &lt;weight type=&quot;integer&quot;&gt;100&lt;/weight&gt;<br>    &lt;/processors&gt;<br>    &lt;stopped_at_host_shutdown type=&quot;bool&quot;&gt;True&lt;/stopped_at_host_shutdown&gt;<br>  &lt;/settings&gt;<br>&lt;/configuration&gt;</font><br><br>Notice the extra garbage data left at the end of the file after it was supposed to be cleared and written shorter.<br><br><br>Ugh, it's almost 3 AM I'm really sorry if this post just sounds horribly bad in grammar.  <br><br><br>Essentially somewhere in the code you're just writting the bytes intead of deleting and re-writing the file.<br><hr size="1" align="left" width="25%">Alexi NostavichMon, 23 Jun 2008 08:26:43 Z2008-06-23T08:26:43Zhttp://social.technet.microsoft.com/Forums/en-US/winserverhyperv/thread/d872c7a9-8755-4919-ba60-4bd42ebe0cc8#5f46be80-a682-4e4c-85ee-52bd66b2460dhttp://social.technet.microsoft.com/Forums/en-US/winserverhyperv/thread/d872c7a9-8755-4919-ba60-4bd42ebe0cc8#5f46be80-a682-4e4c-85ee-52bd66b2460dCraig Leachhttp://social.technet.microsoft.com/Profile/en-US/?user=Craig%20LeachExtreme problem - HyperV is not saving machine config files properly. I'm having the same problem as you. I've had to edit the XML configuration files about on about 33% of the server setting edits. This occured with both RC0 and RC1.<br><br>Regards,<br>Craig Leach<hr size="1" align="left" width="25%">Craig LeachTue, 24 Jun 2008 01:12:13 Z2008-06-24T01:12:13Zhttp://social.technet.microsoft.com/Forums/en-US/winserverhyperv/thread/d872c7a9-8755-4919-ba60-4bd42ebe0cc8#71c98922-6902-4bd7-8305-5cafa471ecb3http://social.technet.microsoft.com/Forums/en-US/winserverhyperv/thread/d872c7a9-8755-4919-ba60-4bd42ebe0cc8#71c98922-6902-4bd7-8305-5cafa471ecb3Chang Yinhttp://social.technet.microsoft.com/Profile/en-US/?user=Chang%20YinExtreme problem - HyperV is not saving machine config files properly.  <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">Hello,</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"> </span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">I think there might be some accidents (e.g. power-outage) that caused the XML file corrupted or some Security Products (especially the ForeFront Client Security) that seized the XML file.</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"> </span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">Would you please take a look at the Event Viewer at &quot;Application and Services Logs\Microsoft\Windows\Hyper-V-VMMS\Admin&quot;, see if any relevant errors or warnings exist? Please also let us know the exact messages about the Event 18160, see if it has some detailed information about the code like 0XC00CEE2D.</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"> </span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">We have seen some issues about &quot;The requested operation cannot be performed on a file with a user-mapped section open. (0x800704C8)&quot;. This error may occur when you have Microsoft ForeFront Client Security or some other Security Products installed. And if this is the case, you can try the following method:</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"> </span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">Set exclusions for the following directories:</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"> </span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">Default/Custom VHD Directory</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">Default/Custom VM Config Directory</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">Snapshots Directory</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"> </span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">Also, in the case with ForeFront, you can set exclusions for files that processes will access. You will want to include C:\Windows\system32\vmms.exe and C:\Windows\system32\vmwp.exe.</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"> </span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">If you have encountered any accidents like the power-outage, the configuration file may be corrupted. As I saw some unusual entries in this XML file, such as unpaired entry &quot;&lt;savedstate /&gt;&quot; and the last duplicated lines, the reason why saving a VM may result in an unusual configuration file may be due to the incorrect XML file. And if this is the case, you can try restarting the server more than once to see how it goes. Would you please take a look at the following thread and see if Jon's situation is similar:</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"> </span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"><a href="http://forums.technet.microsoft.com/zh-CN/winserverhyperv/thread/c67724e6-4420-4b3f-8049-1029902176f9/"><font color="#0000ff">http://forums.technet.microsoft.com/zh-CN/winserverhyperv/thread/c67724e6-4420-4b3f-8049-1029902176f9/</font></a></span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"> </span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">Additionally, would you please try re-creating the problematic VM with the existing VHD and then see if the problem remains?</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"> </span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">Thank you for your cooperation.</span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'"> </span></p> <p style="margin:0cm 0cm 0pt"><span style="font-size:10pt;font-family:'Verdana','sans-serif'">Best regards,</span></p><span style="font-size:10pt;font-family:'Verdana','sans-serif'">Chang Yin</span>Thu, 26 Jun 2008 12:03:53 Z2008-06-26T12:03:53Z