Answer the question
In order to leave comments, you need to log in
Why does the browser delete session cookies ahead of time?
There are two servers on one a.site.ru (FreeBSD) on the other b.site.ru (Ubuntu) Apache and PHP everywhere. On the first, the session cookie is placed in the browser on the site.ru domain; on the second, as it should be b.site.ru. On that and on another session.name identical. I tried logging in and out, deleting the cookie associated with the session and restarting the session with a new id. In order to check whether it crashes or is overwritten at this moment on another subdomain - it doesn’t crash anywhere, as it should be! But the fact is that I set the session for a week, and for me and for users, the session in the browser crashes every two days (although I checked it is set for a week). On the server, too, the session file is not deleted.
I thought that something was wrong with the settings in the browser, but on yandex.ru the session lives for weeks and is not killed.
What could be the reason, where to dig?..
Answer the question
In order to leave comments, you need to log in
I noticed that when you perform table replacement operations in MySQL (roughly speaking, of course), sessions sometimes crash (and usually this is a user table). This phenomenon has not been verified. There was also an option when the hoster limited the sessions (also did not go into details, but the sessions lasted 10 minutes and it infuriated everyone), since the whole thing stopped pretty soon, but this is not the topic. What am I... After all, there are 2 servers, maybe they import tables among themselves, which leads to the first case described by me
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question