關於觀看資料的技巧 - Linux
By Lily
at 2009-11-10T23:43
at 2009-11-10T23:43
Table of Contents
→ DRLai:不好意思,想請教…fifo怎麼使用呢?我的系統似乎沒有fifo
try
$ mkfifo tmp.log
$ ./<EXE> > tmp.log
$ cat tmp.log
這樣 tmp.log 就完全不會增長
使用 cat 是因為不能斷開
如果需要"一次輸出幾行"的規定,可以試試
$ while :; do head -2 tmp.log; done
替代 cat
--
try
$ mkfifo tmp.log
$ ./<EXE> > tmp.log
$ cat tmp.log
這樣 tmp.log 就完全不會增長
使用 cat 是因為不能斷開
如果需要"一次輸出幾行"的規定,可以試試
$ while :; do head -2 tmp.log; done
替代 cat
--
Tags:
Linux
All Comments
By Jack
at 2009-11-12T05:54
at 2009-11-12T05:54
Related Posts
請問怎麼掛載(mount)網路磁碟?
By Emily
at 2009-11-10T22:34
at 2009-11-10T22:34
關於觀看資料的技巧
By Ingrid
at 2009-11-10T20:27
at 2009-11-10T20:27
請問Debian的DVD ISO下載問題
By Tracy
at 2009-11-10T14:44
at 2009-11-10T14:44
ASUS M5120 灌 red hat 5.1 網卡設定
By Eartha
at 2009-11-10T11:10
at 2009-11-10T11:10
ubuntu 的氣泡通知
By Thomas
at 2009-11-10T11:05
at 2009-11-10T11:05