Home >Backend Development >PHP Problem >What should I do if the Alibaba Cloud PHP web page cannot be accessed?

What should I do if the Alibaba Cloud PHP web page cannot be accessed?

藏色散人
藏色散人Original
2022-11-13 09:28:051705browse

Solution to the inaccessible Alibaba Cloud PHP webpage: 1. Check the Alibaba Cloud manual installation process of LNMP; 2. Enable php-fpm and nginx; 3. Enter the nginx installation directory sbin and enter the command "./ nginx -t"; 4. Verify and modify the nginx configuration file.

What should I do if the Alibaba Cloud PHP web page cannot be accessed?

The operating environment of this tutorial: Windows 7 system, PHP version 8.1, Dell G3 computer.

What should I do if the Alibaba Cloud PHP web page cannot be accessed?

After restarting Alibaba Cloud ECS, the PHP website on LNMP cannot be accessed?

At first I thought the nginx configuration was wrong, so I spent 3 hours working on it. . . If it doesn't work, I checked Alibaba Cloud's manual installation process of LNMP and found that php-fpm and nginx may not be enabled.

Open php-fpm:/usr/local/php/sbin/php-fpm

Open nginx: systemctl start nginx

As a result, nginx cannot be opened and an error message is reported:

1. First enter the nginx installation directory sbin and enter the command ./nginx -t

Verify whether the nginx configuration file is correct

What should I do if the Alibaba Cloud PHP web page cannot be accessed?It turns out to be nginx The configuration was wrong. After modifying the configuration, it was successful.

Recommended learning: "

PHP Video Tutorial

"

The above is the detailed content of What should I do if the Alibaba Cloud PHP web page cannot be accessed?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn