Docker: migration from snapshot 3.1.0 to 3.1.0m1 fails

Hi,

I am using the docker snapshot release 3.1.0 (debian, last Wednesday) on a Synology 920+. Today I tried to switch to the current milestone build 3.1.0m1 (debian).

I loaded the image, created a container with the same volume, environment etc. settings as my currently running version.

I started the 3.1.0m1 with an empty config (startup is normal, and I see the “create user account” page on :8080) and then restored the zip archive (using “7z x”) to the conf and userdata folders.

The container starts normally (no new exceptions) but then it halts when the rule engine is loaded. No exception.

I can access the gui on :8080, but all things remain uninitialized. I waited a few minutes but no change.

Any idea where I went wrong ? I assume its not the build, but my config from the 3.1.0 snapshot.

Strange enough: when I then try to start my working snapshot version 3.1.0, it hangs at the same spot during startup. I had to restore a previous config snapshot which worked imediately. So I assume the config has been modified somewhere.

Thanks,
Lars

It sounds like your config was corrupted either prior to the backup or during the backup.

There really is no need to use that approach though.

Yes, the first step should be to backup. Though be aware that the Docker image will also create a backup automatically when it sees that the configs are for a different version of OH than what is in the image. You will find those backups in userdata/backups.

Then just start the new container using the old folders as they are. Any changes necessary required for the upgrade will be automatically done for you. I doubt this is the problem here, but there are times where the configs need to have changes between versions and those changes will not happen if you restore a backup from the old version over the files created by the new image. As a simple and benign case in point, userdata/etc/version.properties tells openHAB what version it’s running. When you restore your backup over the OH 3.1.0SNAPSHOT over your 3.1.0m1 configs, it will again think it’s running OH 3.1.0SNAPSHOT.

So you should always allow the container to upgrade your configs for you. Don’t just blindly restore an old backup over the configs created by a new version of the container.

Hi,

you were absolutely right! Your approach was immediately successful … stupid me …

If you don’t mind me saying so: you are my hero ! I cant count the number of times your quick and precise answers to questions in the forum have saved me a lot of time. Not to speak of your pattern threads!

Thank you very much!

Lars