Nextcloud and timeout session

Hello everyone, for some time I have agreed that the authentic sessions after a certain period seem to go into time out. It had never happened to me so I ask for confirmation if there are parameters or if I have to investigate something else.

There are some parameters to configure session lifetime/timeout:
'remember_login_cookie_lifetime' => 60*60*24*15,

Lifetime of the remember login cookie. This should be larger than the session_lifetime. If it is set to 0 remember me is disabled.

Defaults to 60*60*24*15 seconds (15 days)

'session_lifetime' => 60 * 60 * 24,

The lifetime of a session after inactivity.

The maximum possible time is limited by the session.gc_maxlifetime php.ini setting which would overwrite this option if it is less than the value in the config.php

Defaults to 60*60*24 seconds (24 hours)

'session_relaxed_expiry' => false,

true enabled a relaxed session timeout, where the session timeout would no longer be handled by Nextcloud but by either the PHP garbage collection or the expiration of potential other session backends like redis.

This may lead to sessions being available for longer than what session_lifetime uses but comes with performance benefits as sessions are no longer a locking operation for concurrent requests.

'session_keepalive' => true,

Enable or disable session keep-alive when a user is logged in to the Web UI.

Enabling this sends a “heartbeat” to the server to keep it from timing out.

Defaults to true

'auto_logout' => false,

Enable or disable the automatic logout after session_lifetime, even if session keepalive is enabled. This will make sure that an inactive browser will be logged out even if requests to the server might extend the session lifetime.

https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/config_sample_php_parameters.html

2 Likes

Thank you very much , I guess these parameters had to be inserted in the php.ini . To be honest, I had only looked on the internet, leaving out the official documentation. Thank you for your suggestion . .