Settings.php in read only mode?
When does drupal settings.php become read-only?


Towards the end of the installation process, when the install scripts have finished writing all they need to write to the file.


  Why does it happen?


Because leaving that file writeable represents a security risk.


  How can I find the error causing this issue?


It's not an error, so there's no cause to find.