Admin Tools

#31997 Update to 5.4 fails

Posted in ‘Admin Tools for Joomla!’
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
PHP version
Admin Tools version

Hello. I am attempting to update Admin Tools from v 5.3.3 to 5.4 and the update fails with the following error:

"Joomla\Filesystem\File::delete: Failed deleting inaccessible file .htaccess"

I have tried to update and reinstall the package and both fail with this same error.

I generally have not had problems updating AT before.



And on another Joomla (3.9.13) on another system, Admintools Pro 5.3.4 > 5.4 upgrade fails with the error:

Joomla\Filesystem\File::delete: Failed deleting inaccessible file Autoloader.php

Manual reinstall fails with the same message.

The first step is to go to Admin Tools and use the Fix Permissions button to change the permissions on your files and folders. That will usually fix the problem.

If that doesn't work, you may need to set up the FTP Layer in the Joomla! Global Config file. The FTP Layer is specifically used to get around file ownership inconsistencies that cause these problems.

Dale L. Brackin
Support Specialist

us.gifEnglish: native

Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

My time zone is EST (UTC -5) (click here to see my current time in Philadelphia, PA)

Hi Yes. Fix permissions via AdminTools was the very first thing I tried in both cases, with no resolution.

Also manually ran this:

find /<path-to-docroot> -type f -print0 | xargs -0 chmod 664
find /<path-to-docroot> -type d -print0 | xargs -0 chmod 775
chown -R <docroot-owner>:apache /<path-to-docroot>
chmod 664 /<path-to-docroot>/configuration.php

Updated six other extensions today on both sites including Akeeba Backup with no issues.

I am a very long-term user of AdminTools and have NEVER had the FTP layer enabled on any installation. Nor have had these two upgrade errors (on two separate CentOS 7 systems) before this current update.

Update to 5.4 failed on a 3rd CentOS 7 server.

"Joomla\Filesystem\File::delete: Failed deleting inaccessible file .htaccess"

No problems updating Akeeba Backup, JCE, the custom template, and various other things. Only AdminTools.

Akeeba Staff
Please bear in mind that the extension update is performed by Joomla itself. The error message comes from Joomla itself as you can see. The problem has to do with the combination of the file's ownership and permissions and how it interacts with the user your web server runs under. This is an operating system level issue, not something we can programmatically change.

If you are not sure what I am talking about please read the Security chapter of Akeeba Backup's documentation where I explain in great detail how users, groups, ownership and permissions interact. Yes, I know you are trying to install Admin Tools and I told you to look at Akeeba Backup's documentation. The chapter I am asking you to read has nothing to do with Akeeba Backup; it's about your operating system.

There are two ways these issues can arise:

1. Your web server runs under a user (e.g. "www-data" or "nobody") but your files, having been transferred by FTP, are owned by a different user (e.g. "myuser"). If the third digit of the octal representation of permissions is not 7 your web server cannot write to the file. Write permissions are also required to delete the file.

2. The file is owned by the same user as the one your web server runs under but it has the wrong permissions, e.g. 0400 (read only). In this case Fix Permissions will work but it has to run before trying to write to, rename or delete the file in question.

Given that you already tried using Fix Permissions and it had no effect (it's incorrect to say it "didn't work" -- it worked, but was ineffective because it's not applicable to your use case) I assume that you have the first problem.

The simple way to temporarily address it is to change the ownership of all files and folders under your site's root to the same user your web server runs under. However, as soon as you try to use FTP / SFTP you will end up in ownership and permissions hell.

The correct way to address it is to use FastCGI on your web server so each site runs under the same user as the one owning its files AND have all files and folders of each site on your server owned by the same user you use to FTP / SFTP into it. Also, never ever use SFTP as root, and in no circumstances whatsoever even think about running the web server as root.

In any case, these are operating level / server maintenance problems, not something that our software has any effect on. Please ask your host or systems administrator to help you. We unfortunately cannot offer server setup help beyond pointing out what the problem is for obvious reasons.

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
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: Typically we work Monday to Friday, 9am to 7pm Cyprus timezone (EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets, but we cannot respond to them, outside of our working hours.

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!