How to Restore an MS SQL Database
The Restore feature is the most common way to deploy an existing database to our servers. By creating a backup file (.bak) of your local database and restoring it here, you can transfer your schema and data in one step.
Important Considerations Before You Begin
- Data Overwrite Warning: Restoring from a backup will permanently overwrite all existing data in the target database. If you have current data you wish to keep, please create a backup of the hosted database before proceeding.
- File Structure Limitations: We only support backups of databases that consist of one Data file (*.mdf) and one Log file (*.ldf). Databases spread across multiple secondary data files or filegroups are not supported.
- Version Compatibility: The MS SQL version of your backup file must be equal to or lower than the version of the database you created in the control panel. You cannot restore a backup from a newer server (e.g., SQL 2019) onto an older server instance (e.g., SQL 2016).
- Size Limits: The combined size of the data and log files inside your backup must fit within the storage limits of your assigned hosting plan.
Step-by-Step Instructions
To begin, navigate to the MS SQL section in the control panel, click on your specific database, and select the Restore tab. You will have two options to proceed:
Option 1: Upload and Restore (Recommended for new files)
Use this method to upload a .bak file directly from your computer and restore it immediately.
- Click the Upload and restore link/button.
- A dialog box will appear. You can either:
- Click Browse and upload a backup file to select the file from your computer.
- Drag and drop your
.bak file into the designated area.
- Schema Setting: We recommend keeping the Change default schema to 'dbo' checkbox selected. This ensures that objects owned by your local user are correctly mapped to the
dbo user on the server, preventing permission issues.
- Click Restore. Wait for the upload and restoration process to complete.
Option 2: Restore from Backup Location
Use this method if you have already uploaded your backup file via FTP or the File Manager.
- Ensure your
.bak file is present in your Backup location.
- Click the Restore from backup location link/button.
- In the dialog box, use the dropdown menu or file list to select the specific backup file you wish to use.
- Schema Setting: Ensure the Change default schema to 'dbo' checkbox is selected to map user permissions correctly.
- Click Restore to begin the process.