WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH] Add periodic fflush to xentop batch mode.

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] Add periodic fflush to xentop batch mode.
From: Yusuke KANEKI <Kaneki.Yusuke@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
Date: Fri, 14 Mar 2008 21:38:23 +0900
Delivery-date: Fri, 14 Mar 2008 05:39:16 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Add periodic fflush to xentop(batch mode).

If you want to make monitor tool using the following command,
you can not get output every some seconds.

xentop -b -d 1 > xentop.log
(above tool use tail command to get periodic data from xentop.log)

This patch is useful when you get 
xentop output(batch mode) periodicaly using pipe.


Best Regards,
 Yusuke Kaneki

----

*** old/xentop.c        2008-03-14 21:00:28.000000000 +0900
--- new/xentop.c        2008-03-14 21:00:36.000000000 +0900
***************
*** 1121,1126 ****
--- 1121,1127 ----
                do {
                        gettimeofday(&curtime, NULL);
                        top();
+                       fflush(stdout);
                        oldtime = curtime;
                        if ((!loop) && !(--iterations))
                                break;



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH] Add periodic fflush to xentop batch mode., Yusuke KANEKI <=