Upgrade to 4.2.0 boot error? Missing table?

Hi everyone,

I had v3.42.4 installed and tried to do ghost update to update to version 4, however I got this message at the end of the update process:

Message: Ghost was able to start, but errored during boot with: UPDATE members_paid_subscription_events SET mrr_delta = ROUND(mrr_delta * 2) WHERE from_plan = to_plan - ER_NO_SUCH_TABLE: Table ‘ghost_prod.members_paid_subscription_events’ doesn’t exist
Suggestion: journalctl -u ghost_blog-aonghas-com -n 50

Debug Information:
OS: Ubuntu, v20.04.2 LTS
Node Version: v14.15.4
Ghost Version: 4.2.0
Ghost-CLI Version: 1.16.3
Environment: production
Command: ‘ghost start’

Additional log info available in: /home/ghostuser/.ghost/logs/ghost-cli-debug-2021-04-12T15_05_21_807Z.log

Try running ghost doctor to check your system for known issues.

Running ghost doctor does not give any errors. I had a pretty clean v3 set up without modifying anything so it’s a bit odd… can I just create this ghost_prod.members_paid_subscription_events table manually somehow and try to rerun the update?

Thanks!
Aonghas

1 Like

Having same problem.
Thinking on migration to another new deployment but current stripe subscription can’t be moved for some reason

1 Like

Anyone else?

Same behavior here. I was updating from 2.38.3 to 4.2.2 (using ghost update) and ended up with exactly the same error as you have: ER _NO_SUCH_TABLE: Table 'ghost_prod.members_paid_subscription_events' doesn't exist

My system:

  • OS: Debian GNU/Linux, v9, 4.15
  • Node Version: v10.24.1
  • Ghost Version: 4.2.2
  • Ghost-CLI Version: 1.16.3
  • Environment: production

Any advice?

Same problem here. Have tried forced upgrade, clean install of version 4 and importing data. Nothing works. Stuck at version 3.42.5 at the moment.

Hi anyone found a solution? I have the exact same problem. Updated ghost and now it does not start because the table members_paid_subscription_events does not exist.

Same issue here. Have tried the upgrade a few times. Tempted to go in and manually create the table and see if that works.

OS: Debian GNU/Linux, v10
Node Version: v14.16.1
Ghost Version: 4.2.2
Ghost-CLI Version: 1.16.3
Environment: production

Upgraded from Debian 9 to 10 and problem existed on both.

I succeeded upgrading Ghost to v4.2.2 and solve the missing table issue by following each step proposed by Hanna in this thread: Error while starting instance after updating to 2.x from 1.x

In my case I had to do ghost update --v2 --force (in the thread she asked to do ghost update --v1 --force

The thread you linked to is a bit confusing to me. It’s not really clear which actions to take as the discussion is a bit nested.
May I ask you to provide actions you did step by step?
Thanks a lot!

The first part of the thread that I linked to is about getting logs to have more context, such as list of migrations, of what caused the error. I will skip that and go to the part that made the difference. Here is the exact sequence of commands I ran and for which you find more explanation in the post I linked before:

  1. ls -al versions to check which versions I had installed
  2. ln -sfn /var/www/ghost/versions/1.26.2 current
  3. ghost run
  4. ghost update --v1 --force This did not work
  5. ghost update --v2 --force This solved it because apparently it triggered the migrations and the missing table was created. After this command ghost was updated to version 4.2.2.

Perhaps it is important to note that before the upgrade I was on version 1.26.2 which is probably why going back to v2 was necessary for me.

Hope it helps