Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 2 May 2020 11:31:44 -0400
From:      Michael Butler <imb@protected-networks.net>
To:        Christoph Moench-Tegeder <cmt@burggraben.net>
Cc:        The Doctor <doctor@doctor.nl2k.ab.ca>, freebsd-ports@freebsd.org
Subject:   Re: Bind 9.16 port error still lingers
Message-ID:  <e2e88e8d-7470-ebb1-05e9-55a1cb51a56c@protected-networks.net>
In-Reply-To: <20200502151636.GA22397@doctor.nl2k.ab.ca>
References:  <20200502140501.GA16385@doctor.nl2k.ab.ca> <20200502143210.GA4453@elch.exwg.net> <20200502151636.GA22397@doctor.nl2k.ab.ca>

next in thread | previous in thread | raw e-mail | index | archive | help
On 5/2/20 11:16 AM, The Doctor via freebsd-ports wrote:
> On Sat, May 02, 2020 at 04:32:10PM +0200, Christoph Moench-Tegeder wrote:
>> ## The Doctor via freebsd-ports (freebsd-ports@freebsd.org):
>>
>>> Subject: Bind 9.16 port error still lingers
>>
>> "Still"?
>>
>>> May  1 21:29:02 gallifrey named[90441]: Required root permissions to open '/var/run/named.pid'.
>>> May  1 21:29:02 gallifrey named[90441]: Please check file and directory permissions or reconfigure the filename.
>>
>> Did you?
>> BTW the default location for named's pidfile on FreeBSD is
>> /var/run/named/pid.
>>
>>> May  1 21:29:02 gallifrey named[90441]: parser.c:950: REQUIRE(obj != ((void *)0) && obj->type->rep == &cfg_rep_uint32) failed, back trace
>>
>> Some (configuration) value should be an integer, but isn't.
>>
> 
> cat /var/run/named.pid
> 15640
> 
> running bind911
> 
> and ls -Fail /var/run/named.pid
> 
> -rw-r--r-- 1 root wheel 6 May 1 21:38 /var/run/named.pid

By default, you need 'root' permissions to write to the /var/run
directory. As the port is configured on FreeBSD, BIND drops privileges
as soon as practical to that of the 'bind' user and group. For example:

imb@sarah:/home/imb> ls -l /var/run/named/
total 8
-rw-r--r--  1 bind  bind    4 Apr 30 21:05 pid
-rw-------  1 bind  bind  102 Apr 30 21:05 session.key

It seems you have incorrectly changed the configuration by not taking
these permissions into account. Check your named.conf for the incorrect
definition of pid-file - it should be "/var/run/named/pid",


	imb



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?e2e88e8d-7470-ebb1-05e9-55a1cb51a56c>