WARNING: This is the _old_ Lustre wiki, and it is in the process of being retired. The information found here is all likely to be out of date. Please search the new wiki for more up to date information.

Difference between revisions of "Lustre Debugging for Developers"

From Obsolete Lustre Wiki
Jump to navigationJump to search
Line 14: Line 14:
 
Each service maintains a request history, which can be useful for first occurrence troubleshooting. ''Prlrpc'' is an RPC protocol layered on LNET. This protocol deals with stateful servers and has semantics and built in support for recovery. ''Prlrpc'' is a subsystem in the Lustre Debug Messages section.
 
Each service maintains a request history, which can be useful for first occurrence troubleshooting. ''Prlrpc'' is an RPC protocol layered on LNET. This protocol deals with stateful servers and has semantics and built in support for recovery. ''Prlrpc'' is a subsystem in the Lustre Debug Messages section.
  
For more information about how to use ''prlrpc'', see [http://wiki.lustre.org/manual/LustreManual18_HTML/LustreDebugging.html#50532482_pgfId-1291584 Section 23.5: ''Ptlrpc Request History''] in the [[Lustre Documentation|''Lustre Operations Manual'']].
+
For more information about how to use ''prlrpc'', see [http://wiki.lustre.org/manual/LustreManual18_HTML/LustreDebugging.html#50638978_47732 Section 23.5: ''Ptlrpc Request History''] in the [[Lustre Documentation|''Lustre Operations Manual'']].
 
 
 
 
  
 
=Finding memory leaks using ''leak_finder.pl''=
 
=Finding memory leaks using ''leak_finder.pl''=

Revision as of 22:13, 18 February 2010

The procedures below may be useful to developers debugging Lustre code.

Adding Debugging to the Source Code

The debug infrastructure provides a number of macros that can be used in Lustre™ source code to aid in debugging or reporting serious errors.

To use these macros, you will need to set the DEBUG_SUBSYSTEM variable at the top of the file to as shown below:

#define DEBUG_SUBSYSTEM S_PORTALS

A list of available macros with descriptions is provided in see Section 23.2.8: Adding Debugging to the Lustre Source Code in the Lustre Operations Manual.

Accessing a ptlrpc Request History

Each service maintains a request history, which can be useful for first occurrence troubleshooting. Prlrpc is an RPC protocol layered on LNET. This protocol deals with stateful servers and has semantics and built in support for recovery. Prlrpc is a subsystem in the Lustre Debug Messages section.

For more information about how to use prlrpc, see Section 23.5: Ptlrpc Request History in the Lustre Operations Manual.

Finding memory leaks using leak_finder.pl

Memory leaks can occur in code when memory has been allocated and then not freed once it is no longer required. The leak_finder.pl program provides a way to find memory leaks.

For details, see Section 23.2.4: Finding Memory Leaks in the Lustre Operations Manual.