CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Beginner:
call perl script in background in another perl script

 



raopatwari
Novice

Jan 28, 2016, 11:13 AM

Post #1 of 3 (2003 views)
call perl script in background in another perl script Can't Post

Hello Gurus,
I am just beginning to code in perl. I was given a task.
I have two scripts
script "a", "b"

in script "a"
I have couple of steps
1,2,3...

as soon as they are done I have to call script "b", when script is "b" is called, script "a" should exit and continue to do execute script "b".

Note: exiting out of script "a" should not depend on script "b" completion.
Your help is greatly appreciated.

Rao


Laurent_R
Veteran / Moderator

Jan 28, 2016, 4:06 PM

Post #2 of 3 (1995 views)
Re: [raopatwari] call perl script in background in another perl script [In reply to] Can't Post

This is a job for the exec system call function, which does exactly what you need: calling another program and exiting immediately (actually, the new program is replacing the current Perl script within the existing process, so that exec does not even create a new process).


raopatwari
Novice

Jan 28, 2016, 5:27 PM

Post #3 of 3 (1989 views)
Re: [Laurent_R] call perl script in background in another perl script [In reply to] Can't Post

Thank you very Laurent. I will try that command.
Regards
Rao


(This post was edited by raopatwari on Jan 28, 2016, 5:28 PM)

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives