Problem migrating 3.0.14 to 3.1.10

Get help with installation and running phpBB 3.1.x here. Please do not post bug reports, feature requests, or extension related questions here.
Get Involved
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

NOTE: phpBB 3.1.x is at its End of Life stage and support will NOT be provided after July 1st, 2018.
User avatar
javiexin
Code Contributor
Posts: 1157
Joined: Wed Oct 12, 2011 11:46 pm
Location: Madrid, Spain
Name: Javier
Contact:

Problem migrating 3.0.14 to 3.1.10

Post by javiexin » Sat Nov 05, 2016 5:05 pm

Hi,

I am trying to migrate my heavily modded forum, currently on 3.0.14, to 3.1.10.

To do that, I am testing in a copy forum (where I have replicated all the live forum content, changing only the subdomain where it is installed).

These are the steps I have taken:
  • Backup the live forum
  • Change in SQL all references to the live subforum folder to the test subforum folder
  • Create new DB and load the updated SQL
  • Copy all the files from the modded forum to the test forum, test it works fine (changing config.php)
  • Remove all modded files, replace with all standard (official) files from 3.0.14; only keep config.php, images/*, files/*, store/*
  • Install STK on the test forum (latest 3.0 version)
  • Run STK Database cleaner - now the DB should be "clean", without mod contents
  • Remove all 3.0 files, copy all standard (official) files from 3.1.10; except config.php, images/*, files/*, store/*
  • Run <newlocation>/install/database_update.php
And here here is where it fails...

First, there was a problem with a phpBB Debug warning: module_id undefined in line 200 of phpbb/db/migration/tool/module.php. This was an exception being thrown, but given this warning, no message came up. I figured that this might be related to THIS fix, so I applied it (this is already merged, so planned for inclusion in 3.1.11). This fixed the warning, but not the underlying error, that persists. This is the error that can be seen now.

Code: Select all

Database type :: mysqli
Previous version :: 3.0.14
A module already exists: ACP_MANAGE_ATTACHMENTS 
This is happening while trying to execute phpbb\db\migration\data\v310\dev.php. All previous steps seem to have worked just fine, but now I am stuck there...

This seems to be related to the migration changes introduced in 3.1.10, but I cannot find how to download a 3.1.9 version any longer (to try the migration to 3.1.9, and then upgrade to 3.1.10), and the applied fix is not complete, from what I can see, or there might be some other issue.

Any clue as to why or what to do to continue upgrade?
Thanks,
-javiexin

User avatar
Puchahawa
Registered User
Posts: 768
Joined: Sat Jan 01, 2011 10:33 pm
Name: Randy

Re: Problem migrating 3.0.14 to 3.1.10

Post by Puchahawa » Sat Nov 05, 2016 5:24 pm

I can't answer your error problem but you can get 3.1.9 here. Click 3.1.9 and it will bring up the different migration options.
Avatar courtesy of artist Faith Coyotë

User avatar
javiexin
Code Contributor
Posts: 1157
Joined: Wed Oct 12, 2011 11:46 pm
Location: Madrid, Spain
Name: Javier
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by javiexin » Sat Nov 05, 2016 5:28 pm

Thanks a lot, I will try it tomorrow (just in case someone knows how to fix the error without going through the process again).

-javiexin

User avatar
Lumpy Burgertushie
Registered User
Posts: 66478
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by Lumpy Burgertushie » Sat Nov 05, 2016 5:28 pm

I would suggest that you access your database using phpmyadmin or whatever you have and empty/truncate the migrations table and then run the database_update.php file again.
make sure that you click the continue button until you get a success message on that page.
each page may take some time so don't be impatient.

robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.2 Styles by PlanetStyles.net

If a tree falls in the forest and nobody is there, does it make a sound?

User avatar
javiexin
Code Contributor
Posts: 1157
Joined: Wed Oct 12, 2011 11:46 pm
Location: Madrid, Spain
Name: Javier
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by javiexin » Sun Nov 06, 2016 12:10 am

Done a couple of times already, and It always stops at this same point. No chance to push continue.

User avatar
3Di
Former Team Member
Posts: 13902
Joined: Mon Apr 04, 2005 11:09 pm
Location: Milan (IT) Frankfurt (DE)
Name: Marco
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by 3Di » Sun Nov 06, 2016 12:55 am

javiexin wrote:Thanks a lot, I will try it tomorrow (just in case someone knows how to fix the error without going through the process again).

-javiexin
That's your best choice, be sure. Redo it using 3.1.9.
Regards.
Please PM me only to request paid works. Thx.
Want to compensate me for my interest? Donate
My development's activity º PhpStorm's proud user
Extensions, Scripts, MOD porting, Update/Upgrades
👨‍🏫 | Take a tour to | The Studio | 👨‍🏫

User avatar
javiexin
Code Contributor
Posts: 1157
Joined: Wed Oct 12, 2011 11:46 pm
Location: Madrid, Spain
Name: Javier
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by javiexin » Sun Nov 06, 2016 1:24 pm

Hi,

Short update: I have tried to move to 3.1.9 by replacing the files with a clean new 3.1.9 installation, and it definitely went past the place where it was blocked before.

It has NOT completed yet, even after a couple of restarts (truncating the migrations table first). It gets stuck now in the softdelete_p1 and softdelete_p2 migrations...

Will continue testing. In the meantime, should I open a new Tracker ticket against this problem? It is definitely introduced by 3.1.10, and the proposed changes for 3.1.11 do not solve the issue (as far as I can tell).

Regards,
-javiexin

rxu
Extensions Development Team
Posts: 2945
Joined: Wed Oct 25, 2006 12:46 pm
Location: Siberia, Russian Federation
Name: Ruslan
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by rxu » Sun Nov 06, 2016 1:43 pm

javiexin wrote:A module already exists: ACP_MANAGE_ATTACHMENTS
That is probably because the module exists actually, presumably because the Manage attachments ACP module for phpBB3 MOD was installed on your old board.
You can try deleting the module in 3.0.14 via ACP first before you start the migration.

User avatar
javiexin
Code Contributor
Posts: 1157
Joined: Wed Oct 12, 2011 11:46 pm
Location: Madrid, Spain
Name: Javier
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by javiexin » Sun Nov 06, 2016 2:11 pm

I reset the modules via the STK before starting the migration process...

If that is the case, then the issue is with STK not removing this extra module, right?

PS: And, by the way, why would it work then in 3.1.9 and not in 3.1.10?

rxu
Extensions Development Team
Posts: 2945
Joined: Wed Oct 25, 2006 12:46 pm
Location: Siberia, Russian Federation
Name: Ruslan
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by rxu » Sun Nov 06, 2016 2:58 pm

javiexin wrote:why would it work then in 3.1.9 and not in 3.1.10
Because more strictness was added to the modules installation system.

User avatar
3Di
Former Team Member
Posts: 13902
Joined: Mon Apr 04, 2005 11:09 pm
Location: Milan (IT) Frankfurt (DE)
Name: Marco
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by 3Di » Mon Nov 07, 2016 1:13 am

rxu wrote:
javiexin wrote:A module already exists: ACP_MANAGE_ATTACHMENTS
That is probably because the module exists actually, presumably because the Manage attachments ACP module for phpBB3 MOD was installed on your old board.
You can try deleting the module in 3.0.14 via ACP first before you start the migration.
You're right, in fact your MOD (for phpBB 3.0.0, released on Mar 14, 2008) adds a module with the exact name of the phpBB 3.1.x's one, here the issue lies within the choice of this module name also for 3.1 I can say.

In fact both the STK and my MODission_reset tool doesn't check for the presence of it in phpBB 3.0.
My tool consider it a true part of phpBB 3.1 and accurately avoid to remove it. So does STK, at a first glance reading its code.

On a side note, i still suggest to avoid upgrading 3.0.x to 3.1.10 but 3.1.9 for the reasons you already stated.

@ javiexin can you confirm you had that MOD installed before?

Regards.
Please PM me only to request paid works. Thx.
Want to compensate me for my interest? Donate
My development's activity º PhpStorm's proud user
Extensions, Scripts, MOD porting, Update/Upgrades
👨‍🏫 | Take a tour to | The Studio | 👨‍🏫

User avatar
javiexin
Code Contributor
Posts: 1157
Joined: Wed Oct 12, 2011 11:46 pm
Location: Madrid, Spain
Name: Javier
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by javiexin » Mon Nov 07, 2016 2:21 am

Yes, I did have the MOD installed.

Now, I am testing again, going straight to 3.1.10, because I did check that after cleaning with STK, the modules table did not have any ACP_MANAGE_ATTACHMENTS module. And it went pass this point.

It seems to me that, before, I run the STK BEFORE removing the old files, and the module somehow got recreated (form the existing acp_info file I guess). Now, I have run STK AFTER deleting the moded files, and installing the clean 3.0.14 files, and thus the module did not get recreated.

But now I am stuck in something else...

This is the new error that I am getting:

Code: Select all

Installing Schema: \phpbb\db\migration\data\v310\profilefield_interests.
Installed Schema: \phpbb\db\migration\data\v310\profilefield_interests; Time: 0.38 seconds
Installing Data: \phpbb\db\migration\data\v310\profilefield_interests.

Fatal error: Uncaught exception 'Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException' 
with message 'You have requested a non-existent service "10".' in vendor\symfony\dependency-injection\Symfony\Component\DependencyInjection\ContainerBuilder.php:806 
Stack trace: 
	#0 vendor\symfony\dependency-injection\Symfony\Component\DependencyInjection\ContainerBuilder.php(444): Symfony\Component\DependencyInjection\ContainerBuilder->getDefinition('10') 	
	#1 phpbb\di\service_collection.php(66): Symfony\Component\DependencyInjection\ContainerBuilder->get('10') 
	#2 phpbb\profilefields\manager.php(495): phpbb\di\service_collection->offsetGet('10') 
	#3 phpbb\db\migration\profilefield_base_migra in vendor\symfony\dependency-injection\Symfony\Component\DependencyInjection\ContainerBuilder.php on line 806
Thanks for all your help and guidance,
-javiexin

User avatar
3Di
Former Team Member
Posts: 13902
Joined: Mon Apr 04, 2005 11:09 pm
Location: Milan (IT) Frankfurt (DE)
Name: Marco
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by 3Di » Mon Nov 07, 2016 3:55 am

I am not an real insider of the STK, I read and understand code when I need or will ..
I havent read it all. :) And I didn't write it. All of the times I used it for my customers' need I went using it replacing (before of all) all the files related to the phpBB's version (ie: virgin 3.0.14 files for a modded 3.0.14). Yours it seems to me a special case.

Once again, I am suggesting to forget about the esistence of phpBB 3.1.10 and go toward this way.

For the sake of see this topic solved, hopefully.

Regards.
Please PM me only to request paid works. Thx.
Want to compensate me for my interest? Donate
My development's activity º PhpStorm's proud user
Extensions, Scripts, MOD porting, Update/Upgrades
👨‍🏫 | Take a tour to | The Studio | 👨‍🏫

User avatar
javiexin
Code Contributor
Posts: 1157
Joined: Wed Oct 12, 2011 11:46 pm
Location: Madrid, Spain
Name: Javier
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by javiexin » Mon Nov 07, 2016 11:37 am

Definitely, 3.1.10 CANNOT be used for a relatively complex migration.

Given the above problem, I had to rerun database_update after truncating the migrations table.
And voila, the error on "Module already exists" reappeared, this time for an OAUTH module.

This tells me that with the new extra secure checks for module migrations, the EXISTING migrations are not quite right, possibly because they do not have correct checks for previous installation of the migration (effectively_installed), or because they try to always install modules, while these might be already existing (maybe this should be checked with one of those infamous "if" in the migrations files...).

Now, back to square 0, restarting the migration, this time to 3.1.9. So yes, 3Di, I am following your suggestion now!

This is really tedious AND very error prone...

-javiexin

User avatar
javiexin
Code Contributor
Posts: 1157
Joined: Wed Oct 12, 2011 11:46 pm
Location: Madrid, Spain
Name: Javier
Contact:

Re: Problem migrating 3.0.14 to 3.1.10

Post by javiexin » Mon Nov 07, 2016 11:53 pm

For the record, I have now been able to complete the migration to 3.1.9, then on to 3.1.10.

However, I should warn everyone about problems with some specific mods that I had installed in 3.0 and that have created problems when moving.
  • Manage attachments ACP module: make sure that the includes/acp/info file created by this mod is NOT present in your system when you run STK to remove all previous mods, or else, it will get recreated
  • Forum Sort Order: make sure to revert the changes to the users table, following the process outlined HERE; you don't need to worry about the forums table, that is taken care for from STK
  • Special Profile Fields, such as Multiple Selection Profile Fields: make sure that your profile_fields tables are clean when you attempt the migration; best way is to remove all the custom profile fields before starting the migration (specially those that have non-standard types MUST be removed); as this is tricky, you might prefer to remove completely all the profile_fields tables, and have the STK to recreate them cleanly
This list might not be complete, but at least should warn some users of potential pitfalls when upgrading to 3.1.

Now, I only need to figure out how to change all SEO URLs in post texts into regular URLs, and reparse the BBCodes, to have a fully functional "vanilla" 3.1 system. And then, continue installing and testing the corresponding extensions to the functionalities we need.

Thanks for your help and pointers.
-javiexin

Locked

Return to “[3.1.x] Support Forum”