Nextcloud 26 upgrade error: passwordHash is not a valid attribute

After upgrading to NC 26, after logging in, it showed Internal Server Error, and I saw in the nextcloud.log that prompted “passwordHash is not a valid attribute”. What’s wrong? and how can I fix it, please? Below are the detailed logs:

"exception":{"Exception":"BadFunctionCallException","Message":"passwordHash is not a valid attribute","Code":0,"Trace":[{"file":"/var/www/*/lib/public/AppFramework/Db/Entity.php","line":165,"function":"setter","class":"OCP\\AppFramework\\Db\\Entity","type":"->"},{"file":"/var/www/*/lib/public/AppFramework/Db/Entity.php","line":73,"function":"__call","class":"OCP\\AppFramework\\Db\\Entity","type":"->"},{"file":"/var/www/*/lib/private/Authentication/Token/PublicKeyTokenMapper.php","line":91,"function":"fromRow","class":"OCP\\AppFramework\\Db\\Entity","type":"::"},{"file":"/var/www/*/lib/private/Authentication/Token/PublicKeyTokenProvider.php","line":119,"function":"getToken","class":"OC\\Authentication\\Token\\PublicKeyTokenMapper","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/*/lib/private/Authentication/Token/Manager.php","line":133,"function":"getToken","class":"OC\\Authentication\\Token\\PublicKeyTokenProvider","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/*/lib/private/User/Session.php","line":777,"function":"getToken","class":"OC\\Authentication\\Token\\Manager","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/*/lib/private/User/Session.php","line":257,"function":"validateToken","class":"OC\\User\\Session","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/*/lib/private/User/Session.php","line":232,"function":"validateSession","class":"OC\\User\\Session","type":"->"},{"file":"/var/www/*/lib/private/legacy/OC_App.php","line":391,"function":"getUser","class":"OC\\User\\Session","type":"->"},{"file":"/var/www/*/lib/private/legacy/OC_App.php","line":123,"function":"getEnabledApps","class":"OC_App","type":"::"},{"file":"/var/www/*/lib/private/legacy/OC_User.php","line":127,"function":"loadApps","class":"OC_App","type":"::"},{"file":"/var/www/*/lib/base.php","line":741,"function":"setupBackends","class":"OC_User","type":"::"},{"file":"/var/www/*/lib/base.php","line":1144,"function":"init","class":"OC","type":"::"},{"file":"/var/www/*/index.php","line":34,"args":["/var/www/*/lib/base.php"],"function":"require_once"}],"File":"/var/www/*/lib/public/AppFramework/Db/Entity.php","Line":136,"CustomMessage":"--"}}

Did you clear the cache of your browser after Update?
Did you reboot Your system after Update?

After both, it should work…

Thank you, I did that and it worked.

1 Like

I have hard reloaded the page and used sudo -u www-data php occ maintenance:repair, then rebooted the system. Keep getting the same message:

