borgbackupserver icon indicating copy to clipboard operation
borgbackupserver copied to clipboard

Login in WebUI not possible after update

Open Nodonn89 opened this issue 2 months ago • 2 comments

Description

I found another problem after updating my BBS-Server. You are not able to login in BBS on the devices, which were logged in by the browser, when the update was executed. I had this behaviour also on the past. Login in is possible with the same account in another browser, private tab/incognito tab or complete other devices. Cleaning cache of the browser for this bbs-website was at first not useful, later then it solved the problem.

Looks like that the new BBS version is not able to read the old session data when the login request is received.

Steps to Reproduce

  • Login into BBS WebUI

  • Stay logged in

  • Go to Portainer -> Stacks -> BBS-Server -> Editor

  • Click on the button "Update the stack"

  • Check "Re-pull image and redeploy"

  • After update done, try to login in BBS WebUI on the same browser as before

  • --> Nothing is done, login site refreshs and cleans textfields

  • Open Private Tab and login successfully in BBS WebUI

Installation Type

Docker

BBS Version

v2.96.5

Agent Version (if applicable)

v2.96.5

Agent OS (if applicable)

Ubuntu / Debian

Relevant Logs

Log from BBS-Server docker container, when a login attempt was done:
[Tue Sep 15 23:38:03.985561 2026] [php:warn] [pid 1234:tid 1234] [client 172.18.0.1:45734] PHP Warning:  session_start(): open(/var/bbs/tmp/sess_be33b896373739421894a4568dc21441, O_RDWR) failed: Permission denied (13) in /var/www/bbs/src/Core/App.php on line 37, referer: http://my-server:9090/login
[Tue Sep 15 23:38:03.985608 2026] [php:warn] [pid 1234:tid 1234] [client 172.18.0.1:45734] PHP Warning:  session_start(): Failed to read session data: files (path: ) in /var/www/bbs/src/Core/App.php on line 37, referer: http://my-server:9090/login
[Tue Sep 15 23:38:04.287497 2026] [php:warn] [pid 1234:tid 1234] [client 172.18.0.1:45734] PHP Warning:  session_regenerate_id(): Session ID cannot be regenerated when there is no active session in /var/www/bbs/src/Controllers/AuthController.php on line 109, referer: http://my-server:9090/login
172.18.0.1 - - [15/Sep/2026:23:38:03 +0200] "POST /login HTTP/1.1" 302 357 "http://my-server:9090/login" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:155.0) Gecko/20100101 Firefox/155.0"
[Tue Sep 15 23:38:04.295510 2026] [php:warn] [pid 1234:tid 1234] [client 172.18.0.1:45734] PHP Warning:  session_start(): open(/var/bbs/tmp/sess_be33b896373739421894a4568dc21441, O_RDWR) failed: Permission denied (13) in /var/www/bbs/src/Core/App.php on line 37, referer: http://my-server:9090/login
[Tue Sep 15 23:38:04.295526 2026] [php:warn] [pid 1234:tid 1234] [client 172.18.0.1:45734] PHP Warning:  session_start(): Failed to read session data: files (path: ) in /var/www/bbs/src/Core/App.php on line 37, referer: http://my-server:9090/login
172.18.0.1 - - [15/Sep/2026:23:38:04 +0200] "GET / HTTP/1.1" 302 361 "http://my-server:9090/login" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:155.0) Gecko/20100101 Firefox/155.0"
[Tue Sep 15 23:38:04.300986 2026] [php:warn] [pid 1234:tid 1234] [client 172.18.0.1:45734] PHP Warning:  session_start(): open(/var/bbs/tmp/sess_be33b896373739421894a4568dc21441, O_RDWR) failed: Permission denied (13) in /var/www/bbs/src/Core/App.php on line 37, referer: http://my-server:9090/login
[Tue Sep 15 23:38:04.301000 2026] [php:warn] [pid 1234:tid 1234] [client 172.18.0.1:45734] PHP Warning:  session_start(): Failed to read session data: files (path: ) in /var/www/bbs/src/Core/App.php on line 37, referer: http://my-server:9090/login
172.18.0.1 - - [15/Sep/2026:23:38:04 +0200] "GET /login HTTP/1.1" 200 5861 "http://my-server:9090/login" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:155.0) Gecko/20100101 Firefox/155.0"

Nodonn89 avatar Sep 15 '26 21:09 Nodonn89

Fixed in v2.96.6. Your log pinned it: session_start() got "Permission denied" reading the session file. PHP keeps sessions on the persisted volume, and when the container's app UID shifts across an update, the files the old www-data wrote (mode 600) are unreadable to the new one, so anyone already logged in is locked out until the cookie is cleared. The container now resets ownership of the session files to the current user on every start. Pull the v2.96.6 image and the login works again without clearing anything. Reproduced and confirmed the fix in a container. Thanks for the precise log.

marcpope avatar Sep 16 '26 02:09 marcpope

Fix works fine. Additional hint on login page also displayed for an expired session.

Nodonn89 avatar Sep 16 '26 16:09 Nodonn89