There could be several reasons why all pages on WordPress show a 404 error when Nginx PHP-FPM is enabled. Some possible causes include:
Incorrect Nginx configuration: The Nginx configuration file may not be set up correctly to work with PHP-FPM. Ensure that the correct PHP-FPM socket or port is specified in the Nginx configuration file.
Wrong path to root folder: If the root folder for the WordPress site is not set correctly, then Nginx will not be able to locate the correct files and will return a 404 error. Check that the root folder path is correct in the Nginx configuration file.
Incorrect file permissions: Ensure that the files and directories for the WordPress site have the correct permissions set. If the files cannot be accessed by the web server, then a 404 error will be returned.
PHP-FPM not running: Verify that PHP-FPM is running correctly on the server. If PHP-FPM is not running, then Nginx will not be able to execute the PHP scripts for the WordPress site.
Plugin or theme conflicts: It is possible that a plugin or theme on the WordPress site is causing conflicts with Nginx PHP-FPM. Try disabling plugins and themes one by one to see if any of them are causing the issue.
Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss
Asked: 2022-05-13 11:00:00 +0000
Seen: 11 times
Last updated: Feb 19 '23
How can a HTTP header be inserted in WordPress?
How can data be stored in a data attribute and utilized through Ajax?
How can an array be passed using typo3 flexform xml and itemsProcConfig?
Does JSON encode fail to retrieve data from the database?
Can the GS1 128 barcode decoder in PHP or Jquery be utilized?
How can Xdebug be used in conjunction with VSCode for Laravel on Sail and WSL2?
In PHP, what is the method for finding encrypted data using the "like" operator?
What is the method to pass a variable from PHP back to JavaScript?
Why do PHP variable variables display unexpected behavior when used with arrays?