How to update mongo data from 0.5.0 to 0.6.1?
-
Just run the nodebb upgrade - https://docs.nodebb.org/vi/latest/upgrading/
Dont forget to backup first
-
Thank you of course, but the obvious solution does not solve the problem, that is why I have asked this question on the forum.
I have mongodb database backup from version 0.5.0
How to move mongodb database from 0.5.0 to 0.6.1 ?
The way of upgarding that is described in the wiki is not suitable.
The reason is that the version 0.5.0 has installed on server #1, there was written several own plugins, personal theme
and many other non-standard settings. Now we are moving to new server and I want to use there latest version of NodeBB.
I have tried to move configured version 0.5.0 on new server,
an error occurs "Error creating index server 127.0.0.1:27017 sockets closed".
Running the upgrade script does not result in any obvious changes.
The main question is how to transfer database of users, messages, etc...
Later I can install my own plugins amd customize default theme.
I see two ways to solve my problem:- Set to work old nodeBB version 0.5.0 on new server and then do upgrade.
- Transfer messages, users, passwords from a database configured for version 0.5.0 on a fresh instal of 0.6.1
I would be grateful for any help.
-
@KotoWolod said:
Set to work old nodeBB version 0.5.0 on new server and then do upgrade.
I would do this I think its the safest solution. Correct med if I am wrong nodebb geeks
-
@Mikael ΠΠΊ.thx May be you are right.
-
After successful updating I run "npm up", cleaned cookies and cache, made "node app --reset themes" and "./nodebb reset all". Everything has started without errors but theme does not show categories and if I am trying to login then I've got error message "invalid csrf token". If I will set back fresh database to the forum - it works.
-
Invalid csrf error possibly means your theme is out of date. Try updating it to latest version compatible with 0.6.1.
As for empty categories page it might be related to the theme being out of date or the categories just don't have the correct permissions setup in the ACP.
-
@baris My current theme is up to date. As I have already wrote , I did "npm up" and "node app --reset themes".
I think that the problem is in updating of database.
Permissions are ok because in version 0.5.1 everything works.
Only after update using wiki tutorial I have faced with this problem. -
This is the manual how to update/upgrade from v0.5.0 to v0.6.1
- git checkout c9228f14837fcf2903923ebca3d90a0d1517a713 (I don't now why v0.5.1 doesn't work in cli and csrf token error)
- ./nodebb upgrade
- git checkout d341428ca1b88d56f7c7fe37d3e5e87d83bb0698 (v0.5.2 doesn`t work in cli too)
- ./nodebb upgrade
- git checkout cce076fc83e6a29c7d385ee757cce4b40c63daf2 (v0.5.3 work in cli, but I am not interesting in experiments)
- ./nodebb upgrade
- git checkout 1943f8fdfa573b40e8b0c5e23e68142a71b2cf93 (v0.5.4)
- ./nodebb upgrade
- git checkout d6c17d5cae66f2ab0d4174e1b6bdda24856eacbe (v0.5.5)
- ./nodebb upgrade
- git checkout e7ecd0f1eb81c54f33f51958b64aa937613bc99d (v0.5.6)
- ./nodebb upgrade
- git checkout 6748013c6534ed672184145ee7b5120eb07e7b47 (v0.5.7)
- ./nodebb upgrade
- git checkout accee7d05ba3f791627d439ac1c73cf5f858eebe (v0.6.0)
- ./nodebb upgrade
- git checkout 4686ae992318eeaaff1945868ee4cc094dcda17d (v0.6.1)
- ./nodebb upgrade
- git checkout c2656bf0b69ec05b1cbc123ef06ec0b14657cc8b (stable)
- ./nodebb upgrade
- npm up
- clear cache and cookies
Is anybody knowing the better solution? Please, give me to know.