| Previous | Next |
| ERROR_UNEXPECTED_MM_CREATE_ERR | ERROR_UNEXPECTED_MM_EXTEND_ERR |
ERROR_UNEXPECTED_MM_MAP_ERROR
What ERROR_UNEXPECTED_MM_MAP_ERROR means
The failure occurs after or during establishment of a virtual-memory view. It is not a normal indication that a preferred address was unavailable; the operating system could not complete the mapping because an internal or backing-store condition was inconsistent.
Where it commonly appears
- MapViewOfFile and image-loader paths
- Shared-memory initialization
- Database and cache engines that map large files
- Processes affected by storage or filter-driver faults
Likely causes
- The mapped file changed size or metadata at the wrong time
- A section object or handle was invalidated by concurrent teardown
- A filter driver interfered with paging I/O
- Corrupt system state, storage, or memory caused an internal mapping failure
Troubleshooting checklist
- Log the mapping offset, length, desired address, protection, and file identity
- Verify alignment requirements and ensure the backing file is not truncated concurrently
- Check whether the same file maps successfully after copying it to a local healthy volume
- Review crash dumps and event logs for memory-manager or disk warnings
- Disable only recently introduced filter components in a controlled test environment
Guidance for developers
Close any partially created handles and do not use the requested address range after failure. Preserve both the Win32 error and the originating API. A retry is reasonable only after the backing file and object lifetime are known to be stable.
Guidance for administrators
Correlate the event with disk, antivirus, backup, encryption, and file-system activity. Repeated system-wide occurrences are a platform-health issue and should not be treated as an application-only defect.
Example
A content service maps a package while an updater replaces it in place. The file identity and size change during section setup, producing an unexpected mapping error. Publishing by atomic rename instead of in-place mutation removes the race.
Related conditions
Do not confuse this with ERROR_INVALID_ADDRESS, which commonly describes an unsuitable requested address, or ERROR_MAPPED_ALIGNMENT, which describes an alignment problem.
References
Looking for a different code? Search another status or error code.