summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYi Zhao <yi.zhao@windriver.com>2021-10-30 23:15:05 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-11-01 10:41:15 +0000
commita5c5977bef44b7b014af590515ea1f93d7d51f46 (patch)
tree7fefc12647f09b6b41fcf23dd2201570cd7b3eb4
parent4ec096a9ce8a49b631efc50e7d95ff653d4c4374 (diff)
downloadopenembedded-core-contrib-a5c5977bef44b7b014af590515ea1f93d7d51f46.tar.gz
bind: remove -r option from rndc-confgen in initscript
The -r option has been removed from rndc-confgen since bind 9.13[1]. Fix the bind startup error: $ /etc/init.d/bind start Starting domain name service: namedrndc-confgen: The -r option has been deprecated. chmod: cannot access '/etc/bind/rndc.key': No such file or directory [1]: https://gitlab.isc.org/isc-projects/bind9/-/commit/3a4f820d625c214cfb21f5e6d18ce9160d2a193b Signed-off-by: Yi Zhao <yi.zhao@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-connectivity/bind/bind-9.16.21/0001-avoid-start-failure-with-bind-user.patch2
-rw-r--r--meta/recipes-connectivity/bind/bind-9.16.21/conf.patch2
2 files changed, 2 insertions, 2 deletions
diff --git a/meta/recipes-connectivity/bind/bind-9.16.21/0001-avoid-start-failure-with-bind-user.patch b/meta/recipes-connectivity/bind/bind-9.16.21/0001-avoid-start-failure-with-bind-user.patch
index 8db96ec049..ec1bc7b567 100644
--- a/meta/recipes-connectivity/bind/bind-9.16.21/0001-avoid-start-failure-with-bind-user.patch
+++ b/meta/recipes-connectivity/bind/bind-9.16.21/0001-avoid-start-failure-with-bind-user.patch
@@ -17,7 +17,7 @@ index b2eec60..6e03936 100644
@@ -57,6 +57,7 @@ case "$1" in
modprobe capability >/dev/null 2>&1 || true
if [ ! -f /etc/bind/rndc.key ]; then
- /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
+ /usr/sbin/rndc-confgen -a -b 512
+ chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
chmod 0640 /etc/bind/rndc.key
fi
diff --git a/meta/recipes-connectivity/bind/bind-9.16.21/conf.patch b/meta/recipes-connectivity/bind/bind-9.16.21/conf.patch
index aad345f9fc..aa3642acec 100644
--- a/meta/recipes-connectivity/bind/bind-9.16.21/conf.patch
+++ b/meta/recipes-connectivity/bind/bind-9.16.21/conf.patch
@@ -276,7 +276,7 @@ diff -urN bind-9.3.1.orig/init.d bind-9.3.1/init.d
+
+ modprobe capability >/dev/null 2>&1 || true
+ if [ ! -f /etc/bind/rndc.key ]; then
-+ /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
++ /usr/sbin/rndc-confgen -a -b 512
+ chmod 0640 /etc/bind/rndc.key
+ fi
+ if [ -f /var/run/named/named.pid ]; then