Run the update via CLI

Get help with installation and running phpBB 3.2.x here. Please do not post bug reports, feature requests, or extension related questions here.
Post Reply
water01
Registered User
Posts: 119
Joined: Tue Dec 07, 2010 11:54 am

Run the update via CLI

Post by water01 » Thu Mar 09, 2017 9:45 pm

I have successfully trialled the upgrade of my Forum via the
1.Using your web browser, visit install/ in your board's root. (e.g. http://www.example.com/yourforum/install)

method but I thought I ought to trial the CLI method as I have a 1GB Forum database.

However when I run the CLi method on a Windows host running Apache using

Code: Select all

c:/php/php.exe ./bin/phpbbcli.php cd:migrate --safe-mode
I get the following error

Code: Select all

ERROR [ mysql4 ]<br /><br />Table 'vwnutant_phpb1.phpbb3_config_text' doesn't exist [1146]<br /><br />An SQL error occurred while fetching this page. Please contact the <a href="mailto:ukpassats@ukpassats.co.uk">Board Administrator</a> if
this problem persists. in C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\ukpassats\phpbb\phpbb\db\driver\driver.php on line 999
So what am I doing wrong please?

User avatar
stevemaury
Support Team Member
Support Team Member
Posts: 50924
Joined: Thu Nov 02, 2006 12:21 am
Location: The U.P.
Name: Steve
Contact:

Re: Run the update via CLI

Post by stevemaury » Fri Mar 10, 2017 12:42 am

This implies that the config table is showing a version of 3.1.x or 3.2.x, but the tables are actually 3.0.x. 3.0.x has no config_text table, but the later two do. Are you upgrading from 3.0.x? What is the result of this query?

Code: Select all

SELECT config_value FROM phpbb_ config WHERE config_name = 'version'
Or, take the database backup you made before trialing, copy it, and run the CLI on it.
For REALLY good and VERY inexpensive hosting CLICK HERE

I can stop all your spam. I can upgrade or update your Board. PM or email me. (Paid support)

water01
Registered User
Posts: 119
Joined: Tue Dec 07, 2010 11:54 am

Re: Run the update via CLI

Post by water01 » Fri Mar 10, 2017 8:00 am

Thank you for your reply.

I had to change the SQL to

Code: Select all

SELECT config_value FROM phpbb3_config WHERE config_name = 'version'
and that returned config_value = 3.0.12 which is correct as I am upgrading from that version to 3.2.

swa66
Registered User
Posts: 9
Joined: Wed Jun 03, 2009 8:59 am

Re: Run the update via CLI

Post by swa66 » Tue Jun 13, 2017 2:13 am

I see as far as I can tell exactly the same problem while trying to move a board from one server to another while upgrading. On ly difference so far: I'm trying the upgrade from 3.0.10

Following this: https://www.phpbb.com/support/docs/en/3 ... /upgrade3/
I'm at step 12 - using the tip to use cli instead of the web version:

Code: Select all

$ php ./bin/phpbbcli.php db:migrate --safemode
PHP Fatal error:  SQL ERROR [ mysqli ]<br /><br />Table '<DB>.<PREFIX>_config_text' doesn't exist [1146]<br /><br />An SQL error occurred while fetching this page. Please contact the <a href="mailto:<ADDRESS>">Board Administrator</a> if this problem persists. in <DOCROOT>/phpbb/db/driver/driver.php on line 999
Table <prefix>_config_text simply doesn't exist on 3.0 versions AFAIK.

