What causes slow start of session_start. It is very slow for PHP to start session_start for the first time. (Wait for several minutes) after the client generates PHPSESSID & nbsp; COOKIE, the access speed will return to normal. Why does it cause slow start of session_start when PHPSESSID & nbsp; is opened after the COOKIE is deleted.
It is very slow for PHP to start session_start for the first time. (Wait for several minutes)
After the client generates the phpsessid cookie, the access speed returns to normal.
After the phpsessid cookie is deleted, it becomes slow again. after the PHPSESSID is generated for the first time, it becomes normal again.
There are two lines of code:
Session_start ();
Phpinfo ();
?>
What causes the slow start of session_start for the first time?
I found many issues and found no reason ......
------ Solution --------------------
First time ???
Again?
------ Solution --------------------
I have never encountered it. I want to test it in a few more browsers.
------ Solution --------------------
4.6 min ?... Inniu's face ....
------ Solution --------------------
I don't know whether this article can solve your problem:
Http://www.myexception.cn/operating-system/501202.html
------ Solution --------------------
I don't know if it's correct to reference the manual.
Reference
There are some posts around und about session_start () beeing terribly slow on ntfs. for me the problem occured from one day to another, system was already running fine for 2 years.
To get around it implementing a custom session_set_save_handler cocould be an option, although for me it worked just to put a session_write_close () somewhere near the end of my script. (maybe IIS didn't kill the php-threads fast enough ?!)
------ Solution --------------------
In the continued manual, "slow" is related:
A note on Windows installations with an NTFS file structure:
Make sure you give your Internet user account (usually IUSR_MACHINENAME) "Modify" access to the session. save_path directory. Otherwise session_start () will silently-and oh, so slowly-fail.
("Modify" is a Win2k term, but the concept translates to older IIS instils ).
------ Solution --------------------
Reference:
It is very slow for PHP to start session_start for the first time. (Wait for several minutes)
After the client generates the phpsessid cookie, the access speed returns to normal.
After the phpsessid cookie is deleted, it becomes slow again. after the PHPSESSID is generated for the first time, it becomes normal again.
There are two lines of code:
Session_start ();
Phpinfo ();
?>
Yes ......
I tested the same code in linux.
Therefore, you should consider windows, not php.
------ Solution --------------------
If this problem occurs in linux, it is easy to install a mrtg to check the usage of CPU, IO, disk, memory, and so on, in this way, you can see through this value where this problem occurs.
------ Solution --------------------
Re-compile or change the version?