# Hoe kan ik migreren van Discourse Hosted naar zelf hosten

**URL:** https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728
**Category:** Self-hosting
**Tags:** hosted-support, hosting
**Created:** [25 oktober 2024 om 07:13 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728 "2024-10-25T07:13:30Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![Sidi\_Codet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sidi_codet/32/455699_2.png) [@Sidi\_Codet](https://meta.discourse.org/u/Sidi_Codet)
#### Post date: [25 oktober 2024 om 07:13 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/1 "2024-10-25T07:13:30Z")

</div>

We were previously using Discourse Hosted, but we’ve moved to self-hosting. How can we transfer our data from Discourse Hosted to our self-hosted setup?

Thank you in advance!

---

<div class="post-metadata">

### Author: ![Moin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/moin/32/554653_2.png) [@Moin](https://meta.discourse.org/u/Moin)
#### Post date: [25 oktober 2024 om 07:26 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/3 "2024-10-25T07:26:33Z")

</div>

You can ask for a backup including all uploads. But I think you also get one when you cancel the hosting. (I think asking the Discourse team instead of the community support could lead to a more detailed answer, because they know the process better than random members of the community.)

> [@How do I cancel my hosting plan?](https://meta.discourse.org/t/how-do-i-cancel-my-hosting-plan/306413/1):
>
> As part of the cancellation process, a complete backup, including all uploads associated with your site, will be generated and made available for download. Please ensure that you keep this backup in a safe place so that you can restore the site in the future if needed.

> [@Create, download, and restore a backup of your Discourse database](https://meta.discourse.org/t/create-download-and-restore-a-backup-of-your-discourse-database/122710#p-603469-upload-a-backup-3):
>
> bookmark This guide provides step-by-step instructions for creating, downloading, and restoring a backup of your Discourse database. person_raising_hand Required user level: Administrator Discourse allows site administrators to create and download a copy of the site’s database. The backup can then be uploaded and restored to any Discourse forum. Discourse backups include the full site database, which contains everything on the site: topics, posts, users, groups, settings, themes, etc. D…

---

<div class="post-metadata">

### Author: ![ondrej](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ondrej/32/198804_2.png) [@ondrej](https://meta.discourse.org/u/ondrej)
#### Post date: [25 oktober 2024 om 16:41 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/4 "2024-10-25T16:41:26Z")

</div>

> [@Moin](#):
>
> you also get one when you cancel the hosting.

You do. I asked at the beginning of the year and got this answer from the Team.

“As part of our cancellation process, we generate a complete backup of your site, including all uploads, which will be made available for you to download”

---

<div class="post-metadata">

### Author: ![Sidi\_Codet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sidi_codet/32/455699_2.png) [@Sidi\_Codet](https://meta.discourse.org/u/Sidi_Codet)
#### Post date: [25 oktober 2024 om 16:50 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/5 "2024-10-25T16:50:38Z")

</div>

and were you able to migrate it successfully @ondrej ??

---

<div class="post-metadata">

### Author: ![ondrej](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ondrej/32/198804_2.png) [@ondrej](https://meta.discourse.org/u/ondrej)
#### Post date: [25 oktober 2024 om 16:52 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/6 "2024-10-25T16:52:10Z")

</div>

Hi, yes. I created / downloaded the backup then restored in on my new site 🎉

---

<div class="post-metadata">

### Author: ![Sidi\_Codet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sidi_codet/32/455699_2.png) [@Sidi\_Codet](https://meta.discourse.org/u/Sidi_Codet)
#### Post date: [25 oktober 2024 om 16:56 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/7 "2024-10-25T16:56:54Z")

</div>

I did that and created a backup, which I downloaded. However, when I tried to restore it on the self-hosted platform, I encountered errors. Did you perhaps make any additional configuration changes before restoring, aside from changing the `hostname`?

---

<div class="post-metadata">

### Author: ![ondrej](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ondrej/32/198804_2.png) [@ondrej](https://meta.discourse.org/u/ondrej)
#### Post date: [25 oktober 2024 om 17:00 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/8 "2024-10-25T17:00:20Z")

</div>

I didn’t make any changes I just uploaded it with no issues. What kind of errors are you getting?

---

<div class="post-metadata">

### Author: ![Sidi\_Codet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sidi_codet/32/455699_2.png) [@Sidi\_Codet](https://meta.discourse.org/u/Sidi_Codet)
#### Post date: [25 oktober 2024 om 17:38 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/9 "2024-10-25T17:38:19Z")

</div>

[log.txt (3).zip](https://meta.discourse.org/uploads/short-url/u6SwnND5xUKveWyFDvAoiU3yMAx.zip) (2.5 KB)  
thats the error i am getting

---

<div class="post-metadata">

### Author: ![philh](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/philh/32/532740_2.png) [@philh](https://meta.discourse.org/u/philh)
#### Post date: [25 oktober 2024 om 18:01 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/10 "2024-10-25T18:01:09Z")

</div>

Link to your self hosted site??

Did you see the error from your log?

```plaintext
[2024-10-25 17:35:57] ERROR: function discourse_functions.raise_discourse_voting_category_settings_readonly() does not exist
[2024-10-25 17:35:58] EXCEPTION: psql failed: ERROR: function discourse_functions.raise_discourse_voting_category_settings_readonly() does not exist

```

---

<div class="post-metadata">

### Author: ![Sidi\_Codet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sidi_codet/32/455699_2.png) [@Sidi\_Codet](https://meta.discourse.org/u/Sidi_Codet)
#### Post date: [25 oktober 2024 om 18:38 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/11 "2024-10-25T18:38:15Z")

</div>

Here’s is the hosted [Community](https://community.naliss.com.ng)

---

<div class="post-metadata">

### Author: ![nathank](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nathank/32/290039_2.png) [@nathank](https://meta.discourse.org/u/nathank)
#### Post date: [25 oktober 2024 om 18:42 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/12 "2024-10-25T18:42:40Z")

</div>

I suspect that you might have tried to restore it to a later version of Discourse - and the database has moved on.

If you start with a clean install of the same vintage as your backup, restore your backup, and then upgrade you should be sweet.

---

<div class="post-metadata">

### Author: ![Sidi\_Codet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sidi_codet/32/455699_2.png) [@Sidi\_Codet](https://meta.discourse.org/u/Sidi_Codet)
#### Post date: [25 oktober 2024 om 18:43 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/13 "2024-10-25T18:43:59Z")

</div>

Please a guide on how to do this , please!

---

<div class="post-metadata">

### Author: ![supermathie](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/supermathie/32/507518_2.png) [@supermathie](https://meta.discourse.org/u/supermathie)
#### Post date: [25 oktober 2024 om 19:19 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/14 "2024-10-25T19:19:37Z")

</div>

> [@nathank](#):
>
> I suspect that you might have tried to restore it to a later version of Discourse - and the database has moved on.

This is supported and should work fine.

> [@philh](#):
>
> ```plaintext
> discourse_functions.raise_discourse_voting_category_settings_readonly() does not exist
> 
> ```

Myself I’m not sure how the backup interacts with the defined functions… possibly it assumes they already exist in the `discourse_functions` schema.

Do you have this plugin (`discourse-post-voting`) installed? Try installing it prior to doing the restore.

---

<div class="post-metadata">

### Author: ![nathank](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nathank/32/290039_2.png) [@nathank](https://meta.discourse.org/u/nathank)
#### Post date: [25 oktober 2024 om 19:24 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/15 "2024-10-25T19:24:38Z")

</div>

> [@supermathie](#):
>
> This is supported and should work fine.

That is good to hear! I probably got a bit confused about the other direction i.e. it isn’t a good idea to use an older version of Discourse with a current backup.

> [@supermathie](#):
>
> Do you have this plugin (`discourse-post-voting`) installed? Try installing it prior to doing the restore.

Yes, @Sidi_Codet do this! (and not what I suggested)

---

<div class="post-metadata">

### Author: ![Sidi\_Codet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sidi_codet/32/455699_2.png) [@Sidi\_Codet](https://meta.discourse.org/u/Sidi_Codet)
#### Post date: [25 oktober 2024 om 20:13 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/16 "2024-10-25T20:13:29Z")

</div>

Its still not working prior to installing the plugin 👇

`> discourse-post-voting`

---

<div class="post-metadata">

### Author: ![philh](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/philh/32/532740_2.png) [@philh](https://meta.discourse.org/u/philh)
#### Post date: [25 oktober 2024 om 20:35 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/17 "2024-10-25T20:35:49Z")

</div>

> [@Sidi\_Codet](#):
>
> Please a guide on how to do this , please!

@Moin referenced the guide above: [Create, download, and restore a backup of your Discourse database](https://meta.discourse.org/t/create-download-and-restore-a-backup-of-your-discourse-database/122710#p-603469-upload-a-backup-3)

In my experience version need to be similar and  
the new installation must have the same plugins installed otherwise the restore usually errors out.

Following the guide works… Keep trying @Sidi_Codet If you are going to successfully self host Discourse you are going to need to be able to do things like this, unless you have someone manage your server and Discourse for you. Keep at it, things get easy as you go. 🙂

---

<div class="post-metadata">

### Author: ![Sidi\_Codet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sidi_codet/32/455699_2.png) [@Sidi\_Codet](https://meta.discourse.org/u/Sidi_Codet)
#### Post date: [25 oktober 2024 om 20:50 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/18 "2024-10-25T20:50:24Z")

</div>

Thank you @philh. I’ve been managing by reading references, searching on Google, and occasionally banging my head against the wall (just kidding, or am I?). But seriously, I couldn’t find any solutions. I’ve been reading more than I ever did in school, trying to find the earliest and most effective solutions. My eyes are blurry, my brain is mush, but I won’t give up!

If I find a working solution, I’ll make sure to share my response so that others can benefit from it. I think there’s a possibility that some developers may be facing the same issue, and it would be helpful to share my findings with the community.

---

<div class="post-metadata">

### Author: ![philh](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/philh/32/532740_2.png) [@philh](https://meta.discourse.org/u/philh)
#### Post date: [25 oktober 2024 om 21:07 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/19 "2024-10-25T21:07:15Z")

</div>

Always good to share! 🙂  
The backup and restore process is normally very straight forward. I am curious about where you are hosting your self hosted instance and how the install went for you.

---

<div class="post-metadata">

### Author: ![Sidi\_Codet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sidi_codet/32/455699_2.png) [@Sidi\_Codet](https://meta.discourse.org/u/Sidi_Codet)
#### Post date: [25 oktober 2024 om 21:25 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/20 "2024-10-25T21:25:13Z")

</div>

I am using lightsail on AWS. The installation was pretty easy, the only issue I have is the migration.

---

<div class="post-metadata">

### Author: ![Falco](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/falco/32/179432_2.png) [@Falco](https://meta.discourse.org/u/Falco)
#### Post date: [25 oktober 2024 om 21:54 UTC](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728/21 "2024-10-25T21:54:57Z")

</div>

This sounds like something @gerhard knows about.

[Volgende pagina](https://meta.discourse.org/t/how-can-i-migrate-from-discourse-hosted-to-self-hosting/332728.md?page=2)
