If you are currently using a stable release of phpBB, updating to this version is straightforward. You would have downloaded one of four packages and your choice determines what you need to do. Note: Before updating, we heavily recommend you do a full backup of your database and existing phpBB files! If you are unsure how to achieve this please ask your hosting provider for advice.
Please make sure you update your phpBB source files too, even if you just run the database updater. If you have shell access to your server, you may wish to update via the command line interface. From your board's root, execute the following command: php bin/phpbbcli.php --safe-mode db:migrate
.
4.i. Full package
Updating using the full package is the recommended update method for boards without modifications to core phpBB files.
First, you should make a copy of your existing config.php
file; keep it in a safe place! Next, delete all the existing phpBB files, you should leave your files/
, images/
and ext/
directories in place, otherwise you will lose your file attachments, uploaded images and get errors due to missing extension files. You can leave alternative styles in place too. With this complete, you can upload the new phpBB files (see New installation for details if necessary). Once complete, copy back your saved config.php
, replacing the new one. Another method is to just replace the existing files with the files from the full package - though make sure you do not overwrite your config.php file.
You should now got to /install/app.php/update
which will display a warning: No valid update directory was found, please make sure you uploaded the relevant files. Beneath that warning you will see a radio button Update database only, just click Submit. Depending on your previous version this will make a number of database changes. You may receive FAILURES during this procedure. They should not be a cause for concern unless you see an actual ERROR, in which case the script will stop (in this case you should seek help via our forums or bug tracker). If you have shell access to your server, you may wish to update via the command line interface. From your board's root, execute the following command: php bin/phpbbcli.php --safe-mode db:migrate
.
Once /install/app.php/update
has completed, it displays the success message: The database update was successful. You may proceed to the Administration Control Panel and then remove the install directory as advised.
4.ii. Changed files
This package is meant for those wanting to only replace the files that were changed between a previous version and the latest version.
This package contains a number of archives, each contains the files changed from a given release to the latest version. You should select the appropriate archive for your current version, e.g. if you currently have 3.3.0 you should select the appropriate phpBB-3.3.1-files.zip/tar.bz2
file.
The directory structure has been preserved, enabling you (if you wish) to simply upload the uncompressed contents of the archive to the appropriate location on your server, i.e. simply overwrite the existing files with the new versions. Do not forget that if you have installed any modifications (MODs) these files will overwrite the originals, possibly destroying them in the process. You will need to re-add MODs to any affected file before uploading.
As for the other update procedures, you should go to /install/app.php/update
, select "Update database only" and submit the page after you have finished updating the files. This will update your database schema and increment the version number. If you have shell access to your server, you may wish to update via the command line interface. From your board's root, execute the following command: php bin/phpbbcli.php --safe-mode db:migrate
.
4.iii. Patch file
The patch file package is for those wanting to update through the patch application, and should only be used by those who are comfortable with it.
The patch file is one solution for those with changes in to the phpBB core files and do not want to re-add them back to all the changed files. To use this you will need command line access to a standard UNIX type patch application. If you do not have access to such an application, but still want to use this update approach, we strongly recommend the Automatic update package explained below. It is also the recommended update method.
A number of patch files are provided to allow you to update from previous stable releases. Select the correct patch, e.g. if your current version is 3.3.0, you need the phpBB-3.3.1-patch.zip/tar.bz2
file. Place the correct patch in the parent directory containing the phpBB core files (i.e. index.php, viewforum.php, etc.). With this done you should run the following command: patch -cl -d [PHPBB DIRECTORY] -p1 < [PATCH NAME]
(where PHPBB DIRECTORY is the directory name your phpBB Installation resides in, for example phpBB, and where PATCH NAME is the relevant filename of the selected patch file). This should complete quickly, hopefully without any HUNK FAILED comments.
If you do get failures, you should look at using the Changed Files package to replace the files which failed to patch. Please note that you will need to manually re-add any MODs to these particular files. Alternatively, if you know how, you can examine the .rej files to determine what failed where and make manual adjustments to the relevant source.
You should, of course, delete the patch file (or files) after use. As for the other update procedures, you should navigate to /install/app.php/update
, select "Update database only" and submit the page after you have finished updating the files. This will update your database schema and data (if appropriate) and increment the version number. If you have shell access to your server, you may wish to update via the command line interface. From your board's root, execute the following command: php bin/phpbbcli.php --safe-mode db:migrate
.
4.iv. Automatic update package
This update method is only recommended for installations with modifications to core phpBB files. This package detects changed files automatically and merges in changes if needed.
The automatic update package will update the board from a given version to the latest version. A number of automatic update files are available, and you should choose the one that corresponds to the version of the board that you are currently running. For example, if your current version is 3.3.0, you need the phpBB-3.3.0_to_3.3.1.zip/tar.bz2
file.
To perform the update, either follow the instructions from the Administration Control Panel->System Tab - this should point out that you are running an outdated version and will guide you through the update - or follow the instructions listed below.
- Go to the downloads page and download the latest update package listed there, matching your current version.
- Upload the uncompressed archive contents to your phpBB installation - only the
install/
and vendor/
folders are required. Upload these folders in their entirety, retaining the file structure.
- After the install folder is present, phpBB will go offline automatically.
- Point your browser to the install directory, for example
http://www.example.com/phpBB3/install/
- Choose the "Update" Tab and follow the instructions
4.v. All package types
If you have non-English language packs installed, you may want to see if a new version has been made available. A number of missing strings may have been added which, though not essential, may be beneficial to users. Please note that at this time not all language packs have been updated so you should be prepared to periodically check for updates.
These update methods will only update the standard style prosilver
, any other styles you have installed for your board will usually also need to be updated.