从 PERL 的 $sftp->get 或 do {...} 中获取错误文本
我不是 perl 程序员,但需要调试错误。我正在使用 Net:SFTP:Foreign 包。
当我尝试获取文件时,以下调用失败:
$sftp->get(source,destination) or do { print "something goneError."}
此行返回“something goneError.”。我想要的是找出哪里出了问题!如何提取失败原因?
顺便说一句,这个脚本已经运行了几个月,没有出现任何错误。该脚本非常可靠,我只是不知道如何捕获失败的原因。
I'm not a perl programmer but need to debug an error. I'm using the Net:SFTP:Foreign package.
When I attempt to get files, the following call fails:
$sftp->get(source, destination) or do { print "something went wrong."}
This line returns "something went wrong." What I would like is to find out WHAT went wrong! How can I extract the reason for failure?
By the way, this script has been working for months without an error. The script is very reliable, I just don't know how to capture the reason for failure.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)