Installation & Settings 6.x-1.0

This page is a walk-through of the 6.x-1.0 settings pages. The 6.x-1.1 release is laid out differently.See Next Page

Contents

Steps to install

  1. Download Boost and unzip the module on your computer.
  2. FTP or upload the module folder and all it's contents(as is) to sites/all/modules
  3. Goto: Administer > Site configuration > Clean URLs
    system path admin/settings/clean-urls
    Ensure that Drupal's clean URLs are enabled and working correctly.
  4. Goto: Administer > Site building > Modules
    system path admin/build/modules/list
    Enable the Boost module in the Caching section.
  5. Save the settings to install (updates the database)
    After saving the settings, there will be a link at the top of the module page directing you to the performance settings, or follow the next step.

Back to top

Performance Settings [tab]

  • Goto: Administer > Site configuration > Performance
    system path admin/settings/performance

Anonymous page caching

Enabling the page cache will offer a significant performance boost. Drupal can store and send compressed cached pages requested by anonymous users. By caching the first request to the page, Drupal does not have to construct the page each time it is viewed. The page must first be visited by an anonymous user in order for the cache to work on subsequent requests for that page. Boost & Core caching do not work for logged in users

  • Gzip page compression (radio buttons) Default is Enabled.
    [  ] Disabled
    [x] Enabled
  • By default, Drupal compresses the pages it caches in order to save bandwidth and improve download times. This option should be disabled when using a web server that performs compression.

 

Boost File Cache

Static page caching is a mechanism that stores dynamically generated web pages as HTML files in a special cache directory located under the Drupal installation directory. By caching a web page in this manner, the web server can serve it out in the fastest possible manner, without invoking PHP or Drupal at all. While this does provide a significant performance and scalability boost, you should note that it could have negative usability side-effects unless your site is targeted at an audience consisting mostly of "anonymous" visitors.

Preemptive cache check boxes on the performance page are not functional until the cron crawler in enabled on the performance/boost page and the settings have been saved.

  • Boost - Static page cache: Choose Enabled for Boost to work.
    [  ] Disabled
    [x] Enabled
    [  ] (Not Recommended) Set Boost & Core (if enabled) cache for each page
  • Boost - HTML - Default minimum cache lifetime:
    [1 Hour] (select)
  • Default is 1 hour and can be increased for sites that do not change very much. The minimum cache lifetime is the minimum amount of time that will elapse before the cache is emptied. Cache lifetime gets checked on cron runs.
  • [x] Preemptive Cache HTML
  • Crawl Site after cron runs, so the cache is primed.
  • Boost - XML - Default minimum cache lifetime:
    [1 hour] (select)
  • The minimum cache lifetime is the minimum amount of time that will elapse before the cache is emptied. Cache lifetime gets checked on cron runs.
  • [x] Preemptive Cache XML
  • Crawl Site after cron runs, so the cache is primed.
  • Boost - JSON - Default minimum cache lifetime:
    [1 hour] (select)
  • The minimum cache lifetime is the minimum amount of time that will elapse before the cache is emptied. Cache lifetime gets checked on cron runs.
  • [x] Preemptive Cache AJAX/JSON
  • Crawl Site after cron runs, so the cache is primed.
  • [Clear ALL Boost cached data: (20) pages](button)
  • Clears the cache of all pages currently in the cache files. Great for seeing current changes when working on the site or after adding content. Visitors will see changes immediately without waiting on a cron run to clean the cache and regenerate the pages.
  • [Clear Boost expired data: (15) pages](button)
  • Clears all pages that are past the cache lifetime. You may have been logged in during the cron run and nothing was cleared due to being logged in. It's like a manual cron run.

Core Database Cache

On high-traffic sites, it may be necessary to enforce a minimum cache lifetime. The minimum cache lifetime is the minimum amount of time that will elapse before the cache is emptied and recreated, and is applied to both page and block caches. A larger minimum cache lifetime offers better performance, but users will not see new content for a longer period of time.

  • [x] Core - Database page cache: Normal is recommended.
  • Core - Default minimum cache lifetime:
    [<none>] (select) none is fine for small sites.
  • This is the length of time before a page expires or is ready to be cleared by Boost on the next cron run.
  • [Clear core page cached data: (0) pages] (Button)

Block cache

Enabling the block cache can offer a performance increase for all users by preventing blocks from being reconstructed on each page load. If the page cache is also enabled, performance increases from enabling the block cache will mainly benefit authenticated users.

  • [x] Block cache: Enabled is Recommended if installed blocks allow it.
  • Note that block caching is inactive when modules defining content access restrictions are enabled.

