title: how to efficiently monitor system stat using vmstat?
body: <p>Am getting the real-time memory stats from <b>vmstat</b> command. I did this using following steps:</p>
  
  <pre><code>$nohup vmstat 60 &gt; vmstatrecord.app &amp;
  </code></pre>
  
  <p>the command executes in background and writes the log to the file <b>vmstatrecord.app</b>. When i see use the command </p>
  
  <pre><code>$ps -A | grep stat
  </code></pre>
  
  <p>I could see the vmstat running in the background and i could also access the log using tail command as:</p>
  
  <pre><code>$tail -f vmstatrecord.app
  </code></pre>
  
  <p>the file updates every 60sec interval. </p>
  
  <p>Now my question is <br>
  1. <b>process continues to write to the file</b> so what will happen if i leave for days ?<br></p>
  
  <p>Assumption:<br>
  If the process writes the file forever <b>am afraid that the file size might grow too large</b> <br></p>
  
  <ol>
  <li>If my assumption is correct and my steps are inefficient. Is there any alternatives to achieve what am trying to achieve from my above steps ? </li>
  </ol>