Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 227600 - bind-chroot update overwrites user supplied ROOTDIR setting
Summary: bind-chroot update overwrites user supplied ROOTDIR setting
Alias: None
Product: Fedora
Classification: Fedora
Component: bind
Version: rawhide
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Adam Tkac
QA Contact: Ben Levenson
Depends On:
Blocks: 451450
TreeView+ depends on / blocked
Reported: 2007-02-07 00:22 UTC by Axel Thimm
Modified: 2013-04-30 23:35 UTC (History)
1 user (show)

Fixed In Version: 9.3.4-3.fc6
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2007-02-26 13:04:26 UTC

Attachments (Terms of Use)

Description Axel Thimm 2007-02-07 00:22:35 UTC
Description of problem:
The bind update overwrites any settings like


with the default ROOTDIR

Version-Release number of selected component (if applicable):

How reproducible:
3/3 on FC6, 1/1 on FC5

Steps to Reproduce:
1.Use a custom ROOTDIR
2.upgrade bind packages
Actual results:
ROOTDIR gets reset

Expected results:
Should not touch uncommented ROOTDIR setting

Additional info:
Hit me on FC5/FC6 alike and for consistency (?) filed under devel.

If the ROOTDIR is not to be changed by the user it should be hardcoded and not
part of sysconfig files. Otherwise the user's choice needs to be preserved.

Together with bug #226982 this bind update causes lots of grief on
(semi-advanced) bind/ldap server setups.

Comment 1 Adam Tkac 2007-02-07 11:58:42 UTC
Could you tell me if this problem is caused by replacement of
/etc/sysconfig/named? And if old configfile is saved as .rpmnew? Thanks much, Adam

Comment 2 Paul Nasrat 2007-02-07 12:11:35 UTC
Also the full output of rpm -Uvv bind-*rpm would be helpful, is this 100%

Comment 3 Axel Thimm 2007-02-07 13:06:33 UTC
(In reply to comment #2)
> Also the full output of rpm -Uvv bind-*rpm would be helpful, is this 100%
> reproducible?

I found the bug, see below. It is 100% reproducable, and is not related to rpm

(In reply to comment #1)
> Could you tell me if this problem is caused by replacement of
> /etc/sysconfig/named? And if old configfile is saved as .rpmnew?

After the update there is only the "new" /etc/sysconfig/named with the wrong
ROOTDIR in place, no *.rpmsave, *.rpmnew etc.

I took a closer look and found the bug (or feature): If bach-chroot is installed
on each upgrade of bind (which of course updates the bind-chroot subpackage) the
ROOTDIR is always reset to /var/named/chroot by

/usr/sbin/bind-chroot-admin --enable

The script seems to want to preserve ROOTDIR if found in /etc/sysconfig/named,
but fails due to setting BIND_CHROOT_PREFIX to the default value early in the
script and later only looking at ROOTDIR if BIND_CHROOT_PREFIX is empty, e.g. never.

The easiest fix is probably simply unconditionally calling rootdir at the top of

bind-chroot-admin is going on with monopolizing ROOTDIR by removing it
completely when uninstalled. That should probably only happen iff ROOTDIR was
still the default.

Bottom line is: If one installs the current bind-chroot one is tied to
ROOTDIR=/var/named/chroot for as long as bind-chroot is installed. If this is
indended behaviour it should be loudly commented as such in
/etc/sysconfig/named. But I think the intended behaviour is to honour user
suppied ROOTDIR.

I suggest to source /etc/sysconfig/named at the very top and eliminate
BIND_CHROOT_PREFIX in favour of ROOTDIR everywhere.

Comment 4 Adam Tkac 2007-02-07 16:49:54 UTC
Perfect catch. I've improved bind-chroot-admin script in fedora devel. Could you
tell me if problem is now solved, please? (with bind*-9.3.4-5.fc7, package will
be avaliable during day)

Regards, Adam

Comment 5 Adam Tkac 2007-02-26 13:04:26 UTC
This could be fixed in bind-*9.3.4-3.fc6 . If this problem still exists, please

Regards, Adam

Note You need to log in before you can comment on or make changes to this bug.