{"id":1713,"date":"2012-07-11T10:21:21","date_gmt":"2012-07-11T14:21:21","guid":{"rendered":"http:\/\/hstore.cs.brown.edu\/?page_id=1713"},"modified":"2013-10-15T17:32:14","modified_gmt":"2013-10-15T21:32:14","slug":"output-logs","status":"publish","type":"page","link":"https:\/\/hstore.cs.brown.edu\/documentation\/debugging\/output-logs\/","title":{"rendered":"Execution Output Logs"},"content":{"rendered":"
The Java portion of H-Store uses log4j<\/a> to generate all debug messages. All of the log output generated by the H-Store nodes in the cluster will be automatically sent back to the machine where you invoked the hstore-benchmark<\/tt> target from the command-line. The log files will be automatically split into separate files in directory defined in the site.log_dir<\/a> configuration parameter.<\/p>\n In the root directory of the H-Store repository, there is a file log4j.properties<\/a> that controls the debug out portion of the Java frontend. This file is read in when the system starts at each node and then is polled every 10 seconds to check for changes. Note that this file is only local to the HStoreSite running from that directory (i.e., the files is not automatically sent to other hosts in the H-Store cluster).<\/p>\n To enable debug output for a particular class file or package, you need to add entry into log4j.properties<\/tt> and declare what output level you want for it. There are three different log levels for log4j:<\/p>\n For example, to enable DEBUG<\/tt> output for the HStoreSite<\/a> class, one would add the following entry to the properties file:<\/p>\n Each log message generated by the system will be tagged based on the thread that generated it. You can reference the table below to determine which thread a message is from (see also the thread name variables in HStoreConstants<\/a>).<\/p>\n The C++ portion of H-Store uses logging levels that are defined at compile time. These levels are defined in debuglog.h<\/a>. Every log message will appear in their corresponding HStoreSite log output file (as defined in site.log_dir<\/a>). If you need to change these levels to debug a certain feature, you must recompile the engine and set the site.exec_ee_log_level<\/a> parameter to one of the following levels:<\/p>\n To use the Execution Engine with a more verbose log-level, you can pass the site.exec_ee_log_level<\/tt> parameter at compilation time. You pass in either the log level name<\/em> or its value<\/em>. Note that we have to recompile the engine from scratch in order to ensure that the log-level value is propagated.<\/p>\n For example, to enable DEBUG<\/tt> level messages, you will execute the following command:<\/p>\n Using the name of the log level also works as well:<\/p>\n\n
log4j.logger.edu.brown.hstore.HStoreSite=DEBUG<\/B><\/pre>\n
\n
\n Thread Identifier<\/th>\n Description<\/th>\n<\/tr>\n \n HXX-YYY<\/td>\n The thread that is assigned to a PartitionExecutor<\/tt>. The XX<\/b> portion of the name represents the HStoreSite<\/tt> id, while the YY<\/b> represents the unique partition id.<\/td>\n<\/tr>\n \n HXX-coord<\/td>\n The HStoreCoordinator<\/tt> thread. This thread is responsible for managing distributed transactions in the system.<\/td>\n<\/tr>\n \n HXX-queue<\/td>\n To be written…<\/i><\/td>\n<\/tr>\n \n HXX-listen<\/td>\n The VoltProcedureListener<\/tt> thread. This is the thread that listens for incoming transaction requests from clients and either queues them immediately in PartitionExecutor<\/tt> if they are single-partitioned, or hands them off to H-Store’s TransactionQueueManager<\/tt>.<\/td>\n<\/tr>\n<\/table>\n Execution Engine Debug Levels<\/h2>\n
\n
\n 100<\/tt><\/td>\n TRACE<\/tt><\/td>\n All log messages are printed. Note that this will significantly reduce the performance of the engine at runtime.<\/td>\n<\/tr>\n \n 200<\/tt><\/td>\n DEBUG<\/tt><\/td>\n Only debug messages are printed.<\/td>\n<\/tr>\n \n 300<\/tt><\/td>\n INFO<\/tt><\/td>\n Only info messages are printed.<\/td>\n<\/tr>\n \n 400<\/tt><\/td>\n WARN<\/tt><\/td>\n Only warning messages are printed.<\/td>\n<\/tr>\n \n 500<\/tt><\/td>\n ERROR<\/tt><\/td>\n Only fatal error messages are printed. This is the default setting.<\/B><\/td>\n<\/tr>\n \n 1000<\/tt><\/td>\n DISABLE<\/tt><\/td>\n All output messages from the engine are suppressed. Some exceptions may be propagated up into the HStoreSite<\/tt>, but the log files will not include additional information.<\/td>\n<\/tr>\n<\/table>\n ant clean-cpp<\/tt> build<\/tt> -Dsite.exec_ee_log_level=200<\/pre>\n
ant clean-cpp<\/tt> build<\/tt> -Dsite.exec_ee_log_level=DEBUG<\/pre>\n