Tried doing a clean installation and I'm right back to square one with the same error message. It is still only showing version 3.4.2 even after using a clean install of 3.5.1. The only directories which was not deleted was cgi bin and directories for 2 subdomains which were both empty.
Not making any progress...right back to square one.