1
我正在運行以下命令並獲取以下輸出,並將其保存到文件中。如何從iostat linux命令的輸出中刪除重複的頭文件
$sysstat/iostat -mdt sda1 1 >> /tmp/disk.out &
Outout是繼
Linux 3.16.0-25-generic (bscpower8n2) 09/25/2016 _ppc64le_ (192 CPU)
09/25/2016 08:12:01 PM
Device: tps MB_read/s MB_wrtn/s MB_read MB_wrtn
sda1 0.00 0.00 0.00 1 0
09/25/2016 08:12:02 PM
Device: tps MB_read/s MB_wrtn/s MB_read MB_wrtn
sda1 0.00 0.00 0.00 0 0
09/25/2016 08:12:03 PM
Device: tps MB_read/s MB_wrtn/s MB_read MB_wrtn
sda1 0.00 0.00 0.00 0 0
09/25/2016 08:12:04 PM
Device: tps MB_read/s MB_wrtn/s MB_read MB_wrtn
sda1 0.00 0.00 0.00 0 0
09/25/2016 08:12:05 PM
Device: tps MB_read/s MB_wrtn/s MB_read MB_wrtn
sda1 0.00 0.00 0.00 0 0
09/25/2016 08:12:06 PM
Device: tps MB_read/s MB_wrtn/s MB_read MB_wrtn
sda1 0.00 0.00 0.00 0 0
但我想把它保存而不報頭和日期也是在同一行。任何人都可以讓我知道如何實現這一目標? e.g
09/25/2016 08:12:01 PM sda1 0.00 0.00 0.00 1 0
09/25/2016 08:12:02 PM sda1 0.00 0.00 0.00 0 0
感謝 舒亞