Wordpress problem No Index active

CashDroid

Member
Jun 11, 2019
5
1
3
Torino
cPanel Access Level
Website Owner
Hello,
I have a VPS on Contabo and I have activated a new Wordpress site. Although everything is fine, I access the dashboard and all internal articles, categories and tags without problems, but when I access the home page I only see the Index Of section with a list of all the files and folders in the folder as I have problems accessing to the /WP-ADMIN section.

I solved by disabling the Indices as per attachment but this creates SEO problems for me and also now by accessing the dash /wp-admin error ERR_TOO_MANY_REDIRECTS appears.

The .htaccess file is correct and the error occurs both before and after switching to HTTPS.
I tried them all, even reinstalling the cPanel but the problem cannot be solved except by turning off the indexes but I would like to reactivate them.

Do you have a solution?
Thank you very much

CentOS 7.6
cPanel & WHM version 80.0.14
WP 5.2.1
 

Attachments

CashDroid

Member
Jun 11, 2019
5
1
3
Torino
cPanel Access Level
Website Owner
Hi @cPanelLauren,
my .htaccess is
Code:
# 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>
Attached is the result of the curl command

In Wordpress Address i have
Code:
https://www.example.com
Thanks for all
 

Attachments

cPanelLauren

Forums Analyst II
Staff member
Nov 14, 2017
8,110
659
263
Houston
cPanel Access Level
DataCenter Provider
Hi @CashDroid


Thanks for providing that information. Can you please open a ticket using the link in my signature? Once open please reply with the Ticket ID here so that we can update this thread with the resolution once the ticket is resolved.

I was hoping to match this to a case we have open currently but it seems to only be affecting CloudLinux systems and you're running CentOS 7.


Thanks!
 

CashDroid

Member
Jun 11, 2019
5
1
3
Torino
cPanel Access Level
Website Owner
Established that it is not a cPanel problem I solved by inserting the string "Directoryindex index.php" in the .htaccess file. On the VPS that I manage, it has never happened to me.
How can I check the index in Apache?
 

CashDroid

Member
Jun 11, 2019
5
1
3
Torino
cPanel Access Level
Website Owner
The final solution is to fix this problem, it is to reconfigure the Directory Index configuration with the following steps:

- Login to WHM as the root user
- Navigate to: Home »Service Configuration» Apache Configuration »DirectoryIndex Priority
- Click the save button
- Click the Rebuild Apache configuration and Restart Apache button

So you don't even have to edit the .htaccess file
 
  • Like
Reactions: cPanelLauren

cPanelLauren

Forums Analyst II
Staff member
Nov 14, 2017
8,110
659
263
Houston
cPanel Access Level
DataCenter Provider
Interesting though, you shouldn't have needed to rebuild the apache configuration without having made any changes - I actually believe this relates to an internal case we have open: CPANEL-27677 in which it's found that Apache does not have DirectoryIndex set to anything (saving and rebuilding the configuration would fix this)

This issue is resolved in v82 of cPanel and should be resolved in the current RELEASE version of cPanel/WHM 80.0.15