| Previous | Next |
| STATUS_DEVICE_NOT_PARTITIONED | STATUS_UNABLE_TO_UNLOAD_MEDIA |
STATUS_UNABLE_TO_LOCK_MEDIA
The device could not lock its media-ejection mechanism
Tape and removable-media devices can expose a command that prevents accidental ejection while an operation is active. This status means the lock request failed, possibly because the device lacks the feature, the door or tray state is incompatible, another owner controls it, or hardware did not complete the command.
Do not proceed with a destructive or long-running job if unexpected removal would be unsafe. Query device capabilities and current state, then resolve ownership or mechanical problems. Repeating the lock without checking support can leave software believing the medium is protected when it is not.
What to inspect
- Confirm that the drive reports lock and unlock capability.
- Check tray, door, media, reservation, and other-owner state.
- Require a successful lock or an explicit safe fallback before critical writes.
References
- Microsoft: TAPE_PREPARE
- Microsoft: GET_CHANGER_PARAMETERS
- Microsoft Open Specifications: NTSTATUS values
Looking for a different code? Search another status or error code.