Kick User out before Backup starts ony ideas or not necessary [SOLVED]

as im going along to backup my NC some of the users are still logged in
when the script runs …

how do i kick those … “i dont wanna sleep usere” or afaik " i dont know how to correctly log out "
out of the system (log them off via bash script)
or is it enough to set NC to maint-mode

brNP

Hi,

There is a simple solution to this: switch maintenance mode on. You should always do this to also tell sync clients that sobering is going on.

php occ maintenance:mode --on
# backup
php occ maintenance:mode --off

Cheers
/S

oh yeah … was runnin this already
step-1 is on
step-5 is off

thanks for the hint !

grafik

As ususal this function is explained in the administrator guide:

https://docs.nextcloud.com/server/15/admin_manual/maintenance/backup.html#maintenance-mode

dont get me wrong but
where does the documetation point out that users will be logged off when switching to mMode
and then will be automatically logged in even when there is 2FA enabled?

as a matter of fact its pretty cool and usefull.
and makes the backup easier.
br NP

It isn’t written that the were logged-off nor that they will automatically be logged-in again.
Afaik, local cookies are used to store a valid session id. As long as this isn’t changing users can continue to use Nexcloud.

i can confirm thats cookie related.
tested it already.

wondering if i am missing an auto log off after a certain amount of time

Checkout the ‘remember_login_cookie_lifetime’ parameter, which is described in the documentation or use the search function of this forum to find related postings:

https://docs.nextcloud.com/server/19/admin_manual/search.html?q=lifetime&check_keywords=yes&area=default#

cool thx allready playin / testin it !
thx