# Restore to New Host

**URL:** <https://meta.discourse.org/t/restore-to-new-host/219515>\
**Category:** Product Support\
**Created:** [February 27, 2022, 7:46pm UTC](https://meta.discourse.org/t/restore-to-new-host/219515 "2022-02-27T19:46:43Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![Samir\_Faci](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/samir_faci/32/119582_2.png) [@Samir\_Faci](https://meta.discourse.org/u/Samir_Faci)\
**Post date:** [February 27, 2022, 7:46pm UTC](https://meta.discourse.org/t/restore-to-new-host/219515/1 "2022-02-27T19:46:43Z")

</div>

I setup a new host so I can have a ‘staging’ environment. I re-created the same discourse installation with what should be the same version. I’m running version: 2.8.2.

First comment, as of version 2.8.2 my back up size has dropped from 282MB to around 90MB. Not sure why but I’m going to just with some intelligence added in that I’m taking advantage of.

I downloaded the latest archive from my forum, and uploaded to local storage on the new staging environment.

The restore fails due to:

```sh
[2022-02-27 19:41:18] ALTER TABLE
[2022-02-27 19:41:18] ALTER TABLE
[2022-02-27 19:41:18] Migrating the database...
[2022-02-27 19:43:00]
[2022-02-27 19:43:00] Reconnecting to the database...
[2022-02-27 19:43:00] Reloading site settings...
[2022-02-27 19:43:00] Disabling outgoing emails for non-staff users...
[2022-02-27 19:43:02] Disabling readonly mode...
[2022-02-27 19:43:02] Clearing category cache...
[2022-02-27 19:43:02] Reloading translations...
[2022-02-27 19:43:02] Remapping uploads...
[2022-02-27 19:43:02] Remapping 'https://forum.geekbeacon.org' to 'https://forum-staging.geekbeacon.org'
[2022-02-27 19:43:08] Restoring uploads, this may take a while...
[2022-02-27 19:43:36] EXCEPTION: 8 posts are not remapped to new S3 upload URL. S3 migration failed for db 'default'.
[2022-02-27 19:43:36] /var/www/discourse/lib/file_store/to_s3_migration.rb:132:in `raise_or_log'
/var/www/discourse/lib/file_store/to_s3_migration.rb:87:in `migration_successful?'
/var/www/discourse/lib/file_store/to_s3_migration.rb:373:in `migrate_to_s3'
/var/www/discourse/lib/file_store/to_s3_migration.rb:66:in `migrate'
/var/www/discourse/lib/file_store/s3_store.rb:317:in `copy_from'
/var/www/discourse/lib/backup_restore/uploads_restorer.rb:62:in `restore_uploads'
/var/www/discourse/lib/backup_restore/uploads_restorer.rb:44:in `restore'
/var/www/discourse/lib/backup_restore/restorer.rb:61:in `run'
/var/www/discourse/script/spawn_backup_restore.rb:23:in `restore'
/var/www/discourse/script/spawn_backup_restore.rb:36:in `block in <main>'
/var/www/discourse/script/spawn_backup_restore.rb:4:in `fork'
/var/www/discourse/script/spawn_backup_restore.rb:4:in `<main>'
[2022-02-27 19:43:36] Trying to rollback...
[2022-02-27 19:43:36] Rolling back...
[2022-02-27 19:43:36] Cleaning stuff up...
[2022-02-27 19:43:36] Dropping functions from the discourse_functions schema...
[2022-02-27 19:43:36] Removing tmp '/var/www/discourse/tmp/restores/default/2022-02-27-194051' directory...
[2022-02-27 19:43:36] Unpausing sidekiq...
[2022-02-27 19:43:36] Marking restore as finished...
[2022-02-27 19:43:36] Notifying 'csgeek' of the end of the restore...

```

---

_[View the full topic](https://meta.discourse.org/t/restore-to-new-host/219515)._
