# MySQL server has gone away. Nextcloud ignoring database configuration in \`config.php\`

**URL:** <https://help.nextcloud.com/t/mysql-server-has-gone-away-nextcloud-ignoring-database-configuration-in-config-php/108533>\
**Category:** ℹ️ Support\
**Created:** [February 21, 2021, 12:41am UTC](https://help.nextcloud.com/t/mysql-server-has-gone-away-nextcloud-ignoring-database-configuration-in-config-php/108533 "2021-02-21T00:41:29Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![marcelrobitaille](https://help.nextcloud.com/letter_avatar/marcelrobitaille/32/6_22734026db12803ebb3e059622ac3534.png) [@marcelrobitaille](https://help.nextcloud.com/u/marcelrobitaille)\
**Post date:** [February 21, 2021, 10:27pm UTC](https://help.nextcloud.com/t/mysql-server-has-gone-away-nextcloud-ignoring-database-configuration-in-config-php/108533/6 "2021-02-21T22:27:14Z")

</div>

I solved it. It was a permission issue. The update changed the owner of `/etc/webapps/nextcloud` and `/var/lib/nextcloud` to `nextcloud:nextcloud` but php was running as `http`. This is one of the first things I tried, but I missed one directory so it still errored out so I assumed it was something else and went down a different path.

Once I fixed the owners, I moved `config.php` and nextcloud did its initial setup. I put in the database information, but the wizard failed because my user already exists (duh it’s an existing install that you borked). I went into `config.php` and added `'installed' => true` and everything works.

---

_[View the full topic](https://help.nextcloud.com/t/mysql-server-has-gone-away-nextcloud-ignoring-database-configuration-in-config-php/108533)._
