Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade from 1.0.6 to 1.6 failing #74

Closed
q1x opened this issue May 3, 2015 · 23 comments
Closed

Upgrade from 1.0.6 to 1.6 failing #74

q1x opened this issue May 3, 2015 · 23 comments

Comments

@q1x
Copy link

q1x commented May 3, 2015

I'm a long time user of OpenDB. I started with a 0.8x install and have upgraded it to 1.0.6 some time ago. This was happily running on an Ubuntu 8.0.4 vm for years. I've recently killed the VM and installed a new 14.04 install and I'm now trying to upgrade to the latest opendb version.

I have the old database restored and moved the old webroot to the new server, that is all working fine.
However, Trying to upgrade to 1.6 I had several errors pointing me to first upgrade to 1.5 before trying to upgrade to 1.6.

I've downloaded the 1.5.0.4, however that fails the upgrade with a lot of SQL errors and corrupts my database (all items are gone).

Can you tell me what the recommended upgrade path would be in this case?

@pellcorp
Copy link
Owner

Apologies for not getting to this earlier

@pellcorp
Copy link
Owner

Ok so 1.0.6 is ancient. do you have a backup of the databas? Can you share it with me. I can setup a 1.5 env and try and upgrade your DB myself. If you can share it send to

@q1x
Copy link
Author

q1x commented May 14, 2015

Hi Jason,

Thanks for getting back to me, thank you very much for helping!
Of course I can share the Mysql DB with you, however the email address is missing from your last message.

I don't think Github supports Private Messages anymore, is there some other way we can get into contact? (IRC/twitter/?)

Thanks again,

Raymond

@q1x
Copy link
Author

q1x commented May 14, 2015

I think I've found your email address, I'll send the DB to you.

@pellcorp
Copy link
Owner

Hi,

I have released a new 1.5.0.8 release which includes fixes for mysql 5.5 and latest php support so that users can upgrade from 1.0.5

https://github.com/pellcorp/opendb/archive/RELEASE_1_5_0_8.zip

This should allow you to upgrade.

So install opendb 1_5_0_8 and perform your upgrade from 1.0.6 to 1.5.0.8

Then install new 1.6 version and point to the upgraded db and complete the upgrade.

As always keep a db backup and let me know how you go

@pellcorp
Copy link
Owner

Ok - so I finally got back to this. I can see that there 350 odd records in file_cache that most likely were not correctly migrated. I am currently figuring out how this should have worked and will get back to you.

Sorry for taking so long

@pellcorp
Copy link
Owner

I will need your filecache directory as well. For some reason these old style uploaded files were not correctly transfered from filecache to upload as part of the upgrade. This might occur if the filecache directory is missing the files. So I need a copy of your 1.0.6 installation including filecache

@pellcorp
Copy link
Owner

I updated the 1.5.0.8 with an additional check for missing file cache items when upgrading. Please use this branch instead of the previously mentioned tag.

https://github.com/pellcorp/opendb/tree/RELEASE_1_5_0_8

See below the errors I received:

upgrade-errors

@MartinWunderli
Copy link
Contributor

Dear Jason,

You probably cannot believe it, but I win the 'outdated' race (I also started with 0.8 years ago...). I am still running an Ubuntu 8.04 VM using OpenDB 1.0.5. But now I have to migrate to ubuntu 14.04, since the hardware of the VM server is falling apart... And I have to migrate, reinstall is not an option with more than 1000 DVDs and since I added several language_audio combinations like ITALIAN_5.1 and new system attributes like PUR_DATE (PUR for purchase).

So the old server is: Ubuntu 8.04, MySQL 5.0.96-0ubuntu3, OpenDB 1.05
The new server is/will be: Ubuntu 14.04, 5.5.44-0ubuntu0.14.04.1, OpenDB 1.6

Reading this post, I would think of the following procedure:

  • make a backup of the web server directory and a dump of the opendb mysql database on old
  • unpacking the special 1.5.0.7 branch on top of the installed 1.0.5 directory on old
  • run install.php (really? does it detect an existing installation? The docs are not quite clear for me) on old
  • unpack 1.6.0 on top of the now migrated 1.0.5/1.5.0.7 directory on old
  • run install.php (from 1.6.0)
  • dump the opendb database on old
  • copy the web server directory from old to new server
  • create a new database opendb and a user lender
  • import the dump

-OR-

is it better to copy the web server directory to the new server, import the 1.0.5 dump there, install 1.5.0.7 on top of the existing 1.0.5 directory and run install.php already on the new server? Then upgrade to 1.6?

Cheers and thanks for your help
Martin

@MartinWunderli
Copy link
Contributor

I tried the second approach and I am now a bit confused.

  • I downloaded the zip from https://github.com/pellcorp/opendb/tree/RELEASE_1_5_0_7
  • I copied the web server directory and the mysql dump (opendb 1.0.5/mysql 5.0) to the new server, imported the myssql dump into mysql 5.5
  • I unzipped the zip on the new server, tar-ed the contents into the web server directory and started install.php. All the upgrade steps (a lot!) went fine. Just out of curiosity I logged in. First I was a bit suprised that all DVDs had a new date (as of today) and that when I wanted to create a new item, the page went blank. Nothing on it.
  • So I thought, let's go to 1.6.0. All steps without errors as before, but still nothing when I try to create a new item.

