cancel
Showing results for 
Search instead for 
Did you mean: 
TPeters
Flight Engineer
Flight Engineer
  • 11K Views

curl finds no route to host?

Jump to solution

I am doing the self-paced course RH294 . With two exercises (Ch.3 final Lab and Ch.4 lab exercise 2) I ran into this problem:

after installing and starting a web service, from the classroom web termicaI I cannot reach servera.lab.example.com with curl: "No route to host". This despite the fact that I can ping it, open a shell to it, and install the package on it with Ansible.

Anyone else have the same problem?

What might be the cause?

 

Labels (1)
27 Replies
Chetan_Tiwary_
Community Manager
Community Manager
  • 2,236 Views

@Rogier Working fine for me : may be a network glitch or some other issue - please run lab finish command and then redo this lab from beginning - it will work. Else please raise a support ticket - our team will check and help you. 

Chetan_Tiwary__0-1697748890124.png

 

0 Kudos
Travis
Moderator
Moderator
  • 9,070 Views

@Chetan_Tiwary_ -

I've seen errors when teaching the class and in most cases, students have not had the firewall running or the service wasn't running. Seeing the entire playbook is what is needed. 

The "curl" command connects on port 80 so if that is blocked by the firewall, you get no routte to host. So, it isn't a network glitch as you can do regular pings. Ansible is able to customize things as servera and the rest of the servers have port 22 open on the firewall for SSH. However, the Linux servers do not have port 80/tcp open.

I would venture a guess that if you would do a "firewall-cmd --add-service=http" or a "firewall-cmd --add-port=80/tcp" that the curl command would work. 

It looks like the lab environment wants you to use HTTPS, so it is important when testing with curl to use the port. It is also important to check the playbook to ensure firewalld opened the correct ports.

 

 

Travis Michette, RHCA XIII
https://rhtapps.redhat.com/verify?certId=111-134-086
SENIOR TECHNICAL INSTRUCTOR / CERTIFIED INSTRUCTOR AND EXAMINER
Red Hat Certification + Training
Chetan_Tiwary_
Community Manager
Community Manager
  • 2,215 Views

@Travis Thanks for the reply and suggestion! You are right that we need to check the whole playbook to come to a conclusion. I guess if one has followed the lab steps correctly and have included all the tasks as instructed in the playbook correctly - post execution , the lab would grade them a overall PASS. So, my point was more like that  the lab has no bugs as such.

 

0 Kudos
TPeters
Flight Engineer
Flight Engineer
  • 2,199 Views

As I pointed out in my reply of 27 July to my own original question, in my case the problem was that `lab finish` does not completely clean the hosts. I have kept my lab environment throughout the course, and that left some crud that prevented properly finishing the lab. Chetan and others may have had similar problems.

 

0 Kudos
Travis
Moderator
Moderator
  • 134 Views

@TPeters -

You're correct that the lab finish doesn't do the cleanup. The lab "start" is supposed to perform the cleanup if you want to redo an exercise, but sometimes there are things that are left out or sometimes "forgotten". So while running finish and then re-running lab start will sometimes solve the issue, if it was a cleanup issue, the only true way to be reset is by reprovisioning the lab environment. 

However, this also provides a learning opportunity to actually troubleshoot and figure out what went wrong because on an exam or in the real world, you won't have a step-by-step guide with how to write a playbook.

Travis Michette, RHCA XIII
https://rhtapps.redhat.com/verify?certId=111-134-086
SENIOR TECHNICAL INSTRUCTOR / CERTIFIED INSTRUCTOR AND EXAMINER
Red Hat Certification + Training
  • 2,134 Views
FWIW, I ran into a similar issue as you after having to fix several mistakes in my initial playbook for the end of chapter (4) lab. I ended up resetting serverb completely and testing the playbook again and it worked.
  • 2,133 Views
correction: end of chapter (3) lab
georgef
Mission Specialist
Mission Specialist
  • 2,036 Views
Hi,
I'm in Chapter 3, final lab data review, and I have the same problem.
I can authenticate just fine through firefox and get the correct index.html, however the grading fails.
Not sure how I can post a screenshot here.

Chetan_Tiwary_
Community Manager
Community Manager
  • 2,033 Views

Hello @georgef !

Did you try the : "firewall-cmd --add-service=http" or a "firewall-cmd --add-port=80/tcp" to see if this helps you in the grading ?

0 Kudos
georgef
Mission Specialist
Mission Specialist
  • 2,031 Views

I'm not sure why I should do firewall-cmd --add-service=http on serverb, as the playbook specifically concerns itself with https only. If there is a misconfiguration in serverb, Redhat should fix it, not me. 

In any case, I tried it, but it didn't make a difference. I can connect through Firefox just fine on https://serverb.lab.example.com, input the credentials and see the index.html

 

 

Join the discussion
You must log in to join this conversation.