Results 1 to 3 of 3
Hi,
I am configuring BIND-9.3 server on RHEL5. Can any body look into it and help me to understand why I am getting this message in /var/log/messages
Mar 25 14:10:09 ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 03-31-2009 #1Just Joined!
- Join Date
- Jan 2008
- Posts
- 49
(bind) named: couldn't open pid file '/var/run/named/named.pid' - any help?
Hi,
I am configuring BIND-9.3 server on RHEL5. Can any body look into it and help me to understand why I am getting this message in /var/log/messages
Mar 25 14:10:09 station1 named[27449]: couldn't open pid file '/var/run/named/named.pid': File exists
Mar 25 14:10:09 station1 named[27449]: exiting (due to early fatal error)
I am using RHEL5, port 53 and 953 are allowed by iptables. SELINUX is in enforcing mode.
[root@station1 run]# rpm -qa | grep bind
bind-utils-9.3.3-7.el5
bind-9.3.3-7.el5
bind-chroot-9.3.3-7.el5
system-config-bind-4.0.3-2.el5
bind-libs-9.3.3-7.el5
here are my config files
======== /etc/named.com =================
include "/etc/rndc.key";
options{
directory "/var/named/";
pid-file "/var/run/named/named.pid";
statistics-file "/var/log/named/named.stats";
dump-file "/var/log/named/named.dump";
zone-statistics yes;
allow-query { 192.168.182.0/24; };
};
key "rndc-key" {
algorithm hmac-md5;
secret "ykBHrr4mZJxlwAdcf9OuKw==";
};
controls {
inet 127.0.0.1 port 953
allow { 127.0.0.1; } keys { "rndc-key"; };
};
zone "." IN {
type hint;
file "named.ca";
};
zone "localdomain" IN {
type master;
file "localdomain.zone";
allow-update { none; };
};
zone "localhost" IN {
type master;
file "localhost.zone";
allow-update { none; };
};
zone "0.0.127.in-addr.arpa" IN {
type master;
file "named.local";
allow-update { none; };
};
zone "0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 .0.0.0.0.0.0.ip6.arpa" IN {
type master;
file "named.ip6.local";
allow-update { none; };
};
zone "255.in-addr.arpa" IN {
type master;
file "named.broadcast";
allow-update { none; };
};
zone "0.in-addr.arpa" IN {
type master;
file "named.zero";
allow-update { none; };
};
zone "example.com" IN {
type master;
file "example.com";
allow-update { none; };
};
zone "182.168.192.in-addr.arpa" IN {
type master;
file "reverse.example.com";
allow-update { none; };
};
====================
=============== /etc/rndc.conf =============
[root@station1 ~]# cat /etc/rndc.conf
# Start of rndc.conf
key "rndckey" {
algorithm hmac-md5;
secret "ykBHrr4mZJxlwAdcf9OuKw==";
};
options {
default-key "rndckey";
default-server 127.0.0.1;
default-port 953;
};
# End of rndc.conf
#############
[root@station1 run]# named -u named -c /etc/named.conf
[root@station1 run]# tail -f /var/log/messages
Mar 25 14:27:38 station1 named[27536]: starting BIND 9.3.3rc2 -u named -c /etc/named.conf
Mar 25 14:27:38 station1 named[27536]: found 1 CPU, using 1 worker thread
Mar 25 14:27:38 station1 named[27536]: loading configuration from '/etc/named.conf'
Mar 25 14:27:38 station1 named[27536]: listening on IPv4 interface lo, 127.0.0.1#53
Mar 25 14:27:38 station1 named[27536]: listening on IPv4 interface eth0, 192.168.182.130#53
Mar 25 14:27:38 station1 named[27536]: command channel listening on 127.0.0.1#953
Mar 25 14:27:38 station1 named[27536]: zone 0.in-addr.arpa/IN: loaded serial 42
Mar 25 14:27:38 station1 named[27536]: zone 0.0.127.in-addr.arpa/IN: loaded serial 1997022700
Mar 25 14:27:38 station1 named[27536]: zone 182.168.192.in-addr.arpa/IN: loaded serial 1997022700
Mar 25 14:27:38 station1 named[27536]: zone 255.in-addr.arpa/IN: loaded serial 42
Mar 25 14:27:38 station1 named[27536]: zone 0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0. 0.0.0.0.0.0.ip6.arpa/IN: loaded serial 1997022700
Mar 25 14:27:38 station1 named[27536]: zone example.com/IN: loaded serial 42
Mar 25 14:27:38 station1 named[27536]: zone localdomain/IN: loaded serial 42
Mar 25 14:27:38 station1 named[27536]: zone localhost/IN: loaded serial 42
Mar 25 14:27:38 station1 named[27536]: running
=====================
[root@station1 run]# /etc/init.d/named restart
Stopping named: [ OK ]
Starting named: [FAILED]
[root@station1 run]# tail -f /var/log/messages
Mar 25 14:29:31 station1 named[27536]: shutting down: flushing changes
Mar 25 14:29:31 station1 named[27536]: stopping command channel on 127.0.0.1#953
Mar 25 14:29:31 station1 named[27536]: no longer listening on 127.0.0.1#53
Mar 25 14:29:31 station1 named[27536]: no longer listening on 192.168.182.130#53
Mar 25 14:29:31 station1 named[27536]: exiting
Mar 25 14:29:34 station1 named[27574]: starting BIND 9.3.3rc2 -u named -t /var/named/chroot
Mar 25 14:29:34 station1 named[27574]: found 1 CPU, using 1 worker thread
Mar 25 14:29:34 station1 named[27574]: loading configuration from '/etc/named.conf'
Mar 25 14:29:34 station1 named[27574]: listening on IPv4 interface lo, 127.0.0.1#53
Mar 25 14:29:34 station1 named[27574]: listening on IPv4 interface eth0, 192.168.182.130#53
Mar 25 14:29:34 station1 named[27574]: command channel listening on 127.0.0.1#953
Mar 25 14:29:34 station1 named[27574]: couldn't open pid file '/var/run/named/named.pid': File exists
Mar 25 14:29:34 station1 named[27574]: exiting (due to early fatal error)
Note: SELINUX is in enfrocing mode and iptables are allowing port 53 and 953.
I dont know where is the problem? Can somebody help me to sortout this issue? hope above outputs will help to understand the issue?
Many thanks.
- 03-31-2009 #2Just Joined!
- Join Date
- Jan 2008
- Posts
- 49
I have created the named.pid file by myself but still got the same error. I confirmed the selinux setting and permissions but got the same error.
Any help?
- 03-31-2009 #3Just Joined!
- Join Date
- Jan 2008
- Posts
- 49
have resolved this issue with
#chmod 770 /var/named/chroot/var/run


Reply With Quote
