如何从 Perl 启动程序作为单独的进程?
可能的重复:
如何在 Perl 中触发并忘记进程?< /a>
我正在寻找一种从 Perl 脚本调用新进程的方法,这将使启动的程序和启动该程序的 Perl 脚本同时继续工作。
该计划是 SIPp(如果它很重要)。
谢谢。
Possible Duplicate:
How can I fire and forget a process in Perl?
I'm looking for a way to invoke a new process from a Perl script, that will let a launched program and a Perl script, from which it's launched, proceed to work concurrently.
The program is SIPp, if it's important.
Thank you.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
如果您确实想要单独的进程,那么另一个选择是
fork
和exec
。If you actually want separate processes, then another option is
fork
andexec
.SIPp 有“-bg”命令行参数。
此参数以后台模式启动 SIPp。
SIPp has "-bg" commandline parameter.
This parameter launches SIPp in background mode.
使用 Proc::Background
Use Proc::Background
在Windows系统中您可以使用“启动”命令。
例如:
启动记事本
或
启动 /d"C\Program Files\Sipp3.1" sipp.exe -sn uac
In Windows system you may use "start" command.
For example:
start notepad
OR
start /d"C\Program Files\Sipp3.1" sipp.exe -sn uac