---
title: "[drupal]Boost - 为网站提供静态页面缓存的性能提升利器"
author: "alwarse"
date: "2016-07-01T14:51:14Z"
tags: ["Drupal"]
categories: ["互联网"]
slug: "drupal-boost"
draft: false
lastmod: "2016-07-01T14:51:14Z"
id: 2308582
url: "https://alwarse.iteye.com/blog/2308582"
---

Boost 模块为 Drupal 站点提供静态页面缓存，绕过PHP脚本执行和数据库请求，直接为匿名浏览用户提供静态缓存页面，使 Drupal 站点的性能得到非常显著的提升，使网站的可扩展性得到加强。

　　Boost 模块会为 Drupal 站点缓存及生成gzip压缩版本 html, xml, ajax, css, js 等文件，并可以在 apache, nginx,  lighttpd 和 iis7 等web服务器端运行。

　　以下是 Boost 模块工作流程的简介（附图）：

- Web 服务器端接收到网页浏览请求
- Web 服务器端对请求进行一些判断，决定如何向用户提供要展示的内容
- 如果没有缓存，则执行一系列PHP程序脚本及数据库请求，并将取得的数据返回给用户，并为页面生成缓存
- 如果有缓存，则根据用户浏览器的支持程度，向用户返回静态缓存页面或者压缩过的静态缓存页面

 

![Boost 模块执行流程](http://lugir.com/sites/default/files/u3-lugir/Boost.preview.png)

　　有关 boost 模块配置和使用，可参考：[http://lugir.com/drupal/documentation/using-boost.html](http://lugir.com/drupal/documentation/using-boost.html)

模块地址：[http://drupal.org/project/boost](http://drupal.org/project/boost)

内容分类: 

[Drupal](http://lugir.com/taxonomy/term/487)

Drupal 模块分类: 

[内容显示](http://lugir.com/taxonomy/term/498)

[性能与扩展](http://lugir.com/taxonomy/term/522)

[实用工具](http://lugir.com/taxonomy/term/536)