Support

Akeeba Backup for Joomla!

#24901 Cannot Access Backend, Front end fine

Posted in ‘Akeeba Backup for Joomla! 4 & 5’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

Joomla! version
n/a
PHP version
n/a
Akeeba Backup version
n/a

Latest post by on Wednesday, 11 May 2016 17:20 CDT

webcoast
EXTREMELY IMPORTANT: Please attach a ZIP file containing your Akeeba Backup log file in order for us to help you with any backup or restoration issue. If the file is over 2Mb, please upload it on your server and post a link to it.

Description of my issue:
Error attempting to access the backend of my website. The front end is fine. I restored to the last backup using Akeeba Kickstart, which ran with out error, however the same issue still exists. I have attached the log file from the main directory, I cannot find a Akeeba specific error log file? There seems to be a lot of issues relating to Akeeba in the error log.

The error I receive when I try to visit the backend is
"Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, webmaster@xxxxx and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request."

This site uses both administrator secret word, and administrator directory protection (username & password).

I'm not sure when I successfully last logged into the backend of this site, I used Watchful.li to do the last upgrade so it may not have been for a while. However, recently I did go through my Rochen client sites on my reseller account and remove all old unused versions of websites for security reasons, and this site did have one under the main directory. About 18 months ago we redesigned this site so a copy was put into web/ and redesigned and now that one is live. So I am wondering if perhaps the configuration was not quite right in the web/ Akeeba settings or AdminTools settings, and since I deleted the other unused website in the main directory this has affected things? Not really sure but thought it was worth mentioning.

Regards
Nicola

nicholas
Akeeba Staff
Manager
A white page or a page with a 500 Internal Server Error is, in fact, either a .htaccess issue to a PHP fatal error in disguise.

First, let's see if it is a .htaccess issue. Try renaming the .htaccess file in your site's root to htaccess.bak If there is a .htaccess file in the site's administrator directory, try renaming it as well. If that solves the problem, the issue was with a directive in your .htaccess file. We'd like to recommend you to try removing directives from your .htaccess until you find the one which causes the problem.

If that doesn't help, the error you are receiving is in fact a PHP error in disguise. First, check your server's error logs (not the access logs) immediately after visiting the page which throws the error. There should be an exact description of the PHP fatal error which occurred. Sometimes you can find the error messages in files called error_log or error.log inside the site's root and/or administrator directories. If unsure about the error log location, please consult your host. Most likely the error logs are available in your site's cPanel, Plesk control panel or similar hosting account management facility.

If your host does not give you access to the error logs and you have access to the Joomla! administrator area, please log in to your site's back-end, go to Global Configuration, click on the Server tab and set the Error Reporting to Maximum (Joomla! 1.5) or Development (Joomla! 2.x and later). Try visiting the problem page again.

If you still get a blank page, edit your configuration.php file and put the following code right after the final closing curly brace ( this is what a curly brace looks like --> } ) but before the closing PHP tag (it looks like ?> that is a question mark and a greater-than sign):
ini_set( 'display_errors', true );
error_reporting( E_ALL ); 
Try visiting the problem page again.

If you still get a white page, please remote the two lines from your configuration.php file. Edit the .htaccess file in your site's root. If you don't have a file named .htaccess create a new one. Beware that htaccess.txt is a DIFFERENT FILE and will NOT work! Add the following to the end of the file:
php_flag display_errors On
php_value error_reporting 32767
and retry loading the problem page.

If you still get a white page, remove the two lines from your .htaccess file. Now, create a file called php.ini with the following content:
display_errors=on
error_reporting=E_ALL
and upload it into your site's root and your site's administrator directory. Retry loading the problem page.

IMPORTANT: Sometimes the error won't show. Edit your configuration.php and find the line starting with public $error_reporting and set it to:
public $error_reporting = 'development';

This instructs Joomla! to enable maximum error, warnings and notices verbosity. In 99.9% of cases it will result in the error messages being shown on the browser.

Please note that if you can not understand what the PHP error message means, just copy and paste it here verbatim so that we can take a look and point you to the right direction.

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

webcoast
Hi Nicholas, thanks for you excellent reply (as always). It was a .htaccess issue, it was the .htaccess within the administrator directory. Once I renamed that to htaccess.bak I was able to get to the Joomla login screen.

So what happened? Why would this have been corrupted or suddenly stop working?

And do I just need to reset the secret word and cpanel administrator directory protection from within Admin Tools to put back the protection that I had originally, so that a new .htaccess is generated in the administrator directory.

Thanks
Nicola

nicholas
Akeeba Staff
Manager
It's not corrupt.

On the source server you had used the administrator password protection feature in Admin Tools. This creates a .htaccess and a .htpasswd file to tell Apache to apply the authentication check before displaying anything in the administrator directory of your site, including the login page.

Here's the problem. The contents of the .htpasswd file are platform dependent. The password needs to be stored in it in a hashed format which is different by Apache version and operating system. Moreover, the actual commands to tell Apache to enable authentication differ between different versions of Apache. For example, what works on Apache 2.4 running on Linux can't be used on Apache 2.2 running on Windows and vice versa. Admin Tools detects the version of Apache and the operating system at the time of enabling this feature and generates the appropriate .htaccess and .htpasswd files in your site's administrator directory. However, if you move your site to a different server and the installed version of Apache there doesn't understand the hashing format of the password or the instructions it throws a 500 Internal Server Error.

That's why you get the Internal Server Error.

The solution: delete the .htaccess and .htpasswd files from your administrator directory. Go to Admin Tools, Administrator password protection. Re-enable the protection. A new set of files, appropriate for your new server, will be created.

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

System Task
system
This ticket has been automatically closed. All tickets which have been inactive for a long time are automatically closed. If you believe that this ticket was closed in error, please contact us.

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!