Index: VBoxHDD.cpp
===================================================================
--- VBoxHDD.cpp	(revision 23577)
+++ VBoxHDD.cpp	(working copy)
@@ -606,7 +606,6 @@
     return rc;
 }
 
-
 /**
  * internal: scans plugin directory and loads the backends have been found.
  */
@@ -2242,6 +2241,15 @@
                 /** @todo Please, review this! It's an ugly hack I think... */
                 if (!RTStrICmp(pszBackend, "RAW"))
                     uImageFlags |= VD_IMAGE_FLAGS_FIXED;
+				
+				if (PCHSGeometryFrom.cHeads > 16 || PCHSGeometryFrom.cSectors > 63)
+				{
+					Assert(RT_MIN(cbSize / 512 / 16 / 63, 16383) -
+					   (unsigned int)RT_MIN(cbSize / 512 / 16 / 63, 16383) == 0);		
+					PCHSGeometryFrom.cCylinders = (unsigned int)RT_MIN(cbSize / 512 / 16 / 63, 16383);
+					PCHSGeometryFrom.cHeads = 16;
+					PCHSGeometryFrom.cSectors = 63;
+				}				
 
                 rc = VDCreateBase(pDiskTo, pszBackend, pszFilename, cbSize,
                                   uImageFlags, szComment,
@@ -2326,7 +2334,8 @@
 
         if (RT_SUCCESS(rc))
         {
-            pImageTo->Backend->pfnSetModificationUuid(pImageTo->pvBackendData, &ImageModificationUuid);
+			if (!RTUuidIsNull(&ImageModificationUuid)) /* VDI doesn't like empty modify uuid */
+				pImageTo->Backend->pfnSetModificationUuid(pImageTo->pvBackendData, &ImageModificationUuid);
             /** @todo double-check this - it makes little sense to copy over the parent modification uuid,
              * as the destination image can have a totally different parent. */
 #if 0
