i'm creating a service for a socket server in PHP on my server with CentOS 7.
I've a problem starting and retrieving the status of the service with systemctl command.
Basically if i run:
system('systemctl status myservice');
i get a blank string.
I tried with "start" command and it doesn't start anything. I also tried with standard services like httpd.
If i start these commands from SSH Shell everything works.
I don't think it is a problem of disabled shell in php, because if i run
system("pwd");
i get the right output. So shell is active.
What can i do?