I'm confused:
Why is the script that supposed to do the update of the database [according to https://www.phpbb.com/support/docs/en/3 ... /upgrade3/ ] failing on a nonexisting table when it's not supposed to exist in the first place ?

FWIW:

Code: Select all

> SELECT config_value FROM <PREFIX>_config WHERE config_name = 'version';
+--------------+
| config_value |
+--------------+
| 3.0.10       |
+--------------+
1 row in set (0.00 sec)
Trying to do a few testruns before the big change: upgrade to 3.2.0 (along with updates from apache -> nginx ; mysql -> mariadb; different OS, different hardware etc. Can't do all that with live users without some confidence this will work ...

Andy_123
Registered User
Posts: 4
Joined: Thu Aug 17, 2017 3:59 pm

Re: Run the update via CLI

Post by Andy_123 » Thu Aug 17, 2017 4:04 pm

Hi,

i am trying to update my forum from version 3.0.5 to 3.2.1 and i get exactly the same error:

Code: Select all

php ./bin/phpbbcli.php db:migrate --safe-mode
PHP Fatal error:  SQL ERROR [ mysql4 ]<br /><br />Table '***.phpbb3_config_text' doesn't exist [1146]<br /><br />An SQL error occurred while fetching this page. Please contact the <a href="mailto:***">Board Administrator</a> if this problem persists. in ***/phpbb/db/driver/driver.php on line 999
Here is the forum version:

Code: Select all

SELECT config_value FROM phpbb_ config WHERE config_name = 'version';
ERROR 1146 (42S02): Table '***.phpbb_' doesn't exist
mysql> SELECT config_value FROM phpbb3_config WHERE config_name = 'version';
+--------------+
| config_value |
+--------------+
| 3.0.5        |
+--------------+
1 row in set (0.00 sec)
Could anyone please give me a hint on how to fix this? I am stuck at point 12. of this: https://www.phpbb.com/support/docs/en/3 ... /upgrade3/ guide and am not able to update my forum.

Best regards,
Andy

User avatar
thecoalman
Community Team Member
Community Team Member
Posts: 3399
Joined: Wed Dec 22, 2004 3:52 am
Location: Pennsylvania, U.S.A.
Contact:

Re: Run the update via CLI

Post by thecoalman » Thu Aug 17, 2017 4:21 pm

I had this happen to me while I was doing some test conversion runs, forget what the issue was but it might be blank config.php file or cache issue.Whatever it was it was one those Doh! things.
“Results! Why, man, I have gotten a lot of results! I have found several thousand things that won’t work.”

Attributed - Thomas Edison

Andy_123
Registered User
Posts: 4
Joined: Thu Aug 17, 2017 3:59 pm

Re: Run the update via CLI

Post by Andy_123 » Thu Aug 17, 2017 5:03 pm

Well, in my case it's correctly referring to a non existing mysql table. This looks like a general problem to me.

I did everything the guild told me to do, which means i replaced almost all files and folders but the few who hold uploaded data and the config file of course.

Not sure what else i can try, as i said, this looks like a bug in the migration script to me.

User avatar
thecoalman
Community Team Member
Community Team Member
Posts: 3399
Joined: Wed Dec 22, 2004 3:52 am
Location: Pennsylvania, U.S.A.
Contact:

Re: Run the update via CLI

Post by thecoalman » Thu Aug 17, 2017 8:50 pm

Andy_123 wrote:
Thu Aug 17, 2017 5:03 pm
Well, in my case it's correctly referring to a non existing mysql table.
Correct, it was same error I had. Like I said it was a simple fix but I don't remember what it was. Try hitting ctrl- f5.
“Results! Why, man, I have gotten a lot of results! I have found several thousand things that won’t work.”

Attributed - Thomas Edison

User avatar
canonknipser
Registered User
Posts: 2096
Joined: Thu Sep 08, 2011 4:16 am
Location: Germany
Name: Frank Jakobs
Contact:

Re: Run the update via CLI

Post by canonknipser » Thu Aug 17, 2017 9:10 pm

As far as I remember, there is an error in the order of the migration files used for db upgrading.
See:
https://tracker.phpbb.com/browse/PHPBB3-15112

Maybe it's worth a try to upgrade first to the latest 3.0-Version (3.0.14) and afterwards update to 3.2.1
Greetings, Frank
phpbb.de support team member
English is not my native language - no support via PM or mail
New arrival - Extensions and scripts for phpBB

Andy_123
Registered User
Posts: 4
Joined: Thu Aug 17, 2017 3:59 pm

Re: Run the update via CLI

Post by Andy_123 » Thu Aug 17, 2017 9:58 pm

canonknipser wrote:
Thu Aug 17, 2017 9:10 pm
As far as I remember, there is an error in the order of the migration files used for db upgrading.
See:
https://tracker.phpbb.com/browse/PHPBB3-15112

Maybe it's worth a try to upgrade first to the latest 3.0-Version (3.0.14) and afterwards update to 3.2.1
That sounds like something that should be fixed. :) Anyways, thx for letting me know. Tomorrow I will try to update to an older version first.

Maybe from my version to 3.1.* works.

Andy_123
Registered User
Posts: 4
Joined: Thu Aug 17, 2017 3:59 pm

Re: Run the update via CLI

Post by Andy_123 » Fri Aug 18, 2017 2:28 pm

Just to let everyone know.

After multiple tries i had to update from 3.0.0.5 -> 3.0.0.14 -> 3.1.11 -> 3.2.1 to make it work.
All other attempts ended in some kind of problem i was not able to resolve.

Even the final solution did not work flawlessly but hey, i hope it all goes well when i migrate the production system.

Post Reply

Return to “[3.2.x] Support Forum”