# Cannot login after PHP upgrade to 7.2

**URL:** <https://help.nextcloud.com/t/cannot-login-after-php-upgrade-to-7-2/56950>\
**Category:** ℹ️ Support\
**Tags:** centos, nc16, php72\
**Created:** [July 20, 2019, 3:24pm UTC](https://help.nextcloud.com/t/cannot-login-after-php-upgrade-to-7-2/56950 "2019-07-20T15:24:31Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Simon\_Parzer](https://help.nextcloud.com/user_avatar/help.nextcloud.com/simon_parzer/32/16611_2.png) [@Simon\_Parzer](https://help.nextcloud.com/u/Simon_Parzer)\
**Post date:** [July 20, 2019, 3:52pm UTC](https://help.nextcloud.com/t/cannot-login-after-php-upgrade-to-7-2/56950/2 "2019-07-20T15:52:13Z")

</div>

Looks like this is the same issue: [Nextcloud 16.0.1 Login Loop on Install](https://help.nextcloud.com/t/nextcloud-16-0-1-login-loop-on-install/53959)  
The PHP upgrade changed the owner of /var/lib/php/session/ to root:apache, I changed it back to nginx by `sudo chgrp -R nginx /var/lib/php/session`, then restarted through `sudo systemctl restart php-fpm`, now login works again!

---

_[View the full topic](https://help.nextcloud.com/t/cannot-login-after-php-upgrade-to-7-2/56950)._
