Hey Greg,
Did you happen to restart Apache after changing the shell_exec setting? Below is the code we use to detect shell_exec, you might shoot a copy over to your host as ask them if they have anything that prevents the code from working correctly in their enviroments:
public static function IsShellExecAvailable()
{
$cmds = array('shell_exec', 'escapeshellarg', 'escapeshellcmd', 'extension_loaded');
//Function disabled at server level
if (array_intersect($cmds, array_map('trim', explode(',', @ini_get('disable_functions')))))
return false;
//Suhosin: http://www.hardened-php.net/suhosin/
//Will cause PHP to silently fail
if (extension_loaded('suhosin'))
{
$suhosin_ini = @ini_get("suhosin.executor.func.blacklist");
if (array_intersect($cmds, array_map('trim', explode(',', $suhosin_ini))))
return false;
}
// Can we issue a simple echo command?
if (!@shell_exec('echo duplicator'))
return false;
return true;
}
Thanks for the response, its a VPS with root access so no doubt it would be myself that would need to look into this.
Although I did notice the comment about suhosin, I have that enabled, is that my problem?
Edit: Yes I did restart apache I also had to perform a full reboot not long after too so it definitely wont be that š
It can… You might want to look at the suhsion config setup and make sure that shell_exec is not in the list for suhosin.executor.func.blacklist…
Thanks
Hi there,
I dont even have the suhosin.executor.func.blacklist defined, I was under the impression it should be in php.ini but it is not, do you know of any other locations it could be disabled there?
Hey Greg,
I believe your correct it is a php.ini directive. What if you just create an entry for it and set it to nothing, that may be enough to enable it?
I removed suhosin instead, no change still not detected.
As far as I can see it is enabled on the server (or atleast not disabled)
That is odd… I would just open the file below on your local server comment out the current code and have it return true.
https://plugins.svn.wordpress.org/duplicator/tags/1.1.14/classes/utility.php
At this point I’m not sure what the stag is, if you make any progress let me know and I might be able to work it back into the plugin for others…
for some reason the plugin won’t activate any more either, I have deleted and reinstalled it but still wont work, I click activate and the page seems to just reload without it activating
That is odd… Is it just Duplicator or are you seeing it with other plugins?
just a duplicator issue, everything else is fine to be honest rather weird
If you want to submit a ticket I can have a look (just refer to this thread), at this point I’m not really sure, don’t recall having seen this issue before…
Sure will do can you provide me a link to your ticket system?
You can follow the links in the plugin from the help menu or just go here.