Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: Executing independet commands in PERL

by AgentM (Curate)
on Mar 05, 2001 at 00:41 UTC ( [id://62128]=note: print w/replies, xml ) Need Help??


in reply to Executing independent commands in PERL

It seems that you have more than enough help posted above, so let me just quickly make sure that you understand the differences between fork, exec, and system. They are very often confusing. Your analysis of exec is not entirely correct.
  • exec replaces the current process binary with a new executable binary. Hence, if you ran a perl script and called exec in the same process, you would lose anything that you wrote in that perl script (with some exceptions which are not relevant under Winduz).
  • fork will create a new process and populate it with instructions or a new process, hence giving birth to
  • system which is essentially a fork and exec. The process creates a child process and populates it with the shell command. It then proceeds to waitpid on that system call.

AgentM Systems nor Nasca Enterprises nor Bone::Easy nor Macperl is responsible for the comments made by AgentM. Remember, you can build any logical system with NOR.
  • Comment on Re: Executing independet commands in PERL

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://62128]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having an uproarious good time at the Monastery: (6)
As of 2024-04-19 10:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found