V2Rebuilt from the ground up.

Error fix

Access is denied (os error 5)

Windows blocked Deadlock Mod Manager from changing a file in your Deadlock folder. It is almost always a read-only file, a security feature guarding the folder, or a mod that was installed with admin rights.

Deadlock Mod Manager on Windows
Access is denied. (os error 5)

How to fix it

Work through these in order. Most people are done after the first two.

  1. Close Deadlock and update the app

    Quit the game completely and make sure you're on the latest Deadlock Mod Manager. Then retry what failed before changing anything else.
  2. Clear the read-only flag

    Right-click game\citadel\gameinfo.gi, open Properties and untick Read-only. Do the same for the addons folder and apply it to all subfolders. From a terminal: attrib -r "…\Deadlock\game\citadel\*" /s /d
  3. Allow the app through Controlled folder access

    Windows Security > Virus & threat protection > Ransomware protection. If Controlled folder access is on, add Deadlock Mod Manager under Allow an app, or remove your Steam library from the protected folders. Other antivirus tools have a similar exclusion list.
  4. Remove mods installed as administrator

    Files created by an elevated program can't be changed by a normal one. Run Deadlock Mod Manager as administrator once, remove or reinstall the affected mods, then close it and start it normally again.
  5. Check the folder isn't in a protected location

    Steam libraries outside Program Files avoid most permission problems. If you moved Deadlock to a drive with custom permissions, give your Windows user Full control in the folder's Security tab.
  6. Verify game files as a last resort

    In Steam, right-click Deadlock > Properties > Installed Files > Verify integrity of game files. This restores gameinfo.gi; the app re-applies your mods the next time you launch modded.

Why it happens

To enable, disable or reorder mods, Deadlock Mod Manager renames .vpk files in the addons folder and edits gameinfo.gi so the game knows to load them. Windows returns error 5 when the file is marked read-only, when a security feature such as Controlled folder access guards the folder, or when the file belongs to an administrator account the app isn't running as.

If the error says the files are in use instead, that's a different problem: see Failed to save mod order. If launching fails with error 740, see os error 740.

Still stuck? The permission troubleshooting docs go further, and Discord can help if you share the app logs.

Questions

What does os error 5 mean in Deadlock Mod Manager?

It is the Windows error ERROR_ACCESS_DENIED. Windows refused to let the app write, rename or delete a file in your Deadlock folder, usually gameinfo.gi or a .vpk in the addons folder.

Should I always run Deadlock Mod Manager as administrator?

No. Run it as administrator once to clean up files that were created with admin rights, then go back to starting it normally. Running it elevated all the time makes every new mod file admin-owned and brings the error back the next time you start it normally.

Why do I get os error 5 when Deadlock is closed?

Something other than the game is blocking the file: the read-only attribute, Windows Security's Controlled folder access, another antivirus, or files left behind by a mod installed with admin rights.

Does os error 5 happen on Linux?

The Linux equivalent is Permission denied (os error 13). Make sure your user owns the Deadlock folder, and on Flatpak grant the app access to your Steam library as described in the troubleshooting docs.

Related guides

Mods without the file juggling

Deadlock Mod Manager installs, orders and re-applies your mods so you rarely have to touch the game folder yourself.