Bandwidth optimizations

Drupal can automatically optimize external resources like CSS and JavaScript, which can reduce both the size and number of requests made to your website. CSS files can be aggregated and compressed into a single file, while JavaScript files are aggregated (but not compressed). These optional optimizations may reduce server load, bandwidth requirements, and page loading times.

These options are disabled if you have not set up your files directory, or if your download method is set to private.

  • [x] Optimize CSS files: (Enabled is recommended).
  • This option can interfere with theme development and should only be enabled in a production environment.
  • [x] Optimize JavaScript files: (Enabled is recommended).
  • This option can interfere with module development and should only be enabled in a production environment.

Clear cached data

Caching data improves performance, but may cause problems while troubleshooting new modules, themes, or translations, if outdated information has been cached. To refresh all cached data on your site, click the button below. Warning: high-traffic sites will experience performance slowdowns while cached data is rebuilt.

  • [Clear cached data] (button)
  • Clears the cache in the database (does not effect Boost).

[Save configuration] (button)   [Reset to Defaults] (button)

Back to top

Performance / Boost Settings [tab]

  • Goto: Administer > Site configuration > Performance > Boost
    system path admin/settings/performance/boost

Boost cacheability settings

  • [x] Cache pages that contain URL Variables
  • Boost will cache pages that end with ?page=1 among others. (anything with a "?" in the url)
  • [x] Cache html documents/pages
  • Boost will cache most Drupal pages.
  • [x] Cache .xml & /feed
  • Boost will cache .xml and /feed urls as xml data.
  • [x] Cache ajax/json
  • Boost will cache ajax/json responces.
  • [x] Cache .css
  • Boost will cache CSS files.
  • [x] Cache .js
  • Boost will cache javascript files.
  • Statically cache specific pages: (radio buttons).
    (x) Cache every page except the listed pages
    ( ) Cache only the listed pages
    ( ) Cache pages for which the following PHP code returns TRUE (PHP-mode, experts only).
    Pages:
    [ text box ] This is a standard Drupal type of setting.
  • Enter one page per line as Drupal paths. The '*' character is a wild-card. Example paths are 'blog' for the blog page and blog/* for every personal blog. is the front page.If the PHP-mode is chosen, enter PHP code between <?php and ?>. Note that executing incorrect PHP-code can severely break your Drupal site.

Back to top

Boost advanced settings

  • Clear expired pages on cron runs: (radio buttons).
    (  ) Disabled
    (x) Enabled
  • Caution - If disabled you will need some other method of clearing cached pages. If Disabled, files have to be manually deleted from server or cleared using the administrative interface (Enable the Boost: Pages cache status block).
  • [x] Check database timestamps for any site changes. Only if there's been a change will boost flush the expired content on cron.
  • Pre-process function:
    [ < c o d e > ]
  • The name of a PHP function used to pre-process the contents of each page before writing them out to static files. The function is called with the contents of the page passed as a string argument, and its return value is used as the data written out to the disk. (It is rare that anyone will need this)
  • [x] Only allow ASCII characters in path.
  • Only allowing ACSII characters is a safe way to cache pages. It severely limits i18n support so this can be turned off. Fair warning, disabling this may cause "page not found" errors depending on your url structure (spaces are bad, ect...). If you follow RFC 3986 you should be ok.
  • [x] Clear all empty folders from cache.
  • Disable this if you have to set settings for each dir/subdir, due to the way your server operates (permissions, etc...).
  • [x] Clear all cached terms pages associated with a node on insert/update/delete
  • Works with view's taxonomy/term/% path as well as core.
  • [x] Clear Boosts cache when site goes offline.
  • Under site maintenance when the status is set to offline, boost clears its cache. If you do not want this to happen, clear this checkbox. Pages that are not cached will still send out a Site off-line message, so be smart if turning this off.
  • [  ] Overwrite the cached file if it already exits.
  • This is useful if crawling a site before it goes live.
  • [  ] Do not cache if error on page.
  • Selected - Do not cache the page if there are PHP errors or drupal messages. Not Selected - Cache pages even if it might contain errors.
  • [  ] Turn off clean URLs for logged in users.
  • Drupal will output non clean URLs for non anonymous users. This allows for the browser to cache the page and still have logging in work. This is more on the extreme side of tweaks.
  • [  ] Aggressive Gzip: Deliver gzipped content independent of the request header.
  • In order to deliver gzipped content independent of the header, this will test for gzip compression in a small iframe by sending it compressed content. This compressed content is javascript which creates a cookie with a note of gzip support. On the server side it checks for the cookie and then sends out gzipped content accordingly. See Website Performance - Activate Gzip. In short some firewalls/proxies mangle the gzip header; this gets around that. iframe is on non compressed version of the frontpage only.
  • Files: Enter in a 4 digit number (octal) that will be used by chmod(). Example 0664:
    [ _______ ]
  • Sometimes because of funky servers you need it use a different file mode then the default.
  • Directories: Enter in a 4 digit number (octal) that will be used by chmod(). Example 0775:
    [ _______ ]
  • Sometimes because of funky servers you need it use a different file mode then the default.
  • Ignore cache flushing:
    [x] Disabled
    [  ] Only Ignore Clear Entire Cache Commands (Recommended if caching css/js files)
    [  ] Ignore Clear Entire Cache Commands & Cron Expiration
    [  ] Ignore All Delete Commands (Not Recommended)
  • Make a selection to put your site into a static cached state. It is Recommend to turn on CSS & JS caching if one of these are selected. If you do NOT want the cache cleared completely choose the first selection.
  • Watchdog Verbose Setting:
  • This sets the amount of errors recorded to watchdog(DbLog) when a static state is selected.

Back to top

Boost directories and file extensions

  • Cache Dir: *
    [ cache ]
  • This is the default directory that will hold the cached files or pages.
  • [  ] Do not store the cache file path in the database
  • Enabling will allow for correct multi-site caching, in cases where different content is served from the same Drupal installation, based on domain. Examples: Multi-site with a single/shared database, site translation detection based on domain, and the contributed "Domain Access" module.
  • Cache file path: *
    [ cache/www. example.com ]
  • A file system path where the static cache files will be stored. This directory has to exist and be writable by Drupal. The default setting is to store the files in a directory named cache/localhost/drupal-6.13-2 under the Drupal installation directory. If you change this, you must also change the URL rewrite rules in your web server configuration (.htaccess for Apache, lighttpd.conf for Lighttpd), or caching will not work.

Generated output storage (HTML, XML, AJAX) -expandable section-

  • Dir for non compressed files:
    [ _______ ]
  • Leave blank to not use a subdir
  • Dir for compressed files:
    [ gz _____ ]
  • Leave blank to not use a subdir
  • Character used to replace "?": *
    [ _ ____ ]
  • Best to leave at _
  • Cache html file extension: *
    [ .html _ ]
  • The file extension to append to the file name of the generated cache files. Note that this setting is of no relevance to any public URLs, and it is strongly recommended to leave this as the default '.html' unless you know what you are doing. If you change this, you must also change the URL rewrite rules in your web server configuration (.htaccess for Apache, lighttpd.conf for Lighttpd), or caching will not work.

Static storage (CSS, JS) -expandable section-

  • Dir for more permanent files (css/js):
    [ _______ ]
  • Leave blank to not use a subdir
  • Dir for compressed more permanent files (css/js):
    [ gz _____ ]
  • Leave blank to not use a subdir
  • Character used to replace "?" in the permanent dir: *
    [ _ _____ ]
  • Best to leave at _
  • Cache css file extension: *
    [ .css ___ ]
  • The file extension to append to the file name of the generated cache files. Note that this setting is of no relevance to any public URLs, and it is strongly recommended to leave this as the default '.css' unless you know what you are doing. If you change this, you must also change the URL rewrite rules in your web server configuration (.htaccess for Apache, lighttpd.conf for Lighttpd), or caching will not work.
  • Cache javascript file extension: *
    [ .js ___ ]
  • The file extension to append to the file name of the generated cache files. Note that this setting is of no relevance to any public URLs, and it is strongly recommended to leave this as the default '.js' unless you know what you are doing. If you change this, you must also change the URL rewrite rules in your web server configuration (.htaccess for Apache, lighttpd.conf for Lighttpd), or caching will not work.

Back to top

Boost crawler

  • [x] Enable the cron crawler
  • Pre-cache boosted URL's so they get cached before anyone accesses them.
  • [x] Crawl All URL's in the url_alias table.
  • Preemptively cache all urls found in the Drupal url_alias table. This will crawl that page even if it is not expired. Enable & run cron to get the boost cache loaded.
  • Crawler Throttle:(enter a number in micro seconds).
    [ 0 ]
  • Wait X micro seconds in between hitting each url. 1000000 is 1 second.
  • Crawler Batch Size: (enter a number of URLs).
    [ 25 ]
  • Number of URL's each thread grabs per database operation.
  • Number Of Threads: (select box)
    [ 2 ]
  • Be careful when choosing more then 2 threads.

Boost Apache .htaccess Rules Generator -expandable section-

After changing a selection, save the settings and return here to copy the newly generated rules for the htaccess file.

  • Servers URL or Name:
    [x] %{SERVER_NAME}
    [  ] %{HTTP_HOST}
    [  ] localhost
  • Best to leave these as %{}, only try the last option(s) if boost is still not working.
  • Document Root:
    [x] %{DOCUMENT_ROOT}
    [  ] C:/wamp/www
  • Value of is recommended for this server. Please open an boost issue on drupal.org, since apache and php are not configured correctly.
  • Generated Rules:
  • These rules or file is generated to work with the settings used above.
    Copy this into your .htaccess file as shown below

    # RewriteBase /

    The generated rules go RIGHT HERE (8 lines from the bottom)

    # Rewrite URLs of the form 'x' to the form 'index.php?q=x'

Clear Boost's Database

  • [Reset boost database:(0) records](button).
  • Warning: This gives you a clean slate for the boost database, use with caution.

Save Configurations (button) | Reset to Default (button)

Back to top

Prepare .htaccess File for Boost

Required for cached pages to be served.

    This is easy and anyone can do it without any trouble, follow along.

    Save a copy of the .htaccess file from your Drupal folder for safe keeping.
    It's easy to get a new one anytime if you need it, Drupal is always open.

    Locate the file boosted1.txt in the boost/htaccess folder.
    Double click on boosted1.txt to open it.
    Right click anywhere in the file, Left click on Select All (highlights the text), Right click again, Left click on Copy (that puts the file on your clipboard). Close that file, (X in the top right corner, we're done with it).

    Double click on the Drupal .htaccess file to open it. Look down through the file to see the part(shown below) It's 8 lines from the bottom.

    # RewriteBase /
    (Left click once between these 2 lines, Right click and choose Paste)
    # Rewrite URLs of the form 'x' to the form 'index.php?q=x' .

    Save the file. Put it back in with the rest of the Drupal files where it was.
    We are done, yes it was easy!


    The default.txt file also shows you the exact placement of the rules.

    Rules from boosted1.txt can also be found on the Boost Settings page (admin/settings/performance/boost) in the expandable field group called Boost Apache .htaccess settings generation.

    If static pages are not being served using the boosted1.txt configuration, try the boosted2.txt file before posting a support issue; or try the different radio buttons on the admin/settings/performance/boost page under Boost Apache .htaccess settings generation. field group.

    For the technically inclined, the difference between the two supplied .htaccess templates is due to boosted1.txt relying on SERVER_NAME versus boosted2.txt using HTTP_HOST. There exist valid use cases for both, especially in more advanced, multi-site Drupal installations.

Back to top

Prepare settings.php File for Cron

 

 

 

 

Set $base_url variable in /sites/default/settings.php so cron will run error free and clear the cache properly.
-------------------
This is a cut away of the settings.php file(about half way down)
-------------------
* Examples:
* $base_url = 'http://www.example.com';
* $base_url = 'http://www.example.com:8888';
* $base_url = 'http://www.example.com/drupal';
* $base_url = 'https://www.example.com:8888/drupal';
*
* It is not allowed to have a trailing slash; Drupal will add it
* for you.
*/
# $base_url = 'http://www.example.com'; // NO trailing slash!
-------------------
Add the website URL between the ( ' ' ) as in the example above.
Remove or delete the # so it will work.
-------------------

 

 

 Back to top

System Check and Verify Boost Functions

  • Check the status page
    Goto: Administer > Reports > Status report
    system path admin/reports/status
    Check for any errors or notices.
  • Log out from Drupal (or use another browser) to browse around your site as an anonymous user. Ensure that static files are indeed being generated into the Boost cache directory specified. If you opted to use gzip, check that gzipped files are being generated in the directory you specified for gzip. The performance settings page shows how many pages are being cached by Boost, and (for pages Boost cannot cache) by Drupal core.

 

Check Pages to Insure Boost is Performing

To check whether you have a static or dynamic version of a page. Visit the page as an anonymous user, visit a second page, then back to the original page. Click view source in your browser and look at the very end of the HTML source code. You have the cached or static version produced by Boost if the last line looks like this:

<!-- Page cached by Boost @ 2009-08-11 06:19:58, expires @ 2009-08-11 09:19:58 -->

  

Need help? Use the Drupal "Post Installation" (Forum). Please use a descriptive title for the post.
(or) Request support in the Boost (issue que).

 

Back to Top

 Back to Top