script de execução php aguar
exec('sh somescript.sh');//this will wait for script to finish
exec('sh somescript.sh >/dev/null 2>&1 &'); //this will NOT wait
Friendly Hawk
exec('sh somescript.sh');//this will wait for script to finish
exec('sh somescript.sh >/dev/null 2>&1 &'); //this will NOT wait