Table of Contents
- Welcome to JawsDB
- Plan Changes
- SSO Dashboard
- Database Backups
- Manual Backups and Migrations with
JawsDB is a Database-as-a-Service (DBaaS) provider supplying a fully functional, fully managed, relational database for use with your application. Rather than going through the hassle of hosting, configuring, patching, and managing a database, JawsDB provides one-click delivery and management of a relational database in the cloud.
JawsDB is easy to use and requires no custom coding or libraries to interact with it. Simply select a plan that meets your needs, and we will provide you with the hostname and credentials necessary to dive in and start swimming with the big fish.
MySQL is the world’s most widely used open-source relational database and is trusted by companies such as Google, Facebook, Twitter, and Youtube. Its power, stability, security, and wealth of online documentation has cemented it as a premiere option for start-ups and established businesses alike.
JawsDB provides situational support for automatic upgrades and downgrades between plans. See the below sections for when an up/downgrade may be possible. In all cases where automatic up/downgrading is allowed, your data should be preserved. However, it is always a good idea to backup your database before a plan change. See the section in this documentation entitled Manual Backups with
mysqldump for information on how to do this.
Application owners should carefully manage the migration timing to ensure proper application function during the migration process.
Depending on whether a desired plan is a single-tenant or multi-tenant (Shared) plan and whether the storage of the desired plan is greater or less than the current plan, a user may be able to change their plan automatically by following the relevant process flow of the platform where JawsDB was purchased.
Plan changes can be made from your Manifold dashboard. Click edit on the resource you’d like to change, select the new plan that you’d like to change to, and then confirm. If successful you will see a confirmation message.
In order to tell whether an automatic plan-change is supported, please reference the table below keeping in mind the current plan and the desired plan.
|PLAN||To Multi-tenant||To Single-tenant (storage < source storage)||To Single-tenant (storage >= source storage)|
JawsDB can be removed from your account by going to the Manifold dashboard and clicking to edit a resource, then clicking “deprovision resource”.
JawsDB provides a Dashboard where users can view important information about their Database. This information includes:
- Connection String
- Server Status
- Allocated Storage
- Backup Window
- Maintenance Window
- Latest Restorable Time
- SSL Information
Users can reset their Database password from the Dashboard and they may also create, view, and delete Databites.
Once your database is listed with a status of ‘AVAILABLE’, the dashboard will allow you to create Databites. As a simple, yet powerful reporting tool, Databites provide users the ability to run basic (read-only) SQL queries against their provisioned database and save those queries for later execution. Once a Databite is created, it is saved to your dashboard where it can be re-run, edited, or deleted with ease.
On your dashboard, under the section labeled ‘Databites’, select “Create New Databite”. This will direct your browser to the Databite page where custom queries can be entered into the editor which features SQL syntax highlighting. Clicking “Update” underneath the editor will execute the query against your database and return the result set in the same browser window in a tabular format.
Using the “Back” link will return you to the dashboard where your Databite will now be listed in the Databite section. Clicking on an existing Databite will redirect the browser to the Databite page and re-execute the query.
For security reasons, Databites are read-only, i.e. they do not support statements that create database objects or that alter data in your database. Think of Databites as a way to create windows into the most important information stored in your database.
JawsDB is based on Amazon’s AWS cloud infrastructure. Because of this, our internal backups are in an Amazon proprietary format (similar to VMWare snapshots). This unfortunately, means that the backups that we take automatically are not downloadable and must be restored by submitting a ticket through support channels or by sending an email to us directly at email@example.com.
We can restore users’ databases by request as long as the request is in the 48 hour timeframe (or 24 hour if the plan is non-alpha). JawsDB backups are taken once per day during your server’s backup window.
A benefit of the snapshots is that we can potentially perform point-in-time restores. We can restore a database to the time of backup (quickest option), but the point-in-time feature means we can attempt to restore the database to a specific point-in-time between the backup window and when the backup request was submitted. The time this takes to complete will grow as the size of the database and the average number of transactions per minute grows.
Customers are also free to take and keep their own backups using
mysqldump or some other service or utility.
Below we provide a quick primer on how to use
mysqldump to create and restore backups.
mysqldump is a powerful client utility packaged with the MySQL clients available on the MySQL downloads page. With this utility, users can backup their database into flat files as well as restore those backups to any MySQL or compatible server of their choice.
In order to complete either operation, the connection credentials and information of the relevant server(s) must be know in advance.
Connection strings provided by JawsDB contain all of the relevant info in the following format:
database will be referenced in the following sections.
mysqldumptutorials below are simplistic and general. The full range of options and configurations that
mysqldumpsupports can be seen here and in the tool’s own
The following command will backup the specified database into a local file called
mysqldump -h hostname -u username -ppassword database > backup.sql
Note that there is no space between the
Backup files created with
mysqldump can be loaded onto a target server the way any SQL file would be loaded. Below is a way to do this with the
mysql command-line utlity.
mysql -h hostname -u username -ppassword database < backup.sql
Note again how there is no space between the
I am unable to insert records into my database. What gives?
If you are on one of JawsDB’s shared plans, you may have breached the database size allotted via your plan. When a database grows larger than the plan allows, INSERT privileges are revoked on the database user until the database is brought back into compliance. SELECT, UPDATE, and DELETE privileges are still available during this time. Once the database size is reduced back under the maximum allowed size, the INSERT privilege will be granted back.
The following can be run against the database or placed into a databite in order to see current database size in MB and whether the account currently has INSERT privileges.
select s.schema_name ,sp.grantee user ,cast(round(sum(coalesce(t.data_length + t.index_length, 0)) / 1024 / 1024, 3) as char) db_size_mb ,sp.has_insert from information_schema.schemata s inner join information_schema.tables t on s.schema_name = t.table_schema inner join ( select spi.grantee ,spi.table_schema ,max( case when spi.privilege_type = 'INSERT' then 1 else 0 end ) has_insert from information_schema.schema_privileges spi group by spi.grantee ,spi.table_schema ) sp on s.schema_name = sp.table_schema group by s.schema_name;
I am getting an error saying I have exceeded the ‘max_questions’ resource. What is that?
The ‘max_questions’ value is a limit that is placed on shared plan accounts to help preserve computing power for other shared plan users on the same server. It is essentially a limit on the number of queries that can be executed from that account in an hour. After 1 hour of reaching the limit, the limit will be reset and queries can again be executed.
HINT: Cached queries do not count against the query limit of ‘max_questions’. Taking advantage of the cache is a good way around this limit.
Single-tenant plans (such as Whitetip and above) carry no ‘max_questions’ limits.
How do I access my database backups?
JawsDB backups are in an Amazon-proprietary snapshot format and must be restored by the JawsDB team. Please see the section entitled Database Backups for more information.
Why do I get an error when attempting to change my plan?
In some specific situations, changing plan requires a manual migration. Please check the section entitled Plan Changes to find out whether this applies to your particular situation.
Does JawsDB support Encryption at Rest? Encryption at Rest (EAR) is a new feature applying transparent AES-256 encryption to the underlying data storage of a JawsDB database and is available on a subset of our plans. Check the desired plan’s description to see if EAR is supported.
Account support and runtime issues should be sent to JawsDB’s support email address.
For news, non-critical questions, and feedback, check out the @jawsdb Twitter account