#433  Upgrade failure to 5.1.0 or higher if using external database
Released
Robin Shen opened 2 years ago
No description
Robin Shen changed fields 2 years ago
Name Previous Value Current Value
Priority
Normal
Critical
OneDev changed state to 'Closed' 2 years ago
Previous Value Current Value
Open
Closed
OneDev changed state to 'Released' 2 years ago
Previous Value Current Value
Closed
Released
Koichi MATSUMOTO commented 2 years ago

The same issue at upgrading 5.3.3 to 5.4.0. I use PostgreSQL.

  • server.log
2021-11-23 22:14:44,475 INFO  [WrapperSimpleAppMain] i.onedev.commons.bootstrap.Bootstrap Launching application from '/srv/onedev/onedev-5.4.0'...
2021-11-23 22:14:44,476 INFO  [WrapperSimpleAppMain] i.onedev.commons.bootstrap.Bootstrap Cleaning temp directory...
2021-11-23 22:14:44,652 INFO  [WrapperSimpleAppMain] io.onedev.commons.loader.AppLoader Initializing dependency injection container...
2021-11-23 22:14:45,714 INFO  [WrapperSimpleAppMain] io.onedev.commons.loader.AppLoader Starting plugin manager...
2021-11-23 22:14:47,855 ERROR [WrapperSimpleAppMain] i.o.s.p.DefaultPersistManager Data version mismatch (app data version: 70, db data version: 69)
Robin Shen commented 2 years ago

@mzch Thanks for your feedback. Please let me know:

  1. How 5.3.3 is started? If via docker, please let me know detailed docker command line you are using
  2. What command you are using to perform the upgrade
Koichi MATSUMOTO commented 2 years ago
  1. Yes, 5.3.3 ran successfully. I don't use docker.
  2. I did as below:
  • bin/upgrade.sh .
  • bin/server.sh start
Koichi MATSUMOTO commented 2 years ago

Finally I created backup file using bin/backup-db.sh ../backupfile, dropped database and re-created it, and restore data from backupfile. Now I run 5.4.0 successfully.

Robin Shen commented 2 years ago

@mzch the command used to upgrade seems incorrect. The procedure should be:

  1. Extract onedev-5.4.0.zip to a folder say "/path/to/onedev-5.4.0"
  2. Open terminal and run command:
$ /path/to/onedev-5.4.0/bin/upgrade.sh /path/to/onedev-5.3.3
  1. After running above command, "/path/to/onedev-5.3.3" will be upgraded to 5.4 (to avoid confusion, it is suggested to name onedev directory without version info)
Koichi MATSUMOTO commented 2 years ago

Oh, thanks. I was wrong about upgrade process. I'd like you to update Upgrade Guide to have a more clear understanding...

Robin Shen commented 2 years ago

Thanks for the suggestion. Will do that.

issue 1 of 1
Type
Bug
Priority
Critical
Assignee
Affected Versions
Not Found
Issue Votes (0)
Watchers (3)
Reference
onedev/server#433
Please wait...
Page is in error, reload to recover