Support

Admin Tools

#10134 Fix Permissions with a large number of files

Posted in ‘Admin Tools 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
Admin Tools version
n/a

Latest post by nicholas on Wednesday, 07 December 2011 10:05 CST

user51436
Actually, this is more a suggestion and best practice than a support request.

I was trying to use the fix permissions tool, but wasn't able.

My first problem was:

Error 503 Service Unavailable
Service Unavailable
Guru Meditation:
XID: 609170194
Varnish cache server


Than, looking this terrific support forum, I discovered that this Varnish cache is a problem from my server. In contact with them, I realized that I can access my website through a alternative secure url (https) that the Varnish cache will not be applied.
Ok, I tried. The error changed, and I started getting this error:

Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 14155798 bytes) 
in /home/storage/a/76/50/tutorbrasil/public_html/administrator/components/com_admintools/models/fixperms.php on line 102


Again, looking this support forum, I realized that if I change my php.ini I could change the memory limit. And my was set to 64M, I changed it to:

memory_limit = 128M


And the error changed as well:

Fatal error: Maximum execution time of 60 seconds exceeded in 
/home/storage/a/76/50/tutorbrasil/public_html/administrator/components/com_admintools/models/fixperms.php on line 329


Then, again, looking this support forum, I realized that I could change my timeout. Than, I changed:

max_execution_time = 90


It was 60 before.

After this, I tried to run fix permissions again, but it never stop to run (I left it running for 7 minutes and canceled).

And thinking more about my site structure and what the fix permissions scripts was doing, I realized that I have a folder with more than 200k files inside of it (a cache folder). And, maybe if I give more time to the script, maybe one hour it will stop.

But, I deleted all the cache folder, and the "Fix Permissions" run as fast as hell, with no error!

So, my suggestion here is to add a configuration to "permissions configurations" to exclude some directories from the action of the script.
Because my cache folder will grow the same size as before, and I don't want to have to delete everything each time I want to run the tool (just while I type this post, I already have 700 files on it).

And the last, but not least, congratulations for this very good piece of software and support.

nicholas
Akeeba Staff
Manager
This is a bug. The contents of the cache (front-end and back-end), tmp and logs directories should not be processed by Fix Permissions. I will fix that in a later release.

I agree that adding custom exceptions would be the ideal solution, but I won't implement that yet. I have some very good reasons not to want to do that yet (sorry, it's one of the rare cases when I can't comment on the 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!

user51436
Hello Nicholas,

Thanks for your reply.
But, I don't see how Admin Tools will guess my cache directory (isn't joomla's directory), is the directory /forum/mimetex/pictures, used with my phpBB forum.

Kind regards,
Thyago

user51436
If I rename this directory as "cache", it will be excluded from Admin Tools Fix Permissions?

nicholas
Akeeba Staff
Manager
Hm, in that case it's best not to use Admin Tools' Fix Permissions feature. It's not designed to handle Joomla! installations with non-Joomla! scripts or other child sites installed in subdirectories of the main Joomla! site. This should be possible in a future version of Admin Tools.

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!

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!