Any ideas?

@MartinWunderli
Copy link
Contributor

Hmmmh, will not give up...

I tried the 1.5.0.7 upgrade on the old server (mysql 5.0). Creating a new item after upgrade to 1.5.0.7 showed the usual page, not blank.Fine!
But then the upgrade 1.6.0 screen went blank after I clicked next (on Ubuntu 8.04/opendb 1.5.0.7/mysql 5.0). Ooops.

Cheers
Martin

@MartinWunderli
Copy link
Contributor

Now I am totally confused... I tried to do again the second approach (see message "I tried the second approach and I am now a bit confused") and now the upgrade to 1.6 also creates a blank page after clicking next...

So I repeat my request for help ;-). I can easily share my web server directores with the 1.0.5 and 1.5.0.7 installation, each including a mysql dump of the used database.

Cheers
Martin (martin@wunderli.ch)

@pellcorp
Copy link
Owner

pellcorp commented Oct 7, 2015

Hi,

Happy to help if I can, no money required. Make sure to keep the versions
separate, just point at the same db to perform the upgrade.

Send me your 1.0.5 db dump if you can and I will take a look myself to see
what's going on.

If that goes ok on my end, I will ask to see your actual installation.

But again make sure you do not extract new version over old version, that
is guaranteed to break stuff.

@pellcorp
Copy link
Owner

pellcorp commented Oct 7, 2015

My email address is jason at pellcorp dot com

@pellcorp
Copy link
Owner

pellcorp commented Oct 8, 2015

H,

Did you upgrade to 1.6.0 on the ubuntu 14.04 server? Do you have error log
for the ubuntu 14.04.

@MartinWunderli
Copy link
Contributor

Hi
I tried both. Upgrading from 1.0.5 to 1.5.0.7 on Ubuntu 8.04 and on 14.04 (I did only once the final step from 1.5.0.7 to 1.6.0, on Ubuntu 14.04, thought it would fix the problem, but it did not). So same effect on both Ubuntus, blank page when inserting items. The last test and the error log were on Ubuntu 14.04 though. 
CheersMartin

@pellcorp
Copy link
Owner

pellcorp commented Oct 8, 2015

The error log you posted was for 1.5.0.7 though, so I need to see logs for
1.6.0 upgrade which won't have the _FILES issue as its been fixed. I did
not upgrade 1.5.0.7 to work with latest php

@pellcorp
Copy link
Owner

pellcorp commented Oct 8, 2015

I will chase down why the update_on field was changed as part of
upgrading. I can't see a reason for it in the code base, and no one else
reported it when they upgraded to 1.5.0.7 so its strange.

@pellcorp
Copy link
Owner

pellcorp commented Oct 9, 2015

I started looking at this and realised what you sent me does not seem to include a DB export of your 1.0.5 db. I don't need the php source, I need the db data, and it needs to be a phpmyadmin export or a mysql cli export, not a OpenDB export.

@pellcorp
Copy link
Owner

pellcorp commented Oct 9, 2015

Oops - sorry just noted the dmp file

@MartinWunderli
Copy link
Contributor

Thanks a lot for helping.

Currently I have Ubuntu 8.04/MySQL 5.0/OpenDB 1.0.5 and Ubuntu 14.04/MySQL 5.5/OpenDB 1.5.0.7 (upgraded from 1.0.5 on the latter machine using the special MySQL 5.5 version). The latter does not allow the adding of new iterms.

However, I can nuke both installations at any time to perform other tests.

@pellcorp
Copy link
Owner

pellcorp commented Oct 9, 2015

Ok - I have added a new 1.5.0.8 tag which includes the mysql 5.5 changes and fixes for the $_FILES issue with latest php. You can download that one and you should be able to add new items.

https://github.com/pellcorp/opendb/archive/RELEASE_1_5_0_8.zip

I also fixed the upgrade bug so that the new linked item instances will have the same date as their parent item, so new items appearing in the whatsnew upon login. So I would suggest you redo the upgrade from 1.0.5 with 1.5.0.8, and then upgrade to 1.6.0

Once you have upgraded to 1.6.0 on ubuntu 14.04 please post me your error.log from apache if there is still an issue.

BE SURE to not install 1.6.0 php files into the same directory as 1.5.0.8, that will create issues, just copy your upload/, itemcache, logs, and include/local.config.php from 1.5.0.8 install to 1.6.0

@MartinWunderli
Copy link
Contributor

Strike! Worked well, could add a DVD, no errors in the apache log for 1.6.0. Thanks a lot!

I found a little bug concerning sorting, but will open another thread for that.

@pellcorp pellcorp closed this as completed Dec 3, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants