mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-09-05 00:55:24 +00:00
726. [func] Implement the "trace" and "notrace" commands in rndc.
This commit is contained in:
2
CHANGES
2
CHANGES
@@ -1,4 +1,6 @@
|
||||
|
||||
726. [func] Implement the "trace" and "notrace" commands in rndc.
|
||||
|
||||
725. [bug] Installing man pages could fail.
|
||||
|
||||
724. [func] New libisc functions isc_netaddr_any(),
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: omapi.h,v 1.18 2001/01/09 21:40:26 bwelling Exp $ */
|
||||
/* $Id: omapi.h,v 1.19 2001/02/06 23:57:15 bwelling Exp $ */
|
||||
|
||||
#ifndef NAMED_OMAPI_H
|
||||
#define NAMED_OMAPI_H 1
|
||||
@@ -43,6 +43,8 @@
|
||||
#define NS_OMAPI_COMMAND_DUMPSTATS "stats"
|
||||
#define NS_OMAPI_COMMAND_QUERYLOG "querylog"
|
||||
#define NS_OMAPI_COMMAND_DUMPDB "dumpdb"
|
||||
#define NS_OMAPI_COMMAND_TRACE "trace"
|
||||
#define NS_OMAPI_COMMAND_NOTRACE "notrace"
|
||||
|
||||
isc_result_t
|
||||
ns_omapi_init(void);
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: omapi.c,v 1.30 2001/01/09 21:39:59 bwelling Exp $ */
|
||||
/* $Id: omapi.c,v 1.31 2001/02/06 23:57:13 bwelling Exp $ */
|
||||
|
||||
/*
|
||||
* Principal Author: DCL
|
||||
@@ -113,6 +113,14 @@ control_setvalue(omapi_object_t *handle, omapi_string_t *name,
|
||||
} else if (omapi_string_strcmp(name, NS_OMAPI_COMMAND_DUMPDB) == 0) {
|
||||
ns_server_dumpdb(ns_g_server);
|
||||
result = ISC_R_SUCCESS;
|
||||
} else if (omapi_string_strcmp(name, NS_OMAPI_COMMAND_TRACE) == 0) {
|
||||
ns_g_debuglevel++;
|
||||
isc_log_setdebuglevel(ns_g_lctx, ns_g_debuglevel);
|
||||
result = ISC_R_SUCCESS;
|
||||
} else if (omapi_string_strcmp(name, NS_OMAPI_COMMAND_NOTRACE) == 0) {
|
||||
ns_g_debuglevel = 0;
|
||||
isc_log_setdebuglevel(ns_g_lctx, ns_g_debuglevel);
|
||||
result = ISC_R_SUCCESS;
|
||||
} else {
|
||||
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL,
|
||||
NS_LOGMODULE_OMAPI, ISC_LOG_WARNING,
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: rndc.c,v 1.38 2001/01/09 21:40:44 bwelling Exp $ */
|
||||
/* $Id: rndc.c,v 1.39 2001/02/06 23:57:16 bwelling Exp $ */
|
||||
|
||||
/*
|
||||
* Principal Author: DCL
|
||||
@@ -270,9 +270,9 @@ command is one of the following:\n\
|
||||
dumpdb Dump cache(s) to the dump file (named_dump.db).\n\
|
||||
stop Save pending updates to master files and stop the server.\n\
|
||||
halt Stop the server without saving pending updates.\n\
|
||||
trace Increment debugging level by one.\n\
|
||||
notrace Set debugging level to 0.\n\
|
||||
*status Display ps(1) status of named.\n\
|
||||
*trace Increment debugging level by one.\n\
|
||||
*notrace Set debugging level to 0.\n\
|
||||
*restart Restart the server.\n\
|
||||
\n\
|
||||
* == not yet implemented\n\
|
||||
@@ -513,10 +513,8 @@ main(int argc, char **argv) {
|
||||
|
||||
notify(command);
|
||||
|
||||
if (strcmp(command, "notrace") == 0 ||
|
||||
strcmp(command, "restart") == 0 ||
|
||||
strcmp(command, "status") == 0 ||
|
||||
strcmp(command, "trace") == 0) {
|
||||
if (strcmp(command, "restart") == 0 ||
|
||||
strcmp(command, "status") == 0) {
|
||||
result = ISC_R_NOTIMPLEMENTED;
|
||||
} else {
|
||||
result = send_command(omapimgr, command, args);
|
||||
|
Reference in New Issue
Block a user