mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-09-03 08:05:21 +00:00
830. [func] Implement 'rndc status'.
This commit is contained in:
2
CHANGES
2
CHANGES
@@ -1,4 +1,6 @@
|
||||
|
||||
830. [func] Implement 'rndc status'.
|
||||
|
||||
829. [bug] The DNS_R_ZONECUT result code is only meaningful
|
||||
for secure zone databases. Queries at zone cut points
|
||||
in non-secure zones should always return a delegation.
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: server.c,v 1.325 2001/05/14 19:06:40 bwelling Exp $ */
|
||||
/* $Id: server.c,v 1.326 2001/05/14 20:44:10 bwelling Exp $ */
|
||||
|
||||
#include <config.h>
|
||||
|
||||
@@ -841,11 +841,9 @@ create_bind_view(dns_view_t **viewp) {
|
||||
return (result);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* Create the zone that handles queries for "version.bind. CH". The
|
||||
* version string returned either from the "version" configuration
|
||||
* version string is returned either from the "version" configuration
|
||||
* option or the global defaults.
|
||||
*/
|
||||
static isc_result_t
|
||||
@@ -924,9 +922,8 @@ create_version_zone(cfg_obj_t **maps, dns_zonemgr_t *zmgr, dns_view_t *view) {
|
||||
}
|
||||
|
||||
/*
|
||||
* Create the special view that handles queries for
|
||||
* "authors.bind. CH". The strings returned list
|
||||
* the BIND 9 authors.
|
||||
* Create the special zone that handles queries for "authors.bind. CH".
|
||||
* The strings returned list the BIND 9 authors.
|
||||
*/
|
||||
static isc_result_t
|
||||
create_authors_zone(cfg_obj_t *options, dns_zonemgr_t *zmgr, dns_view_t *view)
|
||||
@@ -2781,18 +2778,16 @@ ns_server_flushcache(ns_server_t *server) {
|
||||
|
||||
isc_result_t
|
||||
ns_server_status(ns_server_t *server, isc_buffer_t *text) {
|
||||
dns_view_t *view;
|
||||
int zonecount = 0;
|
||||
int xferrunning = 0;
|
||||
int xferdeferred = 0;
|
||||
int zonecount, xferrunning, xferdeferred, soaqueries;
|
||||
int n;
|
||||
isc_result_t result;
|
||||
|
||||
zonecount = dns_zonemgr_getcount(server->zonemgr, DNS_ZONESTATE_ANY);
|
||||
xferrunning = dns_zonemgr_getcount(server->zonemgr,
|
||||
DNS_ZONESTATE_XFERRUNNING);
|
||||
xferdeferred = dns_zonemgr_getcount(server->zonemgr,
|
||||
DNS_ZONESTATE_XFERDEFERRED);
|
||||
soaqueries = dns_zonemgr_getcount(server->zonemgr,
|
||||
DNS_ZONESTATE_SOAQUERY);
|
||||
n = snprintf((char *)isc_buffer_used(text),
|
||||
isc_buffer_availablelength(text),
|
||||
"number of zones: %d\n"
|
||||
@@ -2803,8 +2798,7 @@ ns_server_status(ns_server_t *server, isc_buffer_t *text) {
|
||||
"query logging is %s\n"
|
||||
"server is up and running",
|
||||
zonecount, ns_g_debuglevel, xferrunning, xferdeferred,
|
||||
-1, /* XXX */
|
||||
server->log_queries ? "ON" : "OFF");
|
||||
soaqueries, server->log_queries ? "ON" : "OFF");
|
||||
if (n < 0)
|
||||
return (ISC_R_NOSPACE);
|
||||
isc_buffer_add(text, n);
|
||||
|
@@ -2,7 +2,7 @@
|
||||
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.0//EN"
|
||||
"http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd">
|
||||
|
||||
<!-- File: $Id: Bv9ARM-book.xml,v 1.131 2001/05/09 16:58:12 gson Exp $ -->
|
||||
<!-- File: $Id: Bv9ARM-book.xml,v 1.132 2001/05/14 20:44:14 bwelling Exp $ -->
|
||||
|
||||
<book>
|
||||
<title>BIND 9 Administrator Reference Manual</title>
|
||||
@@ -788,11 +788,15 @@ of a server.</para>
|
||||
<varlistentry><term><userinput>flush</userinput></term>
|
||||
<listitem><para>Flushes the server's cache.</para></listitem></varlistentry>
|
||||
|
||||
<varlistentry><term><userinput>status</userinput></term>
|
||||
<listitem><para>Display status of the server.</para></listitem></varlistentry>
|
||||
|
||||
</variablelist>
|
||||
|
||||
<para>In <acronym>BIND</acronym> 9.1, <command>rndc</command> does not
|
||||
yet support all the commands of the BIND 8 <command>ndc</command>
|
||||
utility. Additonal commands will be added in future releases.</para>
|
||||
<para>In <acronym>BIND</acronym> 9.2, <command>rndc</command>
|
||||
supports all the commands of the BIND 8 <command>ndc</command>
|
||||
utility except <command>ndc start</command>, which was also
|
||||
not supported in <command>ndc</command>'s channel mode.</para>
|
||||
|
||||
<para>A configuration file is required, since all
|
||||
communication with the server is authenticated with
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: zone.c,v 1.324 2001/05/14 19:06:42 bwelling Exp $ */
|
||||
/* $Id: zone.c,v 1.325 2001/05/14 20:44:12 bwelling Exp $ */
|
||||
|
||||
#include <config.h>
|
||||
|
||||
@@ -5965,6 +5965,13 @@ dns_zonemgr_getcount(dns_zonemgr_t *zmgr, int state) {
|
||||
zone = ISC_LIST_NEXT(zone, statelink))
|
||||
count++;
|
||||
break;
|
||||
case DNS_ZONESTATE_SOAQUERY:
|
||||
for (zone = ISC_LIST_HEAD(zmgr->zones);
|
||||
zone != NULL;
|
||||
zone = ISC_LIST_NEXT(zone, link))
|
||||
if (DNS_ZONE_FLAG(zone, DNS_ZONEFLG_REFRESH))
|
||||
count++;
|
||||
break;
|
||||
case DNS_ZONESTATE_ANY:
|
||||
for (zone = ISC_LIST_HEAD(zmgr->zones);
|
||||
zone != NULL;
|
||||
|
Reference in New Issue
Block a user