# Ghost upgrade from 4.44.0 to 4.46.0 breaks ghost

**URL:** <https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858>\
**Category:** Self-hosting\
**Created:** [April 30, 2022, 2:46am UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858 "2022-04-30T02:46:47Z")\
**Posts on this page:** 20\
**Page:** 2

<div class="post-metadata">

**Author:** ![mjw](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/mjw/32/30781_2.png) [@mjw](https://forum.ghost.org/u/mjw)\
**Post date:** [May 4, 2022, 5:57pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/21 "2022-05-04T17:57:36Z")

</div>

Can you roll back? If you can, start planning for an migration to MySQL.

---

<div class="post-metadata">

**Author:** ![Darkice2](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/darkice2/32/20459_2.png) [@Darkice2](https://forum.ghost.org/u/Darkice2)\
**Post date:** [May 4, 2022, 6:12pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/22 "2022-05-04T18:12:58Z")

</div>

Unable to rollback I guess that’s it for 2 of my websites lol… Not sure I understand why both databases can’t be supported… Just use the “basics” of each languages without over complicating/over-optimizing things… Is it better to be “perfect” in the design or have both systems work? Because many people are probably in the same situation where they have to use MariaDB

Was the change to a “newsletter” table (I have never even sent a newsletter…) so important to make that change and break everything?

---

<div class="post-metadata">

**Author:** ![mjw](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/mjw/32/30781_2.png) [@mjw](https://forum.ghost.org/u/mjw)\
**Post date:** [May 4, 2022, 6:42pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/23 "2022-05-04T18:42:52Z")

</div>

> [@Darkice2](#):
>
> Unable to rollback I guess that’s it for 2 of my websites lol…

Can’t you create a clone of your server, and then restore an earlier snapshot? If you do that, you’ve got options.

> [@Darkice2](#):
>
> Not sure I understand why both databases can’t be supported…

It’s a lot more effort for a small dev team to support another database. They’ve always been upfront about MySQL tool. I only heeded their warning a few weeks ago, and I’m glad I switched. :smug:

I hope you get it sorted.

---

<div class="post-metadata">

**Author:** ![Darkice2](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/darkice2/32/20459_2.png) [@Darkice2](https://forum.ghost.org/u/Darkice2)\
**Post date:** [May 4, 2022, 6:50pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/24 "2022-05-04T18:50:49Z")

</div>

I could restore a snapshot but not willing to go through all this effort, because my other site running XenForo with 1.2 million posts would lose a few days of data.

BTW XenForo works “fine” with either MySQL or MariaDB as it is supposed to be “drop in support”.

> **[XF 2.0 - MariaDB Support?](https://xenforo.com/community/threads/mariadb-support.142761/)**
>
> Just to confirm (was unable to check in system requirements listed), is MariaDB supported by XF2?

I still don’t understand why both can’t work together if it is supposed to be drop in support… unless you are using some very very obscure options I don’t see why everything needs to break

---

<div class="post-metadata">

**Author:** ![mjw](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/mjw/32/30781_2.png) [@mjw](https://forum.ghost.org/u/mjw)\
**Post date:** [May 4, 2022, 6:57pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/25 "2022-05-04T18:57:44Z")

</div>

> [@Darkice2](#):
>
> I could restore a snapshot but not willing to go through all this effort, because my other site running XenForo with 1.2 million posts would lose a few days of data.

That’s why I suggested a clone first; work on this, not your production instance.

---

<div class="post-metadata">

**Author:** ![ghost1](https://avatars.discourse-cdn.com/v4/letter/g/59ef9b/32.png) [@ghost1](https://forum.ghost.org/u/ghost1)\
**Post date:** [May 5, 2022, 7:05am UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/26 "2022-05-05T07:05:56Z")

</div>

That’s nice advice for someone running it as VM, but not so much help if you’re running on physical hardware.

---

<div class="post-metadata">

**Author:** ![mjw](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/mjw/32/30781_2.png) [@mjw](https://forum.ghost.org/u/mjw)\
**Post date:** [May 5, 2022, 8:13am UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/27 "2022-05-05T08:13:15Z")

</div>

The OP, who I was replying to, has a VM. IIRC you were able to perform a rollback. Nonetheless, snapshots are possible without a VM and so is a rollback strategy.

---

<div class="post-metadata">

**Author:** ![ghost1](https://avatars.discourse-cdn.com/v4/letter/g/59ef9b/32.png) [@ghost1](https://forum.ghost.org/u/ghost1)\
**Post date:** [May 5, 2022, 11:11am UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/28 "2022-05-05T11:11:27Z")

</div>

So when you are referring to snapshots, would you share a little more information or maybe link to the documentation if there is this topic covered?

---

<div class="post-metadata">

**Author:** ![mjw](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/mjw/32/30781_2.png) [@mjw](https://forum.ghost.org/u/mjw)\
**Post date:** [May 5, 2022, 12:22pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/29 "2022-05-05T12:22:46Z")

</div>

> [@ghost1](#):
>
> So when you are referring to snapshots, would you share a little more information or maybe link to the documentation if there is this topic covered?

This is OS-dependent, and going off-topic. Nonetheless, snapshots are available with LVM, `btrfs` and `zfs`. Likewise, a good backup strategy will help you roll-back. Same goes for MariaDB…`mysqldump`, `automysqlbackup` etc.

> [@ghost1](#):
>
> Today I tried to upgrade Ghost from v4.42.0 to v4.46.2 which failed. Rollback worked for me though.

If you’re still up and running on MariaDB, now is the time to migrate to MySQL.

---

<div class="post-metadata">

**Author:** ![ghost1](https://avatars.discourse-cdn.com/v4/letter/g/59ef9b/32.png) [@ghost1](https://forum.ghost.org/u/ghost1)\
**Post date:** [May 7, 2022, 8:26am UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/30 "2022-05-07T08:26:55Z")

</div>

> [@mjw](#):
>
> This is OS-dependent, and going off-topic. Nonetheless, snapshots are available with LVM, `btrfs` and `zfs` . Likewise, a good backup strategy will help you roll-back. Same goes for MariaDB… `mysqldump` , `automysqlbackup` etc.

Thank you mjw. I wasn’t aware of LVM feature being able to do snapshots. This is a game-changer 🙂

---

<div class="post-metadata">

**Author:** ![Darkice2](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/darkice2/32/20459_2.png) [@Darkice2](https://forum.ghost.org/u/Darkice2)\
**Post date:** [May 7, 2022, 6:17pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/31 "2022-05-07T18:17:05Z")

</div>

I will hire someone to do the attempted migration of MariaDB to MySQL on my server and get Ghost working again. I can snapshot the server first, so even if the attempt is an epic fail, I can restore and my large XenForo site will not be impacted.

If interested please reply here or send me a direct message.

---

<div class="post-metadata">

**Author:** ![Peter\_Sauer](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/peter_sauer/32/16252_2.png) [@Peter\_Sauer](https://forum.ghost.org/u/Peter_Sauer)\
**Post date:** [May 10, 2022, 7:17pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/32 "2022-05-10T19:17:30Z")

</div>

I have an older backup of my VM. But I would prefer to fix this problem until a offical solution is available. Is there a way to skip the errnous alter table command during start

`alter table newsletters modify ...`

manullay?. I didn’t use newsletter for my blog.

---

<div class="post-metadata">

**Author:** ![mjw](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/mjw/32/30781_2.png) [@mjw](https://forum.ghost.org/u/mjw)\
**Post date:** [May 11, 2022, 11:24am UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/33 "2022-05-11T11:24:10Z")

</div>

> [@Peter\_Sauer](#):
>
> …until a offical solution is available.

I can’t speak for the Ghost team, but note that MariaDB isn’t officially supported, so there is no guarantee that there will be a fix. Moreover, Ghost 5.0 will definitely introduce breaking changes for MariaDB users.

For continuity, all MariaDB users should be planning to migrate their Ghost database to MySQL.

---

<div class="post-metadata">

**Author:** ![fehwalker](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/fehwalker/32/287_2.png) [@fehwalker](https://forum.ghost.org/u/fehwalker)\
**Post date:** [May 11, 2022, 1:02pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/34 "2022-05-11T13:02:28Z")

</div>

Also seeing this issue upgrading from 4.44.0 to 4.47.1.

I won’t be using an Oracle product, so sounds like it’s time to migrate to another site platform.

---

<div class="post-metadata">

**Author:** ![heyakyra](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/heyakyra/32/5478_2.png) [@heyakyra](https://forum.ghost.org/u/heyakyra)\
**Post date:** [May 13, 2022, 1:28pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/35 "2022-05-13T13:28:42Z")

</div>

> I won’t be using an Oracle product, so sounds like it’s time to migrate to another site platform.

Yeah, seriously. I’m switching to [WriteFreely](https://github.com/writeas/writefreely/) which is written in Go, much cleaner, supports federation with ActivityPub, and has a more powerful theming engine in the works.

---

<div class="post-metadata">

**Author:** ![fehwalker](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/fehwalker/32/287_2.png) [@fehwalker](https://forum.ghost.org/u/fehwalker)\
**Post date:** [May 13, 2022, 2:00pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/36 "2022-05-13T14:00:11Z")

</div>

My requirements are pretty simple and I have no issues writing markdown, so I’ve already moved my two sites to Jekyll and the Minimal Mistakes theme. The jekyll\_ghost\_importer tool was quite useful. 🤷

---

<div class="post-metadata">

**Author:** ![Darkice2](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/darkice2/32/20459_2.png) [@Darkice2](https://forum.ghost.org/u/Darkice2)\
**Post date:** [May 14, 2022, 12:11am UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/37 "2022-05-14T00:11:15Z")

</div>

Was the change to the “newsletter” db that broke this so critical for performance that it absolutely had to be done, and break all the compatibility? If stick to a more simple table schema/structure, I would think the drop in replacement DB would work as needed – no need to overcomplicate things. I realize that I didn’t write this software and may just be missing something about how it was “absolutely” needed to make whatever the change was, but can the Ghost team revisit if it was really imperative?

I mentioned this before-- I never even sent a newsletter before and never planned to, yet this crashed everything for me. Could there at least be an option added to only do the “upgrade” for people that use newsletters? It doesn’t make sense to break a lot of sites when people don’t sent or use newsletters

---

<div class="post-metadata">

**Author:** ![Boryl](https://avatars.discourse-cdn.com/v4/letter/b/8491ac/32.png) [@Boryl](https://forum.ghost.org/u/Boryl)\
**Post date:** [May 17, 2022, 3:09pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/39 "2022-05-17T15:09:24Z")

</div>

Still Ghost is not compatible with MariaDB.

---

<div class="post-metadata">

**Author:** ![John](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/john/32/29288_2.png) [@John](https://forum.ghost.org/u/John)\
**Post date:** [May 19, 2022, 4:45pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/40 "2022-05-19T16:45:04Z")

</div>

We were moving our recommended environment from MySQL5 to MySQL8 regardless, nothing to do with newsletters.

Ghost is a small team, so we make Ghost work according to a single recommended/supported environment, which is tested and documented in detail.

If you _choose_ to use a different environment to what is documented and recommended, that’s fine, but your mileage may vary as a result.

For specific issues with MariaDB and Knex - the place to raise/discuss/resolve that is on the Knex repository or community. We are not the maintainers of Knex:

> <https://github.com/knex/knex/issues/5154>
>
> \# Environment
> 
> Knex version: 2.0.0
> Database + version: \`10.5.15-MariaDB-0+deb…11u1\`
> OS: Linux
> 
> \# Bug
> 
> refs https://github.com/TryGhost/Ghost/issues/14634
> 
> We've ran into a problem in Ghost where we're unable to drop nullable from a column. It specifically seems to be an issue on MariaDB and after investigation, it seems MariaDB 10.2.7+ returns the default value as a string (\`COLUMN\_DEFAULT\` in https://mariadb.com/kb/en/information-schema-columns-table/), which Knex uses for the column info and appends to the column modify query.
> 
> \[This\](https://github.com/knex/knex/blob/2670c2f8b563bb2ddcbf292172af0c57ed02c16f/lib/schema/tablecompiler.js#L328-L337) block of code seems to append \`default: 'NULL'\`.
> 
> My column was created by Knex and the SQL was:
> 
> \`\`\`sql
> alter table \`newsletters\` add \`created\_at\` datetime null
> \`\`\`
> 
> after we populate it, we try and drop the nullable using \`.dropNullable()\`:
> 
> \`\`\`sql
> alter table \`newsletters\` modify \`created\_at\` datetime not null default 'NULL'
> \`\`\`
> 
> Note: \`default 'NULL'\` is incorrect and causing the issue.
> 
> To test, I printed out \`val\` here: https://github.com/knex/knex/blob/2670c2f8b563bb2ddcbf292172af0c57ed02c16f/lib/dialects/mysql/query/mysql-querycompiler.js#L132
> 
> \`\`\`
> {
> TABLE\_CATALOG: 'def',
> TABLE\_SCHEMA: 'ghost',
> TABLE\_NAME: 'newsletters',
> COLUMN\_NAME: 'created\_at',
> ORDINAL\_POSITION: 21,
> COLUMN\_DEFAULT: 'NULL',
> ...
> }
> \`\`\`
> 
> I would expect the SQL to be:
> 
> \`\`\`sql
> alter table \`newsletters\` modify \`created\_at\` datetime not null
> \`\`\`

---

<div class="post-metadata">

**Author:** ![John](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/john/32/29288_2.png) [@John](https://forum.ghost.org/u/John)\
**Post date:** [May 19, 2022, 4:45pm UTC](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858/41 "2022-05-19T16:45:21Z")

</div>

Closed on May 19, 2022, 4:45pm UTC



[Previous page](https://forum.ghost.org/t/ghost-upgrade-from-4-44-0-to-4-46-0-breaks-ghost/29858.md?page=1)