{"reqId":"DuUF68Hvvijn0CsJiO9N","level":3,"time":"2024-04-13T12:59:15+00:00","remoteAddr":"192.168.1.71","user":"admin","app":"index","method":"POST","url":"/nextcloud/index.php/login","message":"passwordHash is not a valid attribute","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/123.0.0.0 Safari/537.36","version":"23.0.2.1","exception":{"Exception":"BadFunctionCallException","Message":"passwordHash is not a valid attribute","Code":0,"Trace":[{"file":"/var/www/nextcloud/lib/public/AppFramework/Db/Entity.php","line":158,"function":"setter","class":"OCP\\AppFramework\\Db\\Entity","type":"->"},{"file":"/var/www/nextcloud/lib/public/AppFramework/Db/Entity.php","line":73,"function":"__call","class":"OCP\\AppFramework\\Db\\Entity","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Token/PublicKeyTokenMapper.php","line":138,"function":"fromRow","class":"OCP\\AppFramework\\Db\\Entity","type":"::"},{"function":"OC\\Authentication\\Token\\{closure}","class":"OC\\Authentication\\Token\\PublicKeyTokenMapper","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/nextcloud/lib/private/Authentication/Token/PublicKeyTokenMapper.php","line":137,"function":"array_map"},{"file":"/var/www/nextcloud/lib/private/Authentication/Token/PublicKeyTokenProvider.php","line":421,"function":"getTokenByUser","class":"OC\\Authentication\\Token\\PublicKeyTokenMapper","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/nextcloud/lib/private/Authentication/Token/Manager.php","line":272,"function":"updatePasswords","class":"OC\\Authentication\\Token\\PublicKeyTokenProvider","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/nextcloud/lib/private/Authentication/Listeners/UserLoggedInListener.php","line":61,"function":"updatePasswords","class":"OC\\Authentication\\Token\\Manager","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/nextcloud/lib/private/EventDispatcher/ServiceEventListener.php","line":87,"function":"handle","class":"OC\\Authentication\\Listeners\\UserLoggedInListener","type":"->"},{"file":"/var/www/nextcloud/3rdparty/symfony/event-dispatcher/EventDispatcher.php","line":251,"function":"__invoke","class":"OC\\EventDispatcher\\ServiceEventListener","type":"->"},{"file":"/var/www/nextcloud/3rdparty/symfony/event-dispatcher/EventDispatcher.php","line":73,"function":"callListeners","class":"Symfony\\Component\\EventDispatcher\\EventDispatcher","type":"->"},{"file":"/var/www/nextcloud/lib/private/EventDispatcher/EventDispatcher.php","line":88,"function":"dispatch","class":"Symfony\\Component\\EventDispatcher\\EventDispatcher","type":"->"},{"file":"/var/www/nextcloud/lib/private/EventDispatcher/EventDispatcher.php","line":100,"function":"dispatch","class":"OC\\EventDispatcher\\EventDispatcher","type":"->"},{"file":"/var/www/nextcloud/lib/private/User/Session.php","line":402,"function":"dispatchTyped","class":"OC\\EventDispatcher\\EventDispatcher","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/CompleteLoginCommand.php","line":44,"function":"completeLogin","class":"OC\\User\\Session","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/ALoginCommand.php","line":40,"function":"process","class":"OC\\Authentication\\Login\\CompleteLoginCommand","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/LoggedInCheckCommand.php","line":60,"function":"processNextOrFinishSuccessfully","class":"OC\\Authentication\\Login\\ALoginCommand","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/ALoginCommand.php","line":40,"function":"process","class":"OC\\Authentication\\Login\\LoggedInCheckCommand","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/EmailLoginCommand.php","line":58,"function":"processNextOrFinishSuccessfully","class":"OC\\Authentication\\Login\\ALoginCommand","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/ALoginCommand.php","line":40,"function":"process","class":"OC\\Authentication\\Login\\EmailLoginCommand","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/UidLoginCommand.php","line":54,"function":"processNextOrFinishSuccessfully","class":"OC\\Authentication\\Login\\ALoginCommand","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/ALoginCommand.php","line":40,"function":"process","class":"OC\\Authentication\\Login\\UidLoginCommand","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/UserDisabledCheckCommand.php","line":58,"function":"processNextOrFinishSuccessfully","class":"OC\\Authentication\\Login\\ALoginCommand","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/ALoginCommand.php","line":40,"function":"process","class":"OC\\Authentication\\Login\\UserDisabledCheckCommand","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/PreLoginHookCommand.php","line":53,"function":"processNextOrFinishSuccessfully","class":"OC\\Authentication\\Login\\ALoginCommand","type":"->"},{"file":"/var/www/nextcloud/lib/private/Authentication/Login/Chain.php","line":108,"function":"process","class":"OC\\Authentication\\Login\\PreLoginHookCommand","type":"->"},{"file":"/var/www/nextcloud/core/Controller/LoginController.php","line":329,"function":"process","class":"OC\\Authentication\\Login\\Chain","type":"->"},{"file":"/var/www/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":217,"function":"tryLogin","class":"OC\\Core\\Controller\\LoginController","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":126,"function":"executeController","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->"},{"file":"/var/www/nextcloud/lib/private/AppFramework/App.php","line":157,"function":"dispatch","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->"},{"file":"/var/www/nextcloud/lib/private/Route/Router.php","line":302,"function":"main","class":"OC\\AppFramework\\App","type":"::"},{"file":"/var/www/nextcloud/lib/base.php","line":1006,"function":"match","class":"OC\\Route\\Router","type":"->"},{"file":"/var/www/nextcloud/index.php","line":36,"function":"handleRequest","class":"OC","type":"::"}],"File":"/var/www/nextcloud/lib/public/AppFramework/Db/Entity.php","Line":129,"CustomMessage":"--"}}                                                                                                       1Help            2UnWrap          3Quit            4Hex             5Goto

I also tried to reset the password via CLI