Restricts all write operations and forbids collection creation. This endpoint also returns previous lock options.