wiki:InstallDrupal

Version 4 (modified by tristano, 12 years ago) (diff)

--

An outline of the project itself can be found here: http://bit.ly/rht93U

Integrating Drupal with BOINC

  1. Download Drupal 6 and install it into a prepared web root / virtual host. Alternatively, use a package manager for easier installation. In either case, be sure to include the allow overrides directive, as .htaccess files must be able to work. Also, enable mod_rewrite in Apache, if not so already, so that clean URLs can be used.
  1. Clone the BOINC source repository somewhere on the server (e.g. /BOINC/drupal-boinc) and link the sites/all/ directory in the Drupal web root to the drupal/sites/all/ directory in the BOINC source via symbolic link. Also clone the project specific source repository similarly (e.g. /BOINC/drupal) and link the sites/default/project/ directory there to sites/default/project/ in the project specific source.
  1. Import a working copy of the BOINC database to MySQL, granting permissions for SELECT, INSERT, UPDATE, and DELETE to an appropriate user (e.g. boinc) on boinc_db_name@localhost. Alternatively, hook into a "live" database for testing on an existing dev platform.
  1. Import the pre-configured Drupal database and grant permissions for SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER, CREATE_TMP_TABLE, and LOCK_TABLES to an appropriate user (e.g. drupal_boinc) on drupal_db_name@localhost.
  1. Edit the dbconfig.php file in sites/default/ of the web root so that db variables are appropriate for the Drupal database and boinc_db variables likewise allow access to the BOINC database.

Basic functionality should now be in place. Create an account and then set its uid to 1 in the Drupal users table for unlimited admin access in Drupal.

Importing BOINC data

With a functional Drupal system hooked into a BOINC database, the best practice is to then import user accounts, teams, and forums into Drupal via the BOINC data import function under the BOINC configuration section in administration. Importing users will generally include avatars, community preferences, private messages, friends, and any "ignored user" flags. At a minimum, all users who participated in the social aspects of the standard BOINC system will be imported. Users who did not have any interactions with other users can instead be imported on-the-fly when they first log into the Drupal system.

Prior to beginning the data import, the process must be configured. Begin with step 1 by reading and making any necessary changes to the settings on the BOINC data import settings page and then click the Save button. If all required settings pass validation, a link will appear to execute the process.

Follow the instructions on screen to work through each stage of the import process.

Notes:

  • Input format should be set to Rich text format for imported messages
  • Leave BBcode as is to keep existing functionality from BOINC

Troublshooting

Errors Referencing Old URLs or File Paths

If there are Drupal caches causing references to files that don't exist, the first thing to try is to access the page at:

/admin/settings/performance

At the bottom is a button to "Clear cached data", which is typically the first thing to try in general Drupal troubleshooting.

If the error prevents even access to that page, create a clear_cache.php file in the Drupal root directory:

<?php
  include_once('./includes/bootstrap.inc');
  drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
  drupal_flush_all_caches();
?>

Accessing that page should also clear the cache.

If neither of those work (or if direct DB access is not difficult), go straight to the database and run the following query:

DELETE FROM cache;

There are a number of cache_* tables to clear, but with any luck that one will suffice to then use one of the easier methods above to finish clearing them automatically.