• Register
0 votes
732 views

Problem :

I am new to AWS and trying to configure ELB with EC2 in AWS but I ran into "Instance has failed at least the Unhealthy Threshold number of health checks consecutively" error to make the instance out of service. I have also checked following:

1) Currently I am using 8080 port for security check and the path is "/index.html". I have tested the following link http://ec2DNSname:8080/index.html in my browser and it returns following:

Response header:
HTTP/1.1 200 OK
X-Powered-By: Express
Accept-Ranges: bytes
ETag: "150-1420697739000"
Date: Thu, 08 Jan 2015 06:16:21 GMT
Cache-Control: public, max-age=0
Last-Modified: Thu, 08 Jan 2015 06:15:39 GMT
Content-Type: text/html; charset=UTF-8
Content-Length: 150
Vary: Accept-Encoding
Connection: keep-alive

2) In my EC2 configuration I am allowing the inbound TCP traffic on 8080 from any machines

May I know the possible cause of failing the health check?

6 5 3
7,540 points

Please log in or register to answer this question.

1 Answer

0 votes

Solution :

If the page is returning a 200 response, it should pass the health check. The Health Check configuration should have the number of times a Health Check needs to return a good result and how often to check it. So for Healthy count of 5 with a check every 30 seconds would only take 2.5 minutes to return as Healthy.

If your HTTP health check is failing then you can try the a TCP health check on port 8080.

Also please check that your VPC configuration is allowing a connection from the Load Balancer to the EC2 instance. This will happen automatically if they belong to the same Subnet, but Network ACLs can impact the connection between different Subnets.

9 7 4
38,600 points

Related questions

1 vote
1 answer 432 views
432 views
Problem: I am not having much knowledge about Amazon EC2. Recently when I was trying to stop my Amazon EC2 instance then I saw the following warning message: "Warning: Please note that any data on the ephemeral storage of your instance will be lost when it is ... the ephemeral storage of my Amazon EC2 instance? I need expert’s advice in this aspect to avoid any important data loss to me.
asked May 23, 2020 Martin K 6.6k points
0 votes
1 answer 16 views
16 views
Problem: I am trying to create a Security Group using the AWS SDK but it is failing to authenticate it. For a very specific Access Key and Secret Key I have already provided the Administrative rights and then also it fails to validate. I also tried ... .java:1146) at com.sunil.demo.ec2.SetupEC2.createSecurityGroup(SetupEC2.java:84) at com.sunil.demo.ec2.SetupEC2.main(SetupEC2.java:25)
asked Aug 24, 2020 Raphael Pacheco 4.9k points
0 votes
1 answer 107 views
107 views
Problem : I am very new to the Linux but want to set up my MySQL databases on the Amazon ec2 instance. I have followed some directions I found about resetting a user login pass by using a --skip-grant-tables option of the MySQL. Now I want to add my user ... HY000): The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement How can I turn above option off?
asked Jan 30, 2020 jwilliam 3.9k points
1 vote
2 answers 141 views
141 views
Problem : I am very new to programming world. According to my senior a for loop will always get executed at least once even if a required condition is not met. Please find below example for your reference: for (int i=6; i <=5; i++) {     //inappropriate for this ... } According to my senior above listed loop will be executed at least once but it does not or let me know if I am I missing something?
asked Apr 6, 2020 morrisBson 3.2k points
0 votes
1 answer 268 views
268 views
Problem : I am currently facing an issue with MySQL! I am the cPanel user, and I am looking for the solution on my issue. It seems this is more specific than other people with the same error codes issues. Please find below my code for the reference: DELIMITER $$ ... from the code: MySQL said: Documentation #1227 - Access denied; you need (at least one of) the SUPER privilege(s) for this operation
asked Nov 21, 2019 peterlaw 6.9k points
0 votes
1 answer 4 views
4 views
Problem: Hello Developers! I am new to the world of programming and I started learning Java at an academy. My teacher gave us an assingment in which we have to find the index of last occurrence of a character in a string. The program should return the ... those solutions. If someone has better solution then kindly explain or else please explain what substrings are and how I can use it. Thanks
asked Nov 29, 2020 Code Learner 5.5k points
0 votes
1 answer 7 views
7 views
Problem: Hello! I recently attempted a quiz on programming, which was required for an internship. I do not have much experience in the field of computer programming. There was a question in the quiz that puzzled me: &ldquo;A java program must have at least one ... c. Could anyone from here please tell me whether my answer was correct or not. Moreover, please explain the correct answer. Thanks!
asked 4 days ago Code Learner 5.5k points
0 votes
1 answer 16 views
16 views
Problem: Hi there! I have been learning to program for a long time now and I recently learned inheritance in Java. I wrote the following program for practice: class Institutions { public void print_institutions() { System.out.println("This is an institution"); } } class ... , I have no idea what is causing this error. Can anybody here please clarify the cause of the error and its solution? Thanks!
asked Dec 29, 2020 Code Learner 5.5k points
0 votes
1 answer 42 views
42 views
Problem: Hi, i upgraded the wordpress to Wordpress 5..2.2 but it popups a notification that my server is running an older version. Can anyone suggest me the best solution.
asked Nov 2, 2020 prog_learner 2.5k points