PDA

View Full Version : I'm a nut in suPHP help me I gonna cry


hugolambert
13th December 2009, 09:48
Hi all
I installed ispconfig and enabled suphp for my website, but when I try to do what ispconfig usually do when creating mails, I use exec (su .... blah blah) and I got this error message : "su: must be run from a terminal"
So now I feel alone and sad in front of this stupid error log file :(

till
14th December 2009, 15:45
Please post the exact error message.

hugolambert
14th December 2009, 22:06
the exact message in the ispconfig log is [Sun Dec 13 08:44:14 2009] [error] [client my.ip] su: must be run from a terminal, referer: http://www.mywebsite.fr/

hugolambert
15th December 2009, 18:58
I really cannot get to the point : why on earth ispconfig can do exec commands under php when websites with suexec and suphp cannot do it?
Why?????????????????????????

till
15th December 2009, 19:01
You totally mix up things. The ispconfig interface does not use a single exec commnd. ISPConfig consists of a interface part which runs on apache and a separate daemon which executes commands and has higher priveliges.

hugolambert
15th December 2009, 21:56
so there is no way for instance that I call a cgi script that would be able to create mail directories on the server like it does on ispconfig?
And if not, how to run a deamon with higher privileges? :confused:

till
16th December 2009, 11:06
so there is no way for instance that I call a cgi script that would be able to create mail directories on the server like it does on ispconfig?

Thts not possible. At least not without big security holes. You will have to use a separated daemon and interface part.

And if not, how to run a deamon with higher privileges?

Thats too much to explian here in detail. There are two ways, either run a daemon that is started automatically at boot time with a init script that processes changes in the system or you use a root cronjob for that. Take a look at the ispconfig sources and installer if you want to know how this can be done.

But the easiest way is, just use ispconfig. It does everything that is needed to configure your system and if you want to add additional mailboxes from a external script, use the remote api.

hugolambert
16th December 2009, 15:50
Thanks for the info, but how can I install the remote framework? there is nothing in the update section (system) of ispconfig3

till
16th December 2009, 16:03
The remote framework is already part of ispconfig. The demo files are also in the remote_client directory of the ispconfig 3 tar.gz. Dont mix this up with the remoting framework of ispconfig 2.

hugolambert
19th December 2009, 22:44
Thank's for the tips ! It's great !