fcdebug

Dynamically sets the log level to debug a library.

You can modify the core-site.xml file to set the log level of all modules using the fs.mapr.trace property. However, you must restart FUSE for the change to take effect. As an alternative, you can use the fcdebug utility to debug a specific library (at runtime) without restarting FUSE.

NOTE
You may have to run this command once per library (to debug).

Syntax

/opt/mapr/server/tools/fcdebug [-i] [-p <process ID>] [-s <shm ID>][-m <module>] [-l <level>] [-o <slowOpsTraceThreshold>]

Parameters

Parameter Description
-i Lists the current debug level of all modules.
-l Specifies the log level. Value can be one of the following: FATAL, ERROR, WARN, INFO, DEBUG.
NOTE
If you do not specify the log level, the default level is applied for the module.
-m Specifies the module for which the log level is to be set. You can retrieve the list of modules with the fcdebug -i -p <process ID> or the fcdebug -i -s <shmid> command.
NOTE
If you do not specify the module, the log level is set on all modules.
-o For RPCs, we use the -o parameter to rate limit error messages.

Default value: 0 milliseconds (no error messages are printed)

Value of x milliseconds indicates that error messages are printed every x milliseconds. There is no limit to the maximum value.
-p Specifies the process ID of either the file client, or the FUSE-based POSIX client.
-s Specifies the shared memory ID (shmid) of either the file client, or the FUSE-based POSIX client.
ATTENTION
Specify either the process ID (-p) or the shmid (-s) option. If you specify both the options, only the shmid (-s) option is used.

Examples

The following command retrieves the list of modules:
Note: Use either the -p or the -s option.

/opt/mapr/server/tools/fcdebug -i -p 196614  (OR)
/opt/mapr/server/tools/fcdebug -i -s 335020032
NOTE
You can run this command after dynamically setting the log level to verify the setting.
The following command dynamically sets the log level to DEBUG on the given module:
Note: Use either the -p or the -s option.

/opt/mapr/server/tools/fcdebug -p 196614 -m FuseOps -l DEBUG (OR)
/opt/mapr/server/tools/fcdebug -s 335020032 -m FuseOps -l DEBUG
NOTE
It may take up to30 seconds for the changes to take effect.
The following command sets the log level to DEBUG on all the modules:
Note: Use either the -p or the -s option.

/opt/mapr/server/tools/fcdebug -p 196614 -l DEBUG (OR)
/opt/mapr/server/tools/fcdebug -s 335020032 -l DEBUG
The following command resets the log level to the default value on all the modules:
Note: Use either the -p or the -s option.

/opt/mapr/server/tools/fcdebug -p 196614 (OR)
/opt/mapr/server/tools/fcdebug -s 335020032