0

I have a webfaction account and I install openerp-server 6.1.1, when a start the server from ssh session it's works, when I close the session it close the server too. So I'm trying to start the server with cron.

From cron I call a script like this:

*/1 * * * * ~/webapps/openerp/start.sh

And the script:

.bash_profile

openerp-server -c /home/usuario/webapps/openerp/server.conf

It doesn't work....

But if I call the script from the command line the server load ok....

It any way to debug this?

Community
  • 1
  • 1
Mariano DAngelo
  • 920
  • 5
  • 18
  • 39

1 Answers1

0

Add to your cron command:

su -c "nohup openerp-server -c /home/usuario/webapps/openerp/server.conf &" - username

In this way you will have:

1.- Run the command with an user different from root. 2.- "man nohup" nohup left your app in the backgroung.

I hope it helps you.