Actions

Developer Area/Changing Hostnames: Difference between revisions

From Mahara Wiki

< Developer Area
(Created page with "When changing a Mahara installation over to a new hostname, the following steps are required to a) update the hostname setting, and b) re-generate the system's public key. <div …")
 
No edit summary
 
Line 3: Line 3:
<div id="section_1">
<div id="section_1">


== If you let Mahara auto-detect the wwwroot: ==
==If you let Mahara auto-detect the wwwroot:==


* Run the following SQL queries on the database. Remember to take a full dump of your database in case anything goes wrong!<br />
* Run the following SQL queries on the database. Remember to take a full dump of your database in case anything goes wrong!<br />
Line 12: Line 12:
</div><div id="section_2">
</div><div id="section_2">


== If you have set wwwroot in config.php manually: ==
==If you have set wwwroot in config.php manually:==


* Update $cfg-&gt;wwwroot in config.php to the new address.
* Update $cfg-&gt;wwwroot in config.php to the new address.

Latest revision as of 16:12, 11 Mayıs 2011

When changing a Mahara installation over to a new hostname, the following steps are required to a) update the hostname setting, and b) re-generate the system's public key.

If you let Mahara auto-detect the wwwroot:

  • Run the following SQL queries on the database. Remember to take a full dump of your database in case anything goes wrong!
    • delete from config where field = 'wwwroot';
    • delete from config where field like '%openssl%';
  • Log in as an administrator and go to "Site Administration -> Configure Site -> Networking" to re-generate the public key.

If you have set wwwroot in config.php manually:

  • Update $cfg->wwwroot in config.php to the new address.
  • Run the following SQL queries on the Mahara database.  Remember to take a full dump of your database in case anything goes wrong!
    • delete from config where field = 'wwwroot';
    • delete from config where field like '%openssl%';
  • Log in as an administrator and go to "Site Administration -> Configure Site -> Networking" to re-generate the public key.

The 'config' table name in the above SQL statements may vary if you have a dbprefix set.

Note that any networked peers such as Moodle would also need to have their configuration updated to contain the new Mahara hostname and public key.