I have migrated some php sites from my apache to the openmediavault nginx. One site uses shell_exec that does not work on my NGINX installation.
shell_exec is not disabled according to php.ini.
How can i get this working using NGINX?
NGINX shell_exec
-
- OMV 2.x
- monsen
-
-
what is the shell_exec command?
-
shell_exec is a PHP command. It let's you execute a shell command and get back the output as string:
string shell_exec ( string $cmd ) -
I know what shell_exec is (i've used once for a plugin(, i wanted to know which shell command inside, it might be a permission issue.
-
Oh ok.
I am using ping there. -
And the website is running under a specific username? does that user have a valid shell?
honestly i have no idea if you need a valid shell to execute under php as a user. Maybe try the full path of ping you can locate with which ping
-
I run the website under www-data. Afaik this user has shell access by default. I also tried another user that definitely has shell access with no luck.
using full path or copying ping in the site folder did not help.
Jetzt mitmachen!
Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!