Apache hints that the requested operation has failed could not start the solution

  • 2020-05-09 19:50:21
  • OfStack

The reason is that port 1:800 is occupied, such as IIS, and the other reason is thunderbolt. My apache server was disabled by thunderbolt!

Reason 2: software conflict. Installing some software will prevent apache from starting if you have an Dr.com network connection open - > TcpIp properties - > Advanced - > The WINS tag removes the lmhosts check from netbios and disables tcp/ip netbios. Then it should start again.

If the apache configuration file httpd.conf is wrong, launch it in windows, and it will prompt the requested operation has failed. You can actually launch apache in command line mode with a parameter, apache will tell you which sentence is wrong, and then you can fix it accordingly.

Check for errors: go to cmd and then go to the Apache installation directory (specifically your own installation directory)\bin > httpd.exe -w -n "Apache2" -k start

(change Apache2 in quotation marks to your Apache service name, mine is version 2.2.4, the service name is Apache2, you can look for it in the computer service)

Prompt if line 133 has a problem (hint :Syntax error on line line 133 of...) Open the Apache installation directory \conf\ httpd. conf finds ServerAdmin at line 133 (if there is no tool to determine the number of lines, press ctrl+F and search with the "ServerAdmin" keyword, there will be two of them in 1, the one below is).

If it is a port occupation (note: OS 10048) it is normally only allowed once per socket address (protocol/network address/port). , exit Apache first, search Listen 80 in httpd.conf, change 80 to 8080 or another port number, and rerun Apache 1, this should be able to start.

The above is the method used when 1 failed to start, take out for the reference of friends with similar problems. Hope it can be helpful.

If the root of the site is not set correctly, it will not start. Apache has a lot of problems. There are two. Just look for Apache/htdocs in httpd.conf, as in K:/IDDCWEB/wwwroot

1 the "\" of the general file address should be changed to "/" in Apache.

If you are using version Apache2.24, select php5apache2_2.dll in php to load.

In addition, I will modify some Settings of httpd.conf for your reference and comparison.

1. Change the root directory of the website, there are two places. Find DocumentRoot and Directory. Modify D:/wwwroot      ; In Apache, the word "/" should be changed to "/".

2. Home page setting, DirectoryIndex, add relevant home page items, such as index.php ihdex.htm

3. Look for LoadModule ssl, add in the following two lines, line 1 "LoadModule php5_module D: / Server php/php5apache2_2 dll" refers to loading php module way, line 2 "PHPIniDir" D: / php "" is indicated php php configuration file. ini position, is, of course, "D:/php" should be changed to the unzipped php directory you selected earlier.

4. Find AddType application/ x-gzip.gz.tgz and add "AddType application/ x-httpd-php" and "AddType application/ x-httpd.html" at the bottom. You can also add more. For example, if you add 1 line "AddType application/ x-httpd-php.htm", then the.htm file can also execute the php program. You can even add 1 line "AddType application/ x-httpd-php.txt" to make the php program run in plain text file format.

5. Search for ServerName    . Change the port after the name of the website to the previous port.


Related articles: