M
M
mihmig2014-02-23 21:27:17
PHP
mihmig, 2014-02-23 21:27:17

Apache and mod_php - is the bytecode cached?

As far as I understand in cgi mode - the php script is translated (interpreted) every time the script is called (as if it were called from the command line). And in mod_php mode - how?
If apache "remembers" the result of the translation of the called php file (caches), then what happens when the php file is changed on disk?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
M
Max, 2014-02-23
@AloneCoder

It doesn't cache anything.

G
GHua, 2014-02-23
@GHua

I'll add @AloneCoder . There are eaccelerator, xcache, apc, opcache for this.

F
FacedSID, 2014-04-15
@FacedSID

If PHP is in mod_php mode, then the file is cached. Once a file is modified, nothing will happen until the cached file expires. Let's just say that the TTL for the cache costs 5 minutes, if you executed the file, it was cached, then you made changes, then these changes will take effect only after 5 minutes (from the moment the file is executed). You can force clean storage.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question