831 |
florian |
1 |
Preliminary Upgrade-Instructions
|
|
|
2 |
================================
|
|
|
3 |
|
|
|
4 |
This document describes the Phorum upgrading process. Please keep in mind,
|
|
|
5 |
that these instructions are neither complete, nor final. If you find
|
|
|
6 |
problems in upgrading which are not described here or if you have
|
|
|
7 |
useful additions, please let us know.
|
|
|
8 |
|
|
|
9 |
Table of contents:
|
|
|
10 |
|
|
|
11 |
1. Upgrading from a Phorum5 version to another Phorum5 version
|
|
|
12 |
1.1 Upgrading the database
|
|
|
13 |
1.1.1 Preparations
|
|
|
14 |
1.1.2 From a webbrowser
|
|
|
15 |
1.1.3 From a system console
|
|
|
16 |
1.2 Upgrading templates and hacks
|
|
|
17 |
2. Upgrading from Phorum 3.4.x to Phorum5
|
|
|
18 |
|
|
|
19 |
|
|
|
20 |
1. Upgrading from a Phorum5 version to another Phorum5 version
|
|
|
21 |
-------------------------------------------------------------------------------
|
|
|
22 |
|
|
|
23 |
|
|
|
24 |
1.1 Upgrading the database
|
|
|
25 |
--------------------------
|
|
|
26 |
|
|
|
27 |
|
|
|
28 |
1.1.1 Preparations
|
|
|
29 |
-----------------------
|
|
|
30 |
|
|
|
31 |
The upgrading process will preserve all of your active settings and
|
|
|
32 |
modules, but will overwrite hacks and any changes made to the default
|
|
|
33 |
template (in the directory {phorum dir}/templates/default). Other
|
|
|
34 |
templates will be kept intact.
|
|
|
35 |
|
|
|
36 |
Here are the steps for upgrading:
|
|
|
37 |
|
|
|
38 |
- Backup your existing Phorum5 installation.
|
|
|
39 |
Before doing an upgrade, it is always wise to make a good backup
|
|
|
40 |
of your running system. Make a backup your Phorum install directory
|
|
|
41 |
and the database in which your Phorum tables are stored;
|
|
|
42 |
|
|
|
43 |
- Download a newer Phorum5 package;
|
|
|
44 |
|
|
|
45 |
- Extract the files and put them on top of the current installation;
|
|
|
46 |
|
|
|
47 |
- Keep the database settings from {phorum dir}/include/db/config.php
|
|
|
48 |
the same;
|
|
|
49 |
|
|
|
50 |
Now you can choose whether you want to upgrade from a webbrowser or
|
|
|
51 |
from a console.
|
|
|
52 |
|
|
|
53 |
|
|
|
54 |
1.1.2 From a webbrowser
|
|
|
55 |
-----------------------
|
|
|
56 |
|
|
|
57 |
Open your forum using your webbrowser. In case a database upgrade
|
|
|
58 |
is needed, you will be prompted to go to the admin page. In that case
|
|
|
59 |
open the {phorum url}/admin.php page, which will guide you through
|
|
|
60 |
the upgrade.
|
|
|
61 |
|
|
|
62 |
|
|
|
63 |
1.1.3 From a system console
|
|
|
64 |
---------------------------
|
|
|
65 |
|
|
|
66 |
In the scripts directory of your Phorum installation, you will find
|
|
|
67 |
the script "console_upgrade.php". Go to the scripts directory and
|
|
|
68 |
execute the script from there. On most systems, you can do this using
|
|
|
69 |
the following command:
|
|
|
70 |
|
|
|
71 |
# php console_upgrade.php
|
|
|
72 |
|
|
|
73 |
If you want to run this script from a different locations, then edit
|
|
|
74 |
the script and update the $PHORUM_DIRECTORY variable to match the
|
|
|
75 |
location of your Phorum installation.
|
|
|
76 |
|
|
|
77 |
|
|
|
78 |
1.2 Upgrading templates and hacks
|
|
|
79 |
---------------------------------
|
|
|
80 |
|
|
|
81 |
For minor upgrades, the Phorum team has the policy that templates
|
|
|
82 |
should not change. For example, if you are upgrading version 5.1.1
|
|
|
83 |
to 5.1.2, you can simply keep the old templates.
|
|
|
84 |
|
|
|
85 |
Template functionality might change between major Phorum releases.
|
|
|
86 |
For example, templates that were made for Phorum 5.0.x are not
|
|
|
87 |
compatible with the templates for Phorum 5.1.x. So to upgrade these,
|
|
|
88 |
you'll have to build new templates, based on the new default template
|
|
|
89 |
that is included in the distribution. Simply copying the old template
|
|
|
90 |
will most probably result in errors and missing functionality.
|
|
|
91 |
|
|
|
92 |
If you are doing a minor upgrade and you have to preserve changes that
|
|
|
93 |
were made to the default template (which is not the recommended way
|
|
|
94 |
of customizing Phorum, see creating_templates.txt), you can follow one
|
|
|
95 |
of the following options:
|
|
|
96 |
|
|
|
97 |
- Extract the new Phorum distribution to its own directory and reapply
|
|
|
98 |
your changes before putting it over the existing installation;
|
|
|
99 |
|
|
|
100 |
- Create a backup of your existing installation. Install the new
|
|
|
101 |
distribution on top of the old one and reapply the changes to
|
|
|
102 |
the new version while it is "live".
|
|
|
103 |
|
|
|
104 |
|
|
|
105 |
2. Upgrading from Phorum 3.4.x to Phorum5
|
|
|
106 |
-------------------------------------------------------------------------------
|
|
|
107 |
|
|
|
108 |
- Download and unpack the Phorum5 package;
|
|
|
109 |
|
|
|
110 |
- Follow the installation instructions in docs/install.txt. Install
|
|
|
111 |
Phorum5 is a new directory.
|
|
|
112 |
|
|
|
113 |
- Convert the old forum data:
|
|
|
114 |
|
|
|
115 |
In the scripts directory of your Phorum5 distribution, you will find
|
|
|
116 |
a script named phorum3to5convert.php. Instructions for using this
|
|
|
117 |
script can be found at the top of this script itself. The script will
|
|
|
118 |
convert your old forum to Phorum5. Everything, but permission levels,
|
|
|
119 |
is converted.
|
|
|
120 |
|
|
|
121 |
- Update the posted message counters for the users:
|
|
|
122 |
|
|
|
123 |
In the scripts directory, you will also find a script named
|
|
|
124 |
"update_postcount.php". This script can be used to update the number
|
|
|
125 |
of posts for users to the right value. So if you want correct numbers
|
|
|
126 |
to show up in the user profiles, just run this script once AFTER the
|
|
|
127 |
conversion has been completed. To run it, you will have to copy it
|
|
|
128 |
over to the main Phorum5 directory. After that you can either run
|
|
|
129 |
it from the command line or by opening it from your webbrowser. See
|
|
|
130 |
also the instructions in the script itself.
|
|
|
131 |
|