<-
Apache > HTTP Server > Documentation > Version 2.4 >

ġ mod_file_cache

ֽ ƴմϴ. ֱٿ ϼ.
:޸𸮿 ϵ ij
:Experimental
:file_cache_module
ҽ:mod_file_cache.c

ؼ ؾ Ѵ. mod_file_cache Ͽ Ʈ ⶧ IJ б ٶ.

ʰ ûǴ ij Ͽ ϸ ִ. mod_file_cache ûǴ ΰ ij Ѵ. þ Ͽ mod_file_cache (open) mmap() ƴϸ ڵ Ѵ. ϱ ʿ ۾ Ϻθ (Ư ۾) û Ź ϴ Ҷ ѹ Ͽ ϰ Ѵ.

: CGI α׷̳ Ư ڵ鷯 ϴ ӵ . ġ core ڵ鷯 ϴ ϹϿ ȴ.

ġ 1.3 ִ mod_mmap_static Ȯ .

Support Apache!

þ

Bugfix checklist

top

mod_file_cache ϱ

mod_file_cache ּ MMapFile CacheFile þ Ͽ ϵ ij Ѵ.

÷ þ ϴ ƴϴ. , ġ MMapStatic þ , AIX ٸ ÷ θ Ѵ. ʴ þ α׿ . ʴ þ ص ij ʴ´. þ ϴ ÷ Ѵٸ  غ.

MMapFile þ

mod_file_cache MMapFile þ ϵ mmap() ýȣ Ͽ ޸𸮿 Ѵ. ֽ н ü ýȣ , ü ִ. , mmap() ִ ũ ý Ƿ ̸ غ .

Ҷ Ҷ mmap()Ѵ. ׷ Ͻýۿ ش ϳ Ǹ ؾ Ѵ (ߴܰ ). ٽ ؼ Ǿµ ̻ϰ û 𸥴. (unlink) ڸ ο ؾ Ѵ. rdist mv ټ ̷ Ѵ. Ź ߰ ʿ stat() ˻簡 ʿϰ Ҷ ǵ ϱ⶧ ȭ Ѵ.

CacheFile þ

mod_file_cache CacheFile þ þ ( ϵ)  ڵ(handle) Ȥ (file descriptor) ij Ѵ. ûϸ ij ڵ ãƼ API sendfile() ( TransmitFile()) ѱ.

Ҷ Ҷ ڵ ijѴ. ׷ Ͻýۿ ij ϳ Ǹ ؾ Ѵ (ߴܰ ). ٽ ؼ Ǿµ ̻ϰ û 𸥴. (unlink) ڸ ο ؾ Ѵ. rdist mv ټ ̷ Ѵ.

丮 ij ϴ þ . غ... Include þ Ͽ ɾ Ѵ:

find /www/htdocs -type f -print \
| sed -e 's/.*/mmapfile &/' > /www/conf/mmap.conf

top

CacheFile þ

:۽ ڵ ijѴ
:CacheFile file-path [file-path] ...
:ּ
:Experimental
:mod_file_cache

CacheFile þ Ҷ (open) ϵ ڵ ij Ѵ. ڵ ij ڵ ݴ´(close). Ͻýۿ Ǹ ٽ ijϱ ؾ Ѵ.

file-path ƱԸƮ ض. ƱԸƮ ġ URL-ϸ ȯ ڵ鷯 Ͻý ο Ȯ ġؾ Ѵ. ѹ ʿ stat() ýȣ ʿϱ⶧ inode ɺũ θ . mod_alias mod_rewrite ۼ ϸ ٷ ֱ⵵ ⵵ ϴ.

CacheFile /usr/local/apache/htdocs/index.html

top

MMapFile þ

:۽ ޸𸮿 Ѵ
:MMapFile file-path [file-path] ...
:ּ
:Experimental
:mod_file_cache

MMapFile þ Ҷ ( ƱԸƮ ) ޸𸮿 Ѵ(map). ڵ Ǭ(unmap). Ͻýۿ Ǹ ϵ ٽ mmap()ϱ ּ HUP̳ USR1 ñ׳ Ѵ.

file-path ƱԸƮ ض. ƱԸƮ ġ URL-ϸ ȯ ڵ鷯 Ͻý ο Ȯ ġؾ Ѵ. ѹ ʿ stat() ýȣ ʿϱ⶧ inode ɺũ θ . mod_alias mod_rewrite ۼ ϸ ٷ ֱ⵵ ⵵ ϴ.

MMapFile /usr/local/apache/htdocs/index.html

:  en  |  fr  |  ko 

top

Comments

Notice:
This is not a Q&A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Libera.chat, or sent to our mailing lists.
  翻译: