亚洲国产日韩欧美一区二区三区,精品亚洲国产成人av在线,国产99视频精品免视看7,99国产精品久久久久久久成人热,欧美日韩亚洲国产综合乱

Nginx or php-fpm code file cache
伊謝爾倫
伊謝爾倫 2017-05-16 17:14:57
0
3
1005

Problems I encountered:

Nginx configurationAThe root directory of the project is a, and the a directory is soft linked to a1.
Later, after new code is released, a2 at the same level as a1 will be generated. The a directory also points to a2, but when accessing A# During the ## project, the code running result of a1 is still running. In theory, the code a2 should be executed at this time. Even after deleting the
a1 directory, the error message is still that some part of the code in the a1 directory is incorrect.

I suspect it’s

Nginx or php-fpm caching the code files?
OPCache, or Nginx, is there a configuration problem with php-fpm? Please ask God for answers.

伊謝爾倫
伊謝爾倫

小伙看你根骨奇佳,潛力無限,來學(xué)PHP伐。

reply all(3)
洪濤

Based on your description, I guess the problem lies in the fact that the opcache上。
這里nginx應(yīng)該是把目錄a作為路徑傳遞到了php-fpm中(通常的配置是這樣的),
opcache也是以路徑作為緩存代碼的Key,
所以說雖然軟連接指向的目錄改變了,但是opcacherecognized directories are the same, so the directly cached files are used.

It is recommended not to turn on code caching in the development environment, because currently opcacheit is not possible to check whether the file is updated every time. It can only be updated through functions or configuring the update time.

大家講道理

Configuration in php.ini:

opcache.validate_timestamps=1
opcache.revalidate_freq=0

opcache will verify the modification timestamp of the PHP file every time. If the PHP file has been modified, opcache will re-cache the new PHP file opcode into the memory.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template