In my case, resetting the permissions on the file itself did not help as when the file gets renamed to be ".old", the new version does not have permissions to be created. It is therefore critical that the permissions be set on the folder.
I received this error after a clean install of WSUS because there was no ownership or permissions on the file: C:\Program Files\Update Services\LogFiles\SoftwareDistribution.log. I took ownership of the file with the currently logged in user, set it to inherit permissions from the parent folder and the problem was solved.