Internal server error on login

Hi all,

this morning my nextcloud server does no longer allow logins.

In the logfile I was able to identify following information - which does not realy

What need I do to get rid of the error?

Thanks a lot!


{“reqId”:“gqGPEIV/ymPj3exryo8/”,“remoteAddr”:“”,“app”:“index”,“message”:“Exception: {“Exception”:“Exception”,“Message”:“Session has been closed - no further changes to the session are allowed”,“Code”:0,“Trace”:”#0 \/var\/www\/owncloud\/lib\/private\/Session\/Memory.php(52): OC\\Session\\Memory->validateSession()\n#1
\/var\/www\/owncloud\/lib\/private\/Security\/CSRF\/TokenStorage\/SessionStorage.php(63): OC\\Session\\Memory->set(‘requesttoken’, ‘PBG7u2zyAzx2BAI…’)\n#2 \/var\/www\/owncloud\/lib\/private\/Security\/CSRF\/CsrfTokenManager.php(57): OC\\Security\\CSRF\\TokenStorage\\SessionStorage->setToken(‘PBG7u2zyAzx2BAI…’)\n#3 \/var\/www\/owncloud\/lib\/public\/Util.php(505): OC\\Security\\CSRF\\CsrfTokenManager->getToken(*** sensitive parameters replaced ***)\n#4 \/var\/www\/owncloud\/lib\/private\/legacy\/template.php(79): OCP\\Util::callRegister()\n#5 \/var\/www\/owncloud\/lib\/base.php(396): OC_Template->__construct(’’, ‘update.admin’, ‘guest’)\n#6 \/var\/www\/owncloud\/lib\/base.php(338): OC::printUpgradePage()\n#7 \/var\/www\/owncloud\/lib\/base.php(841): OC::checkUpgrade(true)\n#8 \/var\/www\/owncloud\/index.php(54): OC::handleRequest()\n#9 {main}",“File”:"\/var\/www\/owncloud\/lib\/private\/Session\/Memory.php",“Line”:119}",“level”:3,“time”:“2016-11-28T09:04:53+00:00”,“method”:“GET”,“url”:"/owncloud/index.php",“user”:"–"}

Hi Peter,

Are all users affected by the login problems or only one or some users? Did you change something on the server? Have there been any updates, did the user change his password before this issue?
If possible, please provide further information, that could help to analyze this problem.

I find it hard to read such error messages as well, so I’m rather guessing and try to preclude probable issues:
do you run some kind anti brute force tool (fail2ban for example) which struck and blocks user connections?

Hi Schmu,

all users are effected.

  • There is no login possible in the web interface
  • desktop application on Ubuntu can’t connect anymore
  • mobile Apps on Android are no longer connected

without the web-interface I have to read the logfile in the data directory - the only significant information I - as a newbe found - is the entry posted in the topic of this thread.

It might have happen that an automatic update was running:
I found the maintenancemode parameter set to true (without having set it to this value manually). The parameter file shows the version set to ???
Where could I find information about an possible autupgrade?

To clarify the history: The stuff is running on Raspi 3 based on Jessie. I first installed owncloud 9.2 and upgraded to nextcloud 10.1.2 after reading details about the nextcloud fork.

The installation was running fine up to this morning.

Any hints?



Hi Peter,

If maintenance mode is still set to true, please set it to false. You can either use the occ command out change the value in the config.php and restart the webserver.
From what I know the maintenance mode prevents user logins to make sure no data is changed during maintenance.
This value could have been set during upgrade.

Hi Schmu,

I already did remove the maintenance flag, the log information listed is caused when trying to connect to the server using the web-interface after setting maintenancemode => false

because of the fact that maintenancemode was set to true this morning I assumed that an automatic update was running and did cause the situation.



I found the root cause of the problem!

The installation of my system was migrated from owncloud to nextcloud following this description.

The origin installation was performed using apt-get on a raspi3 box.
The owncloud installation package was not removed using the package manager. Yesterday evening a newer owncloud (9.1.2) package was amongst several other packages and was extracted into the 10.0.1 nextcloud directory structure.

Solution: 1. remove the owncloud package with package manager
2. download and extract nextcloud into the owncloud directory structure

kind regards


1 Like