BIND 10 #1443: allow bind10 to run even if configuration is corrupted

BIND 10 Development do-not-reply at isc.org
Thu Mar 22 14:40:08 UTC 2012


#1443: allow bind10 to run even if configuration is corrupted
-------------------------------------+-------------------------------------
                   Reporter:  jreed  |                 Owner:  muks
                       Type:         |                Status:  reviewing
  defect                             |             Milestone:
                   Priority:         |  Sprint-20120403
  medium                             |            Resolution:
                  Component:         |             Sensitive:  0
  configuration                      |           Sub-Project:  Core
                   Keywords:         |  Estimated Difficulty:  4
            Defect Severity:  N/A    |           Total Hours:  0
Feature Depending on Ticket:         |
        Add Hours to Ticket:  0      |
                  Internal?:  0      |
-------------------------------------+-------------------------------------
Changes (by jelte):

 * owner:  jelte => muks


Comment:

 Replying to [comment:11 muks]:
 >
 > {{{
 > diff --git a/src/bin/bind10/bind10_src.py.in
 b/src/bin/bind10/bind10_src.py.in
 > +        if self.clear_config is not None:
 > +            args.append("--clear-config")
 > }}}
 >
 > That should just check `if self.clear_config:` as it's boolean. I
 believe a check for not None will always be true here. I'm no Python guru,
 so please check this. :)
 >

 you are right, fixed

 > {{{
 > +                      help="Back up the configuration file and start
 with a clean one")
 > }}}
 >
 > I think "backup" should be used as a single word here.
 >

 In fact, 'backup' is not even a verb, so i've changed it to "Create backup
 of the configuration file and start with a clean configuration".

 > {{{
 > diff --git a/src/bin/cfgmgr/tests/b10-cfgmgr_test.py.in
 b/src/bin/cfgmgr/tests/b10-cfgmgr_test.py.in
 >  class MyConfigManager:
 > -    def __init__(self, path, filename):
 > +    def __init__(self, path, filename, session=None,
 rename_config_file=None):
 >          self._path = path
 > }}}
 >
 > Here too, the default value should be `rename_config_file=False` (though
 it's not used here).
 >

 done

 > It probably also needs a ChangeLog entry.
 >

 of course;
 [func] jelte
 Added a command-line option '--clear-config' to bind10, which causes the
 system to create a backup of the existing configuration database file, and
 start out with a clean default configuration. This can be used if the
 configuration file is corrupted to the point where it cannot be read
 anymore, and BIND 10 refuses to start. The name of the backup file can be
 found in the logs (CFGMGR_RENAMED_CONFIG_FILE).

 > Please pass it back to me when you have/won't fix these, and I'll review
 it again. :)

 thanks :)

 oh, btw, i had forgotten something else; we keep our log message files in
 alphabetical order, and have a tool to help with that
 (tools/reorder_message_file.py), ran the modified .mes file through it, so
 the diff contains a fix there too

-- 
Ticket URL: <http://bind10.isc.org/ticket/1443#comment:13>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development


More information about the bind10-tickets mailing list