[PVFS2-CVS] commit by robl in pvfs2-1/src/server: pvfs2-server.c

CVS commit program cvs at parl.clemson.edu
Fri Mar 4 11:50:12 EST 2005


Update of /projects/cvsroot/pvfs2-1/src/server
In directory parlweb:/tmp/cvs-serv6619/src/server

Modified Files:
	pvfs2-server.c 
Log Message:
pcarns: 
This patch adds the ability to time stamp log messages with a date and
time rather than the default hr:min:sec:usec format.  This is useful for
production systems if you are more worried about the approximate time
that an error occurred rather than debugging performance problems.

The time stamp format is controlled by a new server config file variable
called "LogStamp".  It has three valid values: "none", "usec", or
"datetime", which correspond to the following formats respectively:

Initialization completed successfully.

[20:10:46.631851] Initialization completed successfully.

[02/25 20:10] Initialization completed successfully.



Index: pvfs2-server.c
===================================================================
RCS file: /projects/cvsroot/pvfs2-1/src/server/pvfs2-server.c,v
diff -u -w -p -u -r1.176 -r1.177
--- pvfs2-server.c	7 Dec 2004 15:09:30 -0000	1.176
+++ pvfs2-server.c	4 Mar 2005 16:50:12 -0000	1.177
@@ -197,6 +197,7 @@ int main(int argc, char **argv)
     /* reset gossip debug mask based on configuration settings */
     debug_mask = PVFS_debug_eventlog_to_mask(server_config.event_logging);
     gossip_set_debug_mask(1, debug_mask);
+    gossip_set_logstamp(server_config.logstamp_type);
     gossip_debug(GOSSIP_SERVER_DEBUG,"Logging %s (mask %Lu)\n",
                  server_config.event_logging, Lu(debug_mask));
 



More information about the PVFS2-CVS mailing list