<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">Am 14.02.2017 um 20:10 schrieb Ebayer Ebayer <<a href="mailto:ebaystardust@gmail.com" class="">ebaystardust@gmail.com</a>>:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">Hi,<div class=""><br class=""></div><div class="">I have Nginx running as a webserver (not as proxy). I need to cache static files that are under /var/www/html/images in memory. What's the simplest way to do this?</div></div></div></blockquote><br class=""></div><div><br class=""></div><div><br class=""></div><div>Your OS does that for you.</div><div><br class=""></div><div>That’s why it does not make sense to cache it again and why there’s no point in running varnish on local files.</div><div><br class=""></div><div>AFAIK, you can get a speed-increase if you have either FreeBSD+ZFS+AIO compiled into NGINX or FreeBSD 11 + nginx 1.11, which uses a special sendfile implementation to maximize deliver-speed of local files.</div><div><br class=""></div><div><a href="https://www.nginx.com/blog/nginx-and-netflix-contribute-new-sendfile2-to-freebsd/" class="">https://www.nginx.com/blog/nginx-and-netflix-contribute-new-sendfile2-to-freebsd/</a></div><div><br class=""></div><div><br class=""></div><div>Also take a look at</div><div><br class=""></div><div><a href="https://calomel.org/nginx.html" class="">https://calomel.org/nginx.html</a></div><div><br class=""></div><div><br class=""></div><div><br class=""></div><div><br class=""></div><div>Rainer</div><div><br class=""></div><br class=""></body></html>