Installation & Settings 6.x-1.01

This page is a walk-through of the steps and the 6.x-1.01 UI pages, so everything will look familiar.

This might look a little overwhelming, but It's easy. With a few selections during setup along with the default settings, it will work fine in most cases.

Contents

Steps to install

  1. Download Boost, Transliteration, Globalredirect and unzip the modules on your computer.
  2. Prepare htaccess file for boost and settings.php for cron.
  3. FTP or upload the module folders with all their contents(as is) to sites/all/modules
  4. Goto: Administer > Site configuration > Clean URLs
    system path admin/settings/clean-urls
    Ensure that Drupal's clean URLs are enabled and working correctly.
  5. Goto: Administer > Site building > Modules
    system path admin/build/modules/list
    Enable the Boost module in the Caching section, Transliteration, Globalredirect and Poormanscron if used.
  6. 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/Boost settings) UI page.
  7. After the module has been enabled, a notice will display (Drupal's standard page caching disabled by Boost.), we will turn this back on after setting up the module.

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.
    All done, the pages should now be served by Boost after all the settings are completed.
    Check the pages using the instructions in the last section on this page. If they are not showing the html comment, try the boosted2.txt file or use the htaccess generator in the performance/boost settings UI.

    Additional notes for htaccess:

    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

Performance /Boost Settings [tab]

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

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.

  • Boost - Static page cache: Choose Enabled for Boost to work.
    (  ) Disabled
    (x) Enabled
    (  ) (Not Recommended) Set Boost & Core (if enabled) cache for each page
  • Gzip page compression (Boost & Core): Radio buttons
    (  ) Disabled
    (x) Enabled (Default)
  • 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 - 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.
  • 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.
  • 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.

    [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.

 

Back to top

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.
  • [  ] Cache .xml & /feed
  • Boost will cache .xml and /feed urls as xml data.
  • [  ] 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 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 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).
  • [  ] Check database timestamps for any site changes. Only if there's been a change will boost flush the expired content on cron. (this helps to reduce server load by keeping cached pages that have not changed)
  • 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] Asynchronous Operation: output HTML, close connection, then store static file.
  • Run php in the background. When a cached page is generated, this will allow for faster page generation; downside is the headers are not the standard ones outputted by drupal; sends "Connection: close" instead of "Connection: Keep-Alive".
  • [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.
    Note: When a node belongs to term/1 and it gets created/updated/deleted, the cached page(s) for term/1 will be cleared.
  • [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 PHP error on page.
  • Selected - Do not cache the page if there are PHP errors.
    Not Selected - Cache pages even if it might contain errors.
  • [x] Do not cache if a message is on the page
  • Selected - Do not cache the page if there are drupal messages.
    Not Selected - Cache pages even if it might contain a drupal message.
  • [  ] 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.
    Note: Recommended for sites that don't change much and have only administrator logins.
  • [  ] 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:
    [ _______ ] (text box)
  • 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:
    [ _______ ] (text box)
  • 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:
    [5 Record all errors to the db log] (select box)
  • This sets the amount of errors recorded to watchdog(DbLog) when a static state is selected.

 

Back to top

Boost crawler

  • [  ] Enable the cron crawler
  • Pre-cache boosted URL's so they get cached before anyone accesses them. Enable the crawler first and save settings to use Preemptive Cache settings.
  • [  ] Preemptive Cache HTML
  • Enable caching of this content type with this checkbox.
  • [  ] Preemptive Cache XML
  • Enable caching of this content type with this checkbox.
  • [  ] Preemptive Cache AJAX/JSON
  • Enable caching of this content type with this checkbox.
  • [  ] Crawl All URL's in the url_alias table.
  • Enable the crawler first to enable this checkbox.
  • Crawler Throttle:
    [ 0 ] (enter a number in micro seconds)
  • Wait X micro seconds in between hitting each url. 1000000 is 1 second.
  • Crawler Batch Size:
    [ 12 ] (enter number of URLs)
  • Number of URL's each thread grabs per database operation.
  • Number Of Threads:
    [ 2 ] (select box)
  • Be careful when choosing more then 2 threads.

    [Reset Crawler & Cron Semaphore] (button)

    Resets the crawler and clears the cron semaphore entry from the database (a clean slate).

Back to top

Boost Apache .htaccess Rules Generator

This part of the UI is an added feature if needed. The htaccess rules are also located in the module folder boost/htaccess, which contains boosted1.txt and boosted2.txt files.

Note: If a selection is changed, save the settings. Then Goto: Boost htaccess rules generation page, copy the new rules and paste them into the Drupal 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.

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

Drupal Performance [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

  • Caching mode:
    (  ) Disabled
    (x) Normal (recommended for production sites, no side effects)
    (  ) Aggressive (experts only, possible side effects)
  • Minimum cache lifetime:
    [< none>] (select box) none is fine for small sites.
  • 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.
  • Gzip page compression (Boost & Core):
    (  ) 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 webserver that performs compression.

    [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.

  • Block cache:
    (  ) Disabled
    (x) Enabled (Recommended)
  • 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.

  • Optimize CSS files:
    (  ) Disabled
    (x) Enabled (Recommended)
  • This option can interfere with theme development and should only be enabled in a production environment.
  • Optimize JavaScript files:
    (  ) Disabled
    (x) Enabled (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

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).
Use a descriptive title for the post to get better help and get it faster.
(or) Request support in the Boost (issue que).

 

 

 

Back to top

Boost Administrative and Stats Blocks

There are 2 blocks that you can add to help with the administrative side (status, page configuration), and 1 block to support core stats.
Goto: (administer > Site building > Blocks > List) to place them.

Status Block

This block shows the current status of the page as far as Boost is concerned. It will state if the page is served 'live' or by 'Boost', the expiration of the page and has a Flush Page button to clear the page from the cache manually.

Page configuration Block

This block allows the administrator to set pages individually. Including setting for minimum cache lifetime(select box), preemptive cache(on or off), scope(page ID, content type or content container).

Stats Block

Drupal's core stats is supported. Configure the "Popular content" block, but then disable it. Place the "Boost: AJAX core statistics" in its place. If ajax stats are loading too slowly, copy stats/boost_stats.php to your webroot and enable "Cache Statistics Block". The cache gets updated on cron runs.

 

Back to Top

 Back to Top