All wordpress urls giving 404 for on premise install

Current Version :
2.3

Build :
1

Current Commit :
fd0cb9fb614556460b01da86f10bf6162f0f6de6

Latest Version :
2.3

Latest Build :
1

Latest Commit :
fd0cb9fb614556460b01da86f10bf6162f0f6de6

Server OS:
Ubuntu 20.04


I am able to login to the cyberpanel install using the local server IP and was able to create a website.
All of my DNS records appear to be correct in namecheap as the email server works without issue.
All the respective ports are forwarded at the firewall and appear to be working.
Wordpress + LS Cache install was successful with no issues to note.
Issue is when I try to access the wordpress site I get met with a 404 error from openlitespeed.
Confirmed in the openlitespeed management console at port 7080 that all listenser are configured.
Confirmed in the file manager that all permissions are correct.
Updated rewrite rules with the following and restarted openlitespeed with no change.

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

Renamed plugin folder in hopes that maybe plugin was corrupt, still no change.
Also renamed themes folder with no change.


Spun up another on prem server and completed same steps on a brand new server with same result.


Ran through the Digital Ocean marketplace app for cyberpanel with the same setup but using a different domain and no issues there. So it appears something is wrong with the on prem install, but cannot find any smoking gun.

Please add these rules in htaccess click the fix permission button and run

systemctl restart lsws

and show me if you can access the site?

I have already added these rules and restarted the openlitespeed service

This is what I get when I try to go the site using the server IP

When I go to the external facing IP i get

But I did just discover that if I edit /etc/hosts on my windows desktop to include the server IP and the domain name then the site is accessible with no issues.

dns propagation maybe ?

Is there a reason that if I go to the local server IP I get openlitespeed’s 404 error, but if I update /etc/hosts to point tmknetworks.com to the local server IP I get the actual homepage?

I would’ve thought that going to the local server IP would allow me access to the site itself, but not sure if that’s just a feature of openlitespeed and WordPress.

This is my first time working with it.

Looks to be an issue on my ISP side for making my site available externally and internally from the domain name. As for why my site was not available via the internal server IP it was because the openlitespeed webserver listeners were only configured to listen on the domain name. Once I updated both listeners for http and https to include the internal server IP as a domain I was able to access the site internally via the server IP.

1 Like

This topic was automatically closed 3 hours after the last reply. New replies are no longer allowed.