相关疑难解决方法(0)

将stdout/stderr重定向到多个文件

我想知道如何将stderr重定向到多个输出.我用这个脚本试了一下,但我无法让它工作得很好.第一个文件应该有stdout和stderr,而第二个文件应该有错误.

perl script.pl &> errorTestnormal.out &2> errorTest.out
Run Code Online (Sandbox Code Playgroud)

有一个更好的方法吗?任何帮助将非常感激.谢谢.

unix bash stdout stderr

12
推荐指数
1
解决办法
7960
查看次数

Bash模糊重定向 - 重定向到多个文件

$ echo "" >  /home/jem/rep_0[1-3]/logs/SystemOut.log
bash: /home/jem/rep_0[1-3]/logs/SystemOut.log: ambiguous redirect
Run Code Online (Sandbox Code Playgroud)

我可以一次重定向到多个文件吗?

编辑:任何允许使用模糊文件引用的答案?

bash redirect pipe

9
推荐指数
2
解决办法
2万
查看次数

标签 统计

bash ×2

pipe ×1

redirect ×1

stderr ×1

stdout ×1

unix ×1