amazon-rds

How to copy a database using RDS

帅比萌擦擦* 提交于 2020-01-02 00:49:08
问题 I have a database instance on RDS with 2 databases on it. Is there a good way using the RDS command line tools to copy the one database to the other? If not, what is the recommended way of doing it? Thanks in advance. 回答1: I'd use mysqldump to get the tables and then mysql to import them. Update 2014/07/08 : Depending on what you're planning to do here, another solution today is to setup replication and then to promote the slave to be the master. That is for example if you want to update your

Explain this memory consumption pattern in Amazon RDS/Mysql?

点点圈 提交于 2020-01-01 04:28:04
问题 Folks, Can someone explain this memory consumption pattern on Amazon RDS running Mysql? In this graph, I upgraded to a db.m2.2xlarge, with 34GB of available memory, at 03:30. You can see the switchover very clearly. As clients start connecting and hitting that instance, the Freeable memory drops steeply to 5GB, where it is now hovering. On my previous upgrade between DB instance sizes, I saw the same pattern, until the freeable memory dropped to just under 1GB and hovered there indefinitely.

How to restore database in Elastic Beanstalk?

瘦欲@ 提交于 2019-12-30 12:24:11
问题 I am running Ruby 1.9.3 and Rails 3.2.8 on Amazon Elastic Beanstalk. After several issues with my side of the data, I did a rake db:reload Now I am trying to grab the data that I had already created in the database pre-reload. I have followed the instructions in the Amazon documentation . However, on step 6: Type the name of the restored DB instance in the DB Instance Identifier text box. - The prompt forces to give a new name to the Instance - thus creating a new instance. That is all good,

Error: connect ETIMEDOUT rds lambda

巧了我就是萌 提交于 2019-12-30 08:05:41
问题 I am trying to connect to RDS using Lambda function, but I am getting an error: var mysql = require('mysql'); exports.handler = function(event, context) { //Connect to RDS var connection = mysql.createConnection({ host : 'hostname', user : 'username', password : 'password', database : 'database' }); connection.connect( function(err) { if (err) { throw err; } else { console.log('DB connection establish'); } }); }; The error I am getting is: START RequestId: 9711e650-e582-11e5-af5f-97ba391a42ae

Can I CREATE TRIGGER in an rds DB?

隐身守侯 提交于 2019-12-29 10:14:28
问题 I'm trying to create a trigger on a table in my Amazon RDS database, and I can't seem to make it happen. I tried to create a trigger on a table in the mysql client I use (Navicat), and got the error that I needed the SUPER privilege to do so. After some searching, I found that you could SET GLOBAL log_bin_trust_function_creators = 1 to get around this. I tried that using these instructions: http://getasysadmin.com/2011/06/amazon-rds-super-privileges/ (and then restarting the DB server for

Exporting a AWS Postgres RDS Table to AWS S3

余生长醉 提交于 2019-12-29 01:34:34
问题 I wanted to use AWS Data Pipeline to pipe data from a Postgres RDS to AWS S3. Does anybody know how this is done? More precisely, I wanted to export a Postgres Table to AWS S3 using data Pipeline. The reason I am using Data Pipeline is I want to automate this process and this export is going to run once every week. Any other suggestions will also work. 回答1: There is a sample on github. https://github.com/awslabs/data-pipeline-samples/tree/master/samples/RDStoS3 Here is the code: https:/

Create an RDS Opsworks Layer by a Cloudformation template

好久不见. 提交于 2019-12-25 08:27:19
问题 I'm making a CloudFormation template that creates an opsworks stack, layers and few applications. Within my layers, I have opsworks ones and RDS ones. In the AWS documentation, there is only how to create Opsworks::Layer but I don't know how to make an Amazon RDS service layer: { "Type": "AWS::OpsWorks::Layer", "Properties": { "Attributes" : { String:String }, "AutoAssignElasticIps" : Boolean, "AutoAssignPublicIps" : Boolean, "CustomInstanceProfileArn" : String, "CustomJson" : JSON object,

MySQL query slows down when another query is concurently sent

放肆的年华 提交于 2019-12-25 07:04:24
问题 I am using an InnoDB table that currently has 16m of records. When I run the following query by using MySQL Workbench, it returns in about 14 seconds: SELECT countryCode AS label, SUM(count) AS value FROM AnalyticsPieCharts GROUP BY label ORDER BY value DESC; When I run the same query from a different computer, while the first one is running, both return in about 23-24 seconds. I haven't created any indexes (except of the primary key) or put transaction rules. I am using Amazon RDS. Do you

Amazon RDS replica

自作多情 提交于 2019-12-25 06:59:39
问题 I'm currently migrating my servers on Amazon EC2 and RDS and I can't find out how to create a replica of my production DB instance to a development DB instance. Basically what I would like to do is have a replication occurring everyday or week to be able to work on almost actual data on my development environment. Of course the multi-AZ option wouldn't work in this context since this is not for fail-over and the replication should only go in one direction (prod -> dev) to prevent any

Query storage status on an RDS DB using AWS CLI

一笑奈何 提交于 2019-12-25 04:54:09
问题 I have a few RDS servers I'd like to monitor for insufficient disk space. For simplicity sake, I prefer using my current monitoring system rather than an AWS solution like cloudwatch. I've been reading the documentation and the nearest solution was describe-db-instances, which gives the allocated storage, but not the space left / amount of storage used: "SecondaryAvailabilityZone": "us-east-1a", "ReadReplicaDBInstanceIdentifiers": [], "AllocatedStorage": 100, ... How do I query a specific RDS