Changeset 32570 in vbox for trunk/src/VBox/Main/ConsoleImpl2.cpp
- Timestamp:
- Sep 16, 2010 3:54:14 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/ConsoleImpl2.cpp
r32531 r32570 2719 2719 * on an ext4 partition. Later we have to check the Linux kernel version! 2720 2720 * This bug apparently applies to the XFS file system as well. 2721 * Linux 2.6.36 is known to be fixed (tested with 2.6.36-rc4). 2721 2722 */ 2723 2724 char szOsRelease[128]; 2725 rc = RTSystemQueryOSInfo(RTSYSOSINFO_RELEASE, szOsRelease, sizeof(szOsRelease)); 2726 bool fKernelHasODirectBug = RT_FAILURE(rc) || RTStrVersionCompare(szOsRelease, "2.6.36") < 0; 2727 2722 2728 if ( (uCaps & MediumFormatCapabilities_Asynchronous) 2723 2729 && !fUseHostIOCache 2724 && ( enmFsTypeFile == RTFSTYPE_EXT4 2725 || enmFsTypeFile == RTFSTYPE_XFS)) 2726 { 2727 setVMRuntimeErrorCallbackF(pVM, this, 0, 2728 "Ext4PartitionDetected", 2729 N_("The host I/O cache for at least one controller is disabled " 2730 "and the medium '%ls' for this VM " 2731 "is located on an %s partition. There is a known Linux " 2732 "kernel bug which can lead to the corruption of the virtual " 2733 "disk image under these conditions.\n" 2734 "Either enable the host I/O cache permanently in the VM " 2735 "settings or put the disk image and the snapshot folder " 2736 "onto a different file system.\n" 2737 "The host I/O cache will now be enabled for this medium"), 2738 strFile.raw(), enmFsTypeFile == RTFSTYPE_EXT4 ? "ext4" : "xfs"); 2739 fUseHostIOCache = true; 2740 } 2741 else if ( (uCaps & MediumFormatCapabilities_Asynchronous) 2742 && !fUseHostIOCache 2743 && ( enmFsTypeSnap == RTFSTYPE_EXT4 2744 || enmFsTypeSnap == RTFSTYPE_XFS) 2745 && !mfSnapshotFolderExt4WarningShown) 2746 { 2747 setVMRuntimeErrorCallbackF(pVM, this, 0, 2748 "Ext4PartitionDetected", 2749 N_("The host I/O cache for at least one controller is disabled " 2750 "and the snapshot folder for this VM " 2751 "is located on an %s partition. There is a known Linux " 2752 "kernel bug which can lead to the corruption of the virtual " 2753 "disk image under these conditions.\n" 2754 "Either enable the host I/O cache permanently in the VM " 2755 "settings or put the disk image and the snapshot folder " 2756 "onto a different file system.\n" 2757 "The host I/O cache will now be enabled for this medium"), 2758 enmFsTypeSnap == RTFSTYPE_EXT4 ? "ext4" : "xfs"); 2759 fUseHostIOCache = true; 2760 mfSnapshotFolderExt4WarningShown = true; 2730 && fKernelHasODirectBug) 2731 { 2732 if ( enmFsTypeFile == RTFSTYPE_EXT4 2733 || enmFsTypeFile == RTFSTYPE_XFS) 2734 { 2735 setVMRuntimeErrorCallbackF(pVM, this, 0, 2736 "Ext4PartitionDetected", 2737 N_("The host I/O cache for at least one controller is disabled " 2738 "and the medium '%ls' for this VM " 2739 "is located on an %s partition. There is a known Linux " 2740 "kernel bug which can lead to the corruption of the virtual " 2741 "disk image under these conditions.\n" 2742 "Either enable the host I/O cache permanently in the VM " 2743 "settings or put the disk image and the snapshot folder " 2744 "onto a different file system.\n" 2745 "The host I/O cache will now be enabled for this medium"), 2746 strFile.raw(), enmFsTypeFile == RTFSTYPE_EXT4 ? "ext4" : "xfs"); 2747 fUseHostIOCache = true; 2748 } 2749 else if ( ( enmFsTypeSnap == RTFSTYPE_EXT4 2750 || enmFsTypeSnap == RTFSTYPE_XFS) 2751 && !mfSnapshotFolderExt4WarningShown) 2752 { 2753 setVMRuntimeErrorCallbackF(pVM, this, 0, 2754 "Ext4PartitionDetected", 2755 N_("The host I/O cache for at least one controller is disabled " 2756 "and the snapshot folder for this VM " 2757 "is located on an %s partition. There is a known Linux " 2758 "kernel bug which can lead to the corruption of the virtual " 2759 "disk image under these conditions.\n" 2760 "Either enable the host I/O cache permanently in the VM " 2761 "settings or put the disk image and the snapshot folder " 2762 "onto a different file system.\n" 2763 "The host I/O cache will now be enabled for this medium"), 2764 enmFsTypeSnap == RTFSTYPE_EXT4 ? "ext4" : "xfs"); 2765 fUseHostIOCache = true; 2766 mfSnapshotFolderExt4WarningShown = true; 2767 } 2761 2768 } 2762 2769 #endif
Note:
See TracChangeset
for help on using the changeset viewer.