cancel
Showing results for 
Search instead for 
Did you mean: 
Dthibi
Cadet
Cadet
  • 172 Views

Chapter 4 Lab : Missing /var/www/html directory

Jump to solution

When running the Chapter 4 Lab, it is missing a directory on the managed host:

host: serverb.lab.example.com
directory: /var/www

This causes the playbook to fail at the code from Instruction #4 because it can't start the "httpd" service.  If I manually create the directory "/var/www/html", the playbook is successful.

I have reset "serverb" from the "Lab Envronment" tab and run the "lab start control-review" command and the directory is still missing.

Has anyone else had this issue?  Did I miss a step?  Any suggestions?

Thanks

 

Labels (1)
0 Kudos
1 Solution

Accepted Solutions
Travis
Moderator
Moderator
  • 168 Views

@Dthibi -

Most likely there are issues from another lab that didn't properly get cleaned up. Generally the /var/www/html directory doesn't exist on a RHEL server. This directory gets created when installing the HTTPD package. So the task in the playbook you are running should install the HTTPD package and as part of that is by default creating the /var/www/html directory. It is possible that a cleanup at some point left the package installed, but deleted the directory, so that is one instance where Apache could be on the system, but can't start.

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

View solution in original post

0 Kudos
3 Replies
Travis
Moderator
Moderator
  • 169 Views

@Dthibi -

Most likely there are issues from another lab that didn't properly get cleaned up. Generally the /var/www/html directory doesn't exist on a RHEL server. This directory gets created when installing the HTTPD package. So the task in the playbook you are running should install the HTTPD package and as part of that is by default creating the /var/www/html directory. It is possible that a cleanup at some point left the package installed, but deleted the directory, so that is one instance where Apache could be on the system, but can't start.

Travis Michette, RHCA XIII
https://rhtapps.redhat.com/verify?certId=111-134-086
SENIOR TECHNICAL INSTRUCTOR / CERTIFIED INSTRUCTOR AND EXAMINER
Red Hat Certification + Training
0 Kudos
Dthibi
Cadet
Cadet
  • 165 Views

Thank you for the quick reply.

As I stated in my original post, I "reset" the server and was still missing the folder.  However, I didn't re-run my playbook which would have re-installed the "httpd" package and shown that it is working as expected now. 

0 Kudos
Travis
Moderator
Moderator
  • 164 Views

@Dthibi -

Correct. I knew when you re-ran the playbook things should "work". Because when you reset the server, it was like HTTPD was never installed, so you are correct in the directory wouldn't be there, but there wouldn't even be a service to start.

Travis Michette, RHCA XIII
https://rhtapps.redhat.com/verify?certId=111-134-086
SENIOR TECHNICAL INSTRUCTOR / CERTIFIED INSTRUCTOR AND EXAMINER
Red Hat Certification + Training
0 Kudos
Join the discussion
You must log in to join this conversation.