How to restore Redmine backup » History » Version 2
chin-yeh, 03/12/2012 02:25 PM
1 | 1 | chin-yeh | h1. How to restore Redmine backup |
---|---|---|---|
2 | 2 | chin-yeh | |
3 | This restoration involves 2 parts, first part is to restore the application data; second part is to restore the <code>Redmine</code> database. |
||
4 | |||
5 | _Steps (Part 1 of 2):_ |
||
6 | # obtain the backup location from [[How to backup Redmine]] |
||
7 | # in order to restore the <code>Redmine</code>, extract the whole backup to a temporary location and search for this folder: |
||
8 | <pre> |
||
9 | opt/redmine-x.x.x |
||
10 | </pre> |
||
11 | # copy the folder, <code>redmine-x.x.x</code> and then paste it into: |
||
12 | <pre> |
||
13 | /opt |
||
14 | </pre> |
||
15 | # change the <code>folder owner</code> to: |
||
16 | <pre> |
||
17 | $ chown -R redmine:redmine /opt/redmine-x.x.x |
||
18 | </pre> |
||
19 | # done |
||
20 | |||
21 | _Steps (Part 2 of 2):_ |
||
22 | # search for this file, *redmine_backup.sql* in the extracted backup folder: |
||
23 | <pre> |
||
24 | opt/db_bak |
||
25 | </pre> |
||
26 | # ensure the following ports are unoccupied: |
||
27 | ** 50000 |
||
28 | ** 3001 |
||
29 | ** 3002 |
||
30 | ** 3690 |
||
31 | ** 3007 |
||
32 | # login as *redmine* user and then <code>cd</code> to the <code>Redmine</code> folder: |
||
33 | <pre>$ cd /opt/redmine-x.x.x</pre> |
||
34 | # execute the following script to start the <code>Redmine</code>: |
||
35 | <pre>$ ./ctlscript.sh</pre> |
||
36 | # if started without any error, execute the following script to restore the <code>Redmine</code> database: |
||
37 | <pre> |
||
38 | $ ./use_redmine |
||
39 | $ mysql -u root -p bitnami_redmine < redmine_backup.sql |
||
40 | </pre> |
||
41 | ** _refer to the server_login.xls to get the database password_ |
||
42 | # done. |