首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >无法从服务器计算机运行perl脚本

无法从服务器计算机运行perl脚本
EN

Stack Overflow用户
提问于 2011-11-18 16:52:47
回答 1查看 416关注 0票数 0
代码语言:javascript
复制
        String name="perl http://10.107.97.201//C:/KATool/code/names.pl ";
        Process p = Runtime.getRuntime().exec(name);

        BufferedReader stdInput = new BufferedReader(new 
             InputStreamReader(p.getInputStream()));

        BufferedReader stdError = new BufferedReader(new 
             InputStreamReader(p.getErrorStream()));

        // read the output from the command
        System.out.println("Here is the standard output of the command:\n");
        while ((s = stdInput.readLine()) != null) {
            System.out.println(s);
        }

我无法从服务器计算机运行perl脚本。上面是应用程序中提到的服务器ip(虚拟)。在这件事上请帮帮我。提前谢谢你..

EN

回答 1

Stack Overflow用户

发布于 2011-11-18 17:01:01

您是否有权访问远程计算机?你能从你的终端运行这行代码吗:

代码语言:javascript
复制
perl http://10.107.97.201//C:/KATool/code/names.pl

在您的终端中运行此命令,并调查您收到的错误消息。也许perl脚本本身就是损坏的,或者只是您没有(或丢失)对远程计算机的访问权限。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/8179854

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档