我想将rfcomm的输出重定向到bash中的一个文件,如下所示
$ rfcomm watch hci0 > rfcomm.log &或
$ rfcomm watch hci0 > rfcomm.log 2>&1 &然而,rfcomm.log仍然是空的。
为什么?
发布于 2017-01-23 23:17:44
如果该程序直接写入tty,那么您可以通过使用伪tty (-t)通过ssh调用它来捕获输出。尝试:
ssh -t localhost 'rfcomm watch hci0' > rfcomm.loghttps://stackoverflow.com/questions/41804222
复制相似问题