Error saying "Failed to start httpd.service: Unit httpd.service not found."

0 votes

I'm trying to execute the following command:

sudo service httpd start

end up with the following error:

Failed to start httpd.service: Unit httpd.service not found.
May 13, 2019 in Linux Administration by Avi
4,364 views

1 answer to this question.

0 votes

Execute the following steps or make sure you've executed the following steps correctly:

1) Update and install Apache and PHP:

sudo yum check-update
sudo yum -y install httpd php

2) Start the Apache service:

sudo service httpd start
sudo chkconfig httpd on
answered May 13, 2019 by Kiara
Thanks, this worked for me.

httpd package was missing from my VM instance.

Related Questions In Linux Administration

0 votes
1 answer

Failed to start httpd.service: Unit httpd.service is masked.

Hi@akhtar, A masked service is used to prevent ...READ MORE

answered Apr 23 in Linux Administration by MD
• 23,050 points
67 views
0 votes
1 answer

Job for httpd.service failed because the control process exited with error code.

Hi@akhtar, This problem is caused due to SELinux. It ...READ MORE

answered Apr 23 in Linux Administration by MD
• 23,050 points
103 views
0 votes
1 answer

Name or service not known error

Seems like there is no nameserver set. Run ...READ MORE

answered Apr 1, 2019 in Linux Administration by Rohit
1,852 views
+1 vote
0 answers

Could not start the machine edureka_host_vm because the following physical network interfaces were not found:

Could not start the machine edureka_host_vm because ...READ MORE

Jan 28 in Linux Administration by Harish
• 130 points
99 views
0 votes
1 answer
0 votes
1 answer

How do I set variable if a specific package version is installed in CFEngine?

Here is what you can do.Just use packagesmatching to ...READ MORE

answered Jul 12, 2018 in Other DevOps Questions by Atul
• 10,240 points
142 views
0 votes
1 answer

Install postgreSQL on Ubuntu

Installing PostgreSQL on Ubuntu is very simple, ...READ MORE

answered Mar 22, 2019 in Database by Nitesh
116 views
0 votes
1 answer

Access progrs prompt without switching accounts

Use the following to get the postgres prompt ...READ MORE

answered Mar 22, 2019 in Database by Mahi
77 views
+1 vote
1 answer

Not able to install npm on Ubuntu

Try installing npm using aptitude: sudo apt install aptitude sudo ...READ MORE

answered Nov 28, 2018 in Linux Administration by Omkar
• 69,060 points
3,278 views