Attached is the patch for the gossip log format if anyone is interested 
in applying it.

Michael

On Tue, Mar 09, 2010 at 10:51:38AM -0500, Michael Moore wrote:
> Was there a reason for limiting the datetime format in gossip debugging 
> to not include the year and second? Since usec and thread don't include 
> the date at all it seems having a complete date/time stamp may be 
> helpful (or at least I would consider it helpful). 
> 
> Also, what about making datetime the default format instead of usec? 
> >From a user perspective I'd expect the logs to have date and time 
> information for problem coorelation unless I configure logging 
> otherwise.
> 
> If this is agreeable I'll get a patch together.
> 
> Thanks,
> Michael
> _______________________________________________
> Pvfs2-developers mailing list
> [email protected]
> http://www.beowulf-underground.org/mailman/listinfo/pvfs2-developers
Index: pvfs2/src/common/gossip/gossip.c
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/common/gossip/gossip.c,v
retrieving revision 1.30
diff -a -u -p -r1.30 gossip.c
--- pvfs2/src/common/gossip/gossip.c    9 Dec 2008 19:50:14 -0000       1.30
+++ pvfs2/src/common/gossip/gossip.c    10 Mar 2010 12:13:28 -0000
@@ -479,9 +479,9 @@ static int gossip_debug_fp_va(FILE *fp, 
         case GOSSIP_LOGSTAMP_DATETIME:
             gettimeofday(&tv, 0);
             tp = tv.tv_sec;
-            strftime(bptr, 14, "%m/%d %H:%M] ", localtime(&tp));
-            bptr += 13;
-            bsize -= 13;
+            strftime(bptr, 22, "%m/%d/%Y %H:%M:%S] ", localtime(&tp));
+            bptr += 21;
+            bsize -= 21;
             break;
         case GOSSIP_LOGSTAMP_THREAD:
             gettimeofday(&tv, 0);
Index: pvfs2/src/common/misc/server-config.c
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/common/misc/server-config.c,v
retrieving revision 1.117
diff -a -u -p -r1.117 server-config.c
--- pvfs2/src/common/misc/server-config.c       2 Sep 2009 21:10:39 -0000       
1.117
+++ pvfs2/src/common/misc/server-config.c       10 Mar 2010 12:13:28 -0000
@@ -695,7 +695,7 @@ static const configoption_t options[] =
      *
      * usec: [%H:%M:%S.%U]
      *
-     * datetime: [%m/%d %H:%M]
+     * datetime: [%m/%d/%Y %H:%M:%S]
      *
      * thread: [%H:%M:%S.%U (%lu)]
      *
_______________________________________________
Pvfs2-developers mailing list
[email protected]
http://www.beowulf-underground.org/mailman/listinfo/pvfs2-developers

Reply via email to