[SOLVED] How to update database using 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
User avatar
null2
Registered User
Posts: 510
Joined: Wed Jan 20, 2010 11:03 am

[SOLVED] How to update database using CLI

Post by null2 »

I have a forum with a giant database and I always get a timeout message when updinatg it. Now, I tried to update my forum from 3.1.10 to 3.2 and result was not different.

To solve that, I used to upgrade it using CLI (php ./bin/phpbbcli.php db:migrate --safe-mode). But its not working anymore. How to do it in this last release?

In time: I tried to update it in install page using several ways, no luck with that.
Last edited by null2 on Tue Jan 17, 2017 12:59 am, edited 2 times in total.
Sorry for my bad english. I'm from USA.
Paul
Infrastructure Team Leader
Infrastructure Team Leader
Posts: 26818
Joined: Sat Dec 04, 2004 3:44 pm
Location: The netherlands.
Name: Paul Sohier
Contact:

Re: How to update database using CLI

Post by Paul »

You need to use the cli in the install/ directory. The command is:

Code: Select all

./phpbbcli.php update config.yml
And create a file config.yml with

Code: Select all

updater:
    type: db_only
This will only update the database, not the files.
Knock knock
Race condition
Who's there?

My BlogMy Photosmy phpBB Extensionscustom phpBB work & Development
User avatar
null2
Registered User
Posts: 510
Joined: Wed Jan 20, 2010 11:03 am

Re: How to update database using CLI

Post by null2 »

Worked!

But I had to do some changes:

I had to use the command in this way: php ./phpbbcli.php update config.yml

And in file config.yml, I had to put a TAB before "type" because spaces didnt work:

updater:
[TAB]type: db_only

Thank you!
Sorry for my bad english. I'm from USA.
Paul
Infrastructure Team Leader
Infrastructure Team Leader
Posts: 26818
Joined: Sat Dec 04, 2004 3:44 pm
Location: The netherlands.
Name: Paul Sohier
Contact:

Re: How to update database using CLI

Post by Paul »

The first thing depends on your server setup yeah. The second thing is a phpBB thing, as it doesn't support tabs in code tags
Knock knock
Race condition
Who's there?

My BlogMy Photosmy phpBB Extensionscustom phpBB work & Development
richey
Registered User
Posts: 617
Joined: Mon Feb 18, 2002 4:26 pm
Location: now@Cyberspace
Contact:

Re: [SOLVED] How to update database using CLI

Post by richey »

I get the error message
[ERROR] Could not parse YAML file config.yml
My config.yml looks exactly like the one described above (with the tab), otherwise it's empty. CRLF before the last line. What can I do… :?
.
User avatar
david63
Registered User
Posts: 18334
Joined: Thu Dec 19, 2002 8:08 am
Location: Lancashire, UK
Contact:

Re: [SOLVED] How to update database using CLI

Post by david63 »

richey wrote:
Tue Aug 08, 2017 7:49 am
My config.yml looks exactly like the one described above (with the tab)
Use spaces not tabs - .yml files in phpBB do not work with tabs
David
Remember: You only know what you know and - you don't know what you don't know!
My CDB Contributions | How to install an extension
I will not be accepting translations for any of my extensions in Github - please post any translations in the appropriate topic.
No support requests via PM or email as they will be ignored
Melshimber
Registered User
Posts: 55
Joined: Sun Jul 10, 2005 9:27 am

Re: [SOLVED] How to update database using CLI

Post by Melshimber »

Hiya - I get this error - any idea how to fix?

<b>Parse error</b>: syntax error, unexpected T_STRING, expecting T_CONSTANT_ENCAPSED_STRING or '(' in <b>/homepages/25/***********/htdocs/************/phpBB3/install/phpbbcli.php</b> on line <b>15</b><br />
(uiserver):u71353150:~$

M

PS removed some info from command line to make anonymous.

Please start your own topic especially especially as this one is marked as solved.
Post Reply

Return to “[3.2.x] Support Forum”