Access Denied when creating RDS during init of Elastic Beanstalk - amazon-elastic-beanstalk

Being new to the platform I've followed the setup tutorial:
http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/create_deploy_Python_django.html
When I tried to created the RDS DB it wouldn't let me with the message:
InvalidParameterValue. Access Denied to API Version: API20120423
Output in the commandline:
What could be the reason for this happening?

As a workaround you can answer 'n' to the question "Create an RDS DB Instance", in this way you should be able to complete the init step of your environment.
Then to create an actual RDS DB go to your AWS console, in the Elastic Beanstalk section you'll find your newly created env. Click on the env and in the "Configuration" page you'll find a "Data tier" section, where you'll be able to create a RDS DB, associating it to your env.

Related

AWS (Elastic Beanstalk, RDS). The RDS database becomes unavailable

I deployed webAPP (Java) using Elastic Beanstalk, RDS(MySQL). HEALTH Status OK!
Access to the database is lost after 1 or 2 days. In the IDEA, when I connect to the database, I get an error [42000][1049] Unknown database 'ebdb'.
I have to rebuild environment (Elastic Beanstalk). But in a time I get that problem again. What is the reason of the error? How I can see in AWS is there database or not? Thanks.
I have never seen this issue. I have a custom Java Spring BOOT app running on Elastic Beanstlak and queries data from a RDS MySQL instance. Its been running well over a year without issue.
The database runs fine without any connection issues you are describing. When you look at the RDS instance in the AWS Management Console, what is the status of the database. Is it available - as shown here?
The URL to the RDS Management console in us-west-2:
https://us-west-2.console.aws.amazon.com/rds/home

How to fix db query error: failed to connect to server - please inspect Grafana server log for details

i'm new in Grafana. Im wanted to configure the mysql in grafana as the datasource. But my database is not a local database which is cloud database in mysql. How can i configure that? because i'm trying to configure it say "db query error: failed to connect to server - please inspect Grafana server log for details"
Anyone know how to change that? or how to configure mysql database in grafana (not local database). Please Help. Thank you
error message
Docker host using IP address of your machine follow below steps:
Open the CMD
IPCONFIG /ALL
Look for the IPV4 address under WiFi or
vEtherner, in my case its 192.168.1.24 and 172.45.202.1 respectively
Then try accessing the app hosted in docker container with mapped port (e.g. 1433/5436)
It works on 192.168.1.24:1433 and 172.45.202.1:1433 in the same way to access all container apps hosted using docker

Laravel: No such file or directory for table in AWS RDS laravel

I currently deployed my laravel app to the AWS elastic beanstalk. I created RDS mysql database. I imported my sql dump from my local project and deployed it to the AWS EC2 server. But I'm getting this error.
SQLSTATE[HY000] [2002] No such file or directory (SQL: select * from settings where code = company-name limit 1).
Is there any way how to check if there are data in my DB ? Just to note I'm still learning moving around AWS. Thanks.
EDIT :
I'm also getting correct Environment & details like RDS_PORT RDS_HOST... , on error page where I can see the error displaying
You can follow this tutorial to connect to a MYSQL RDS Database on AWS.
So you can check if all your tables have been created successfully.
AWS Connect to Database Tutorial
Make sure that you open the port of the RDS database in the security group. Otherwise your local machine can't connect to the Database.

Elastic Beanstalk: Migrate DB Security Group to VPC Security Group

When trying to deploy my application, I recently got the following error:
ERROR: Service:AmazonCloudFormation, Message:Stack named
'awseb-e-123-stack' aborted operation. Current state: 'UPDATE_ROLLBACK_IN_PROGRESS'
Reason: The following resource(s) failed to update: [AWSEBRDSDatabase].
ERROR: Updating RDS database named: abcdefg12345 failed
Reason: DB Security Groups can no longer be associated
with this DB Instance. Use VPC Security Groups instead.
ERROR: Failed to deploy application.
How do you switch over a DB Security Group to a VPC Security Group? Steps for using the Elastic Beanstalk Console would be greatly appreciated.
For anyone arriving via Google, here's how you do it via CloudFormation:
The official docs contains an example, at the very bottom https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Overview.RDSSecurityGroups.html#Overview.RDSSecurityGroups.DeleteDBVPCGroups
SecurityGroup:
Type: "AWS::EC2::SecurityGroup"
Properties:
VpcId: <vpc_id>
GroupDescription: Explain your SG
SecurityGroupIngress:
- Description: Ingress description
CidrIp: 10.214.0.0/16
IpProtocol: tcp
FromPort: 3306
ToPort: 3306
RDSDb:
Type: 'AWS::RDS::DBInstance'
Properties:
VPCSecurityGroups:
- Fn::GetAtt:
- SecurityGroup
- GroupId
Had the same issue but was able to fix it by doing the following
Created a RDS db instance from the RDS console
Created a snapshot of the instance
From Elastic Beanstalk console under configuration/database, create the RDS db using the instance
Once the new RDS db instance was created by EBS, inn configuration/software add db environment properties
I hope it helps you resolve this issue.

Unable to connect from local machine to AWS RDS db instance

i am trying to connect AWS db instance through MySQL workbench, the current rdb instance engine is MYSQL 5.6.23 also i am under the free tier plan in AWS ap-southeast region (Singapore)
These are the follwing steps in MySQL workbench
The user name and password is already set by me when i click the Test connection i got error always like this in the below image
So i go to the RDS Security group of this instance amrita2016-rds (sg-970f10f2) in AWS and Add an inbound rule to that group for allowing connections from my machine see the image
after that i tried once again through MYSQL workbench getting same error also i am working under domain network . Please help me to resolve this issue