If when installing or updating a game on Steam displays one of these messages:
- "An error occurred while updating [game title] (disk write/read error)"
- "An error occurred while installing [game title] (disk write/read error)"
- "An error occurred while updating [game title] (content file locked)"
- A file Steam needs to access is locked and cannot be opened or edited. This usually happens when the game in question is currently running, or any of its files are opened on another program.
- File is opened for scanning or quarantined by your Anti Virus software by real time filesystem scanning. This is also known as a false positive.
- Close the game that fails to update with the error
- Usually restarting Steam or your PC helps too.
- Exclude game's or Steam's folders from your antivirus scans.
- Temporarily shutdown your antivirus completely.
Here's also an official Steam Support article about this issue: