I want to execute 2 scripts: s1
and s2
. s2
must be executed after s1
.
The time of execution of s1
is 2800 seconds, and I need to execute s2
after s1
. Should I put sleep(3000)
in my php between them, or will the second one execute automatically after the first one?
I tried this:
exec('python s1 '); //time of execution is 2800s
sleep(3000); // i want to be sure that the first one is finished
shell_exec('php /home/Parik/s2.php');