I’m having a few problems upgrading my mender server from 2.0 to 2.1. First the instructions say
“run the migrate-db script from migration directory.”
So I tried that and got:
/mender-server/migration$ ./migrate-db
./migrate-db: line 30: ./run: No such file or directory
So I tried running it from the production directory which contains the run script:
/mender-server/production$ …/migration/migrate-db
Stopping menderproduction_mender-device-auth_1 … done
Stopping menderproduction_mender-useradm_1 … done
Stopping menderproduction_mender-deployments_1 … done
Stopping menderproduction_mender-inventory_1 … done
menderproduction_mender-mongo_1 is up-to-date
2019-10-04T13:28:29.616+0000 Failed: mongorestore target ‘/srv/db-dump/mender-mongo-useradm’ invalid: stat /srv/db-dump/mender-mongo-useradm: no such file or directory
2019-10-04T13:28:29.696+0000 Failed: mongorestore target ‘/srv/db-dump/mender-mongo-inventory’ invalid: stat /srv/db-dump/mender-mongo-inventory: no such file or directory
2019-10-04T13:28:29.733+0000 Failed: mongorestore target ‘/srv/db-dump/mender-mongo-device-auth’ invalid: stat /srv/db-dump/mender-mongo-device-auth: no such file or directory
2019-10-04T13:28:29.755+0000 Failed: mongorestore target ‘/srv/db-dump/mender-mongo-deployments’ invalid: stat /srv/db-dump/mender-mongo-deployments: no such file or directory
Hi @martin it seems you have some local changes to those files. I’m not sure why else “git merge” would be detecting a conflict. Have you viewed the mentioned files to see what areas are flagged as conflicts?
The local changes are the ones made that are described in the production server setup instructions. As far as I know I have touched any of the files listed.
Here are some of the conflicts. Let me know if you want all of them.
I am facing the same issue as @martin. I try to migrate from version 2.0 (installed as described in the doku) to 2.1 too.
First, I execute “dump-db” without any errors, then i execute “migrate-db” and get the same errors as @martin mention in his first post.
I also get the merge conflict, but I haven’t changed the corresponding files either…
I just fixed it the hard way: “git merge 2.1.0 --strategy-option theirs”. But maybe this isn’ t the best way…