Forgot password?
 Register now


MACC-Public

View: 119|Reply: 1

[MACC-BASE] How to migrate the MACC 3.0 database to new server with same version

[Copy link]

1

Digests

17

Posts

24

Credits

Novice

Rank: 1

Credits
24
Post time 2017-8-22 10:21:11 | Show all posts |Read mode
How to migrate the MACC 3.0 database to new server with same version
Reply

Use magic Report

5

Digests

656

Posts

744

Credits

administrator

Rank: 9Rank: 9Rank: 9

Credits
744
Post time 2017-8-22 10:23:10 | Show all posts
If you need to back up all data of MACC-base, then need you follow the Database and MongoBD backup steps. If not, you can just backup the database only.
1.        Backup Database
Login to the server via SSH.
Command: mysqldump -umacc -p -R macc2 >/tmp/daily_all-databases_201X-XX-XX.sql
The password by default is “P@ssw0rd@macc2015”, referring on this path
(vi /macc/install/tomcat/macc_conf/properties/jdbc-dbcp.properties)

Copy or Download the sql file to PC.

2.        Backup the Mongo DB (devices and STAs record)
Command: mongodump -umacc -d macc2 -o /tmp/mongod_20170609
The password by default is “ma0c#2017#rj”, referring in
(vi /macc/install/tomcat/macc_conf/properties/mongodb.properties)

Copy or Download the mongo DB file to PC.

3.        Restore the database
Before restoring the database, please ensure the MACC-BASE version on new server should be same as original one. After migration, the license file will be expired. Please contact Ruijie Support in advance before migration.
Notes: it’s recommended that the IP address of new server should be same as the old one. Then you don’t need to modify the MACC URL on AP or DHCP pool.

1.        Upload the database and mongo DB file to new server under the /home folder. And login the new server via SSH.
2.        Exec “mysql -umacc -p”, password by default is “P@ssw0rd@macc2015”
3.        Exec “use macc2;”

4.        Use source command to restore the database.

4.        Restore the mongoDB
Command : mongorestore -umacc -d macc2  /home/mongod_20170609/macc2

5.        Migrate the files of the Firmware
Copy the /macc/data folder from the old sever to the new one.
6.        After all steps above, please restart the MACC-BASE server. Then access MACC web service: http://MACC BASE IP/
Reply Support Not support

Use magic Report

You have to log in before you can reply Login | Register now