diff -urN nufw-2.2.21.orig/scripts/nuauth_command/nuauth_command/client.py nufw-2.2.21/scripts/nuauth_command/nuauth_command/client.py --- nufw-2.2.21.orig/scripts/nuauth_command/nuauth_command/client.py 2008-12-09 05:02:10.000000000 +1300 +++ nufw-2.2.21/scripts/nuauth_command/nuauth_command/client.py 2010-03-24 13:51:11.245790323 +1300 @@ -23,12 +23,12 @@ COMMANDS_COMPLETION = ("version", "users", "refresh cache", "refresh crl", "disconnect ", "uptime", "reload", "help", "quit", - "display debug_level", "display debug_areas", "debug_level", + "display debug_level", "display debug_areas", "debug_level", "display threads", "debug_areas", "firewalls", "packets count", "reload periods") COMMANDS_REGEX = re.compile( "^(?:version|users|firewalls|refresh (cache|crl)|nupik!|display debug_(?:level|areas)|" "debug_level [0-9]+|debug_areas [0-9]+|" - "disconnect (?:.+)|uptime|reload(?: periods)?|help|quit|packets count)$") + "disconnect (?:.+)|uptime|reload(?: periods)?|help|quit|packets count|display threads)$") DISCONNECT_REGEX = re.compile("^disconnect +(.*)$") diff -urN nufw-2.2.21.orig/src/nuauth/command.c nufw-2.2.21/src/nuauth/command.c --- nufw-2.2.21.orig/src/nuauth/command.c 2008-12-21 10:00:59.000000000 +1300 +++ nufw-2.2.21/src/nuauth/command.c 2010-03-24 13:52:42.000495672 +1300 @@ -42,6 +42,7 @@ "reload periods: reload the time periods\n" "display debug_level\n" "display debug_areas\n" +"display threads\n" "debug_level LEVEL\n" "debug_areas AREAS\n" "help: display this help\n" @@ -341,6 +342,18 @@ encoder_add_int32(encoder, nuauthconf->debug_level); } else if (strcmp(command, "display debug_areas") == 0) { encoder_add_int32(encoder, nuauthconf->debug_areas); + } else if (strcmp(command, "display threads") == 0) { + char buffer [250]; + int n; + n=sprintf (buffer, "User threads: %u\nUser session threads: %u\nlogger user pool full: %s\nlogger session pool full: %s\n", g_thread_pool_unprocessed(nuauthdatas->user_loggers), g_thread_pool_unprocessed(nuauthdatas->user_session_loggers), (nuauthdatas->loggers_pool_full)?"true":"false", (nuauthdatas->session_loggers_pool_full)?"true":"false"); + /* encoder_add_string(encoder,"logger pool fulls: "); + encoder_add_bool(encoder, nuauthdatas->loggers_pool_full); + encoder_add_string(encoder,"User session threads: "); + encoder_add_int32(encoder, g_thread_pool_unprocessed(nuauthdatas->user_session_loggers)); + encoder_add_string(encoder,"logger sesson pool fulls: "); + encoder_add_bool(encoder, nuauthdatas->session_loggers_pool_full); */ + encoder_add_string(encoder,buffer); + } else if (strcmp(command, "packets count") == 0) { encoder_add_int32(encoder, g_hash_table_size(conn_list)); } else {