Discussion:
DNS and Apache not running
(too old to reply)
Andy
2011-05-25 03:17:50 UTC
Permalink
Hi I have the following services in maintenance:
svcs -xv
svc:/network/dns/server:default (BIND DNS server)
State: maintenance since Wed May 25 06:18:35 2011
Reason: Start method failed repeatedly, last exited with status 1.
See: http://sun.com/msg/SMF-8000-KS
See: man -M /usr/man -s 1M named
See: /var/svc/log/network-dns-server:default.log
Impact: This service is not running.

svc:/network/http:apache22 (Apache 2.2 HTTP server)
State: maintenance since Wed May 25 06:19:57 2011
Reason: Start method failed repeatedly, last died on Killed (9).
See: http://sun.com/msg/SMF-8000-KS
See: man -M /usr/apache2/2.2/man -s 8 httpd
See: http://httpd.apache.org
See: /var/svc/log/network-http:apache22.log
Impact: This service is not running.


dns-server: Executing: /usr/sbin/named
[ May 25 06:18:33 Method "start" exited with status 1. ]
[ May 25 06:18:33 Executing start method ("/lib/svc/method/dns-server
start defa
ult"). ]
Thanks
Tiberiu
h***@bofh.ca
2011-05-25 18:13:10 UTC
Permalink
Post by Andy
svc:/network/dns/server:default (BIND DNS server)
State: maintenance since Wed May 25 06:18:35 2011
Broken DNS can break Apache, so we'll start with that.

What happens if you run "/lib/svc/method/dns-server start default" by hand
as root? What happens if you try running "/usr/sbin/named -g"?
--
Brandon Hume - hume -> BOFH.Ca, http://WWW.BOFH.Ca/
Andy
2011-05-29 06:02:41 UTC
Permalink
Post by h***@bofh.ca
Post by Andy
svc:/network/dns/server:default (BIND DNS server)
State: maintenance since Wed May 25 06:18:35 2011
Broken DNS can break Apache, so we'll start with that.
What happens if you run "/lib/svc/method/dns-server start default" by hand
as root?  What happens if you try running "/usr/sbin/named -g"?
--
Brandon Hume    - hume -> BOFH.Ca,http://WWW.BOFH.Ca/
opensolaris:~# /usr/sbin/named -g
29-May-2011 09:17:56.535 starting BIND 9.3.4-P1 -g
29-May-2011 09:17:56.843 found 1 CPU, using 1 worker thread
29-May-2011 09:17:56.869 loading configuration from '/etc/named.conf'
29-May-2011 09:17:56.870 none:0: open: /etc/named.conf: file not found
29-May-2011 09:17:56.872 loading configuration: file not found
29-May-2011 09:17:56.873 exiting (due to fatal error)
h***@bofh.ca
2011-05-29 11:49:39 UTC
Permalink
Post by Andy
29-May-2011 09:17:56.869 loading configuration from '/etc/named.conf'
29-May-2011 09:17:56.870 none:0: open: /etc/named.conf: file not found
29-May-2011 09:17:56.872 loading configuration: file not found
29-May-2011 09:17:56.873 exiting (due to fatal error)
Well, there's your answer. named can't run if you don't configure it.

Is there a particular reason why you need to run a nameserver? Does your
ISP not provide one, or are you on an isolated network?
--
Brandon Hume - hume -> BOFH.Ca, http://WWW.BOFH.Ca/
Chris Ridd
2011-05-29 16:11:11 UTC
Permalink
Post by h***@bofh.ca
Post by Andy
29-May-2011 09:17:56.869 loading configuration from '/etc/named.conf'
29-May-2011 09:17:56.870 none:0: open: /etc/named.conf: file not found
29-May-2011 09:17:56.872 loading configuration: file not found
29-May-2011 09:17:56.873 exiting (due to fatal error)
Well, there's your answer. named can't run if you don't configure it.
Is there a particular reason why you need to run a nameserver? Does your
ISP not provide one, or are you on an isolated network?
Shouldn't the service be configured with a dependency on the config
file? At the very least it would make this particular misconfiguration
(or lack of configuration!) a little more obvious.
--
Chris
h***@bofh.ca
2011-05-29 16:36:48 UTC
Permalink
Post by Chris Ridd
Shouldn't the service be configured with a dependency on the config
file? At the very least it would make this particular misconfiguration
(or lack of configuration!) a little more obvious.
I'm not sure how configuring a dependency like that would interact if you
also configured chroot_dir (which is present in the property group). Most
likely you'd end up with the dependency being satisfied but named still
claiming '/etc/named.conf' didn't exist.

In other news, 'configuration_file' is *also* a configurable value in the
property group. Myself, if I'd written this manifest, I'd populate that
with '/etc/named.conf' as a default to make it obvious. But I'd bet this
particular manifest is one that didn't get a lot of thought, and hasn't
needed a lot of thought up until this point. This is the first time we've
seen anyone trip over it, after all.
--
Brandon Hume - hume -> BOFH.Ca, http://WWW.BOFH.Ca/
Andy
2011-05-30 13:36:52 UTC
Permalink
Post by h***@bofh.ca
Post by Chris Ridd
Shouldn't the service be configured with a dependency on the config
file? At the very least it would make this particular misconfiguration
(or lack of configuration!) a little more obvious.
I'm not sure how configuring a dependency like that would interact if you
also configured chroot_dir (which is present in the property group). Most
likely you'd end up with the dependency being satisfied but named still
claiming '/etc/named.conf' didn't exist.
In other news, 'configuration_file' is *also* a configurable value in the
property group. Myself, if I'd written this manifest, I'd populate that
with '/etc/named.conf' as a default to make it obvious. But I'd bet this
particular manifest is one that didn't get a lot of thought, and hasn't
needed a lot of thought up until this point. This is the first time we've
seen anyone trip over it, after all.
--
Brandon Hume - hume -> BOFH.Ca,http://WWW.BOFH.Ca/
I've done just touch /etc/named.conf because I don't need it ( someone
mistakenly enabled it for me).
Now when I run svcs -a only apache22 is in maintenance. I've checked
the /etc/httpd.conf and it is ok.
John D Groenveld
2011-05-30 13:47:52 UTC
Permalink
Post by Andy
I've done just touch /etc/named.conf because I don't need it ( someone
mistakenly enabled it for me).
# svcadm disable svc:/network/dns/server:default
Post by Andy
Now when I run svcs -a only apache22 is in maintenance. I've checked
the /etc/httpd.conf and it is ok.
How did you check httpd.conf?

Brandon suggested you look at the log file, what did it reveal?

John
***@acm.org
h***@bofh.ca
2011-05-30 21:24:52 UTC
Permalink
Post by Andy
I've done just touch /etc/named.conf because I don't need it ( someone
mistakenly enabled it for me).
Then why enable it at all? You've activated the name *server*, not a named
client.

Turn it off if you don't need it (and if you don't know if you need it, then
you don't need it) using svcadm disable.

If you turned the DNS server on blindly, is your client configuration
working? What does 'getent hosts www.google.com' output?
Post by Andy
Now when I run svcs -a only apache22 is in maintenance. I've checked
the /etc/httpd.conf and it is ok.
Except /etc/httpd.conf is not the right config file. You want
/etc/apache2/httpd.conf.

What does the svcs log output for that service?
--
Brandon Hume - hume -> BOFH.Ca, http://WWW.BOFH.Ca/
Andy
2011-06-02 15:11:34 UTC
Permalink
Post by h***@bofh.ca
Post by Andy
svc:/network/dns/server:default (BIND DNS server)
State: maintenance since Wed May 25 06:18:35 2011
Broken DNS can break Apache, so we'll start with that.
What happens if you run "/lib/svc/method/dns-server start default" by hand
as root? What happens if you try running "/usr/sbin/named -g"?
--
Brandon Hume - hume -> BOFH.Ca,http://WWW.BOFH.Ca/
Hi
tail -f /var/svc/log/network-http:apache22.log
[ Jun 2 14:38:18 Executing start method ("/lib/svc/method/http-
apache22 start"). ]
Apache version is 2.2
[ Jun 2 14:38:34 Method "start" exited with status 1. ]
[ Jun 2 14:38:34 Executing start method ("/lib/svc/method/http-
apache22 start"). ]
Apache version is 2.2
[ Jun 2 14:38:37 Method "start" exited with status 1. ]
[ Jun 2 14:38:37 Executing start method ("/lib/svc/method/http-
apache22 start"). ]
Apache version is 2.2
[ Jun 2 14:39:37 Method or service exit timed out. Killing contract
84. ]
[ Jun 2 14:39:37 Method "start" failed due to signal KILL. ]
h***@bofh.ca
2011-06-02 15:35:06 UTC
Permalink
Post by Andy
[ Jun 2 14:38:37 Executing start method ("/lib/svc/method/http-
apache22 start"). ]
Apache version is 2.2
[ Jun 2 14:39:37 Method or service exit timed out. Killing contract
84. ]
Assuming you haven't changed anything, what do the logs in /var/apache2/logs
say?
--
Brandon Hume - hume -> BOFH.Ca, http://WWW.BOFH.Ca/
Andy
2011-06-05 02:14:57 UTC
Permalink
I give up opensolaris 2008.05 and I installed Solaris Express snv151a
from Nov 2010 on the same laptop - a Sony Vaio with Intel Centrino at
1.7Ghz - but I have no graphics mode: It seems that the kernel modules
vesa and intel are missing.
Andy
2011-06-05 02:48:30 UTC
Permalink
Post by h***@bofh.ca
Post by Andy
[ Jun 2 14:38:37 Executing start method ("/lib/svc/method/http-
apache22 start"). ]
Apache version is 2.2
[ Jun 2 14:39:37 Method or service exit timed out. Killing contract
84. ]
Assuming you haven't changed anything, what do the logs in /var/apache2/logs
say?
--
Brandon Hume - hume -> BOFH.Ca,http://WWW.BOFH.Ca/
my hostname is opensolaris
when I run # nslookup opensolaris
Server: 192.168.1.1
Address: 192.168.1.1#53

** server can't find opensolaris: NXDOMAIN
h***@bofh.ca
2011-06-05 14:21:54 UTC
Permalink
Post by Andy
my hostname is opensolaris
when I run # nslookup opensolaris
Server: 192.168.1.1
Address: 192.168.1.1#53
Who is 192.168.1.1? Is it your local DNS server? Or is it the local
machine?

Basically, I'm asking why that machine would know who you are.

What does 'getent hosts opensolaris' produce? What does /etc/named.conf
contain?
--
Brandon Hume - hume -> BOFH.Ca, http://WWW.BOFH.Ca/
Andy
2011-06-05 16:48:04 UTC
Permalink
Post by Andy
my hostname is opensolaris
when I run # nslookup opensolaris
Server:         192.168.1.1
Address:        192.168.1.1#53
Who is 192.168.1.1?  Is it your local DNS server?  Or is it the local
machine?
Basically, I'm asking why that machine would know who you are.
What does 'getent hosts opensolaris' produce?  What does /etc/named.conf
contain?
--
Brandon Hume    - hume -> BOFH.Ca,http://WWW.BOFH.Ca/
Thanks a lot. I've finally figured out what was the problem.
I think when I enabled dns server service it added a domain name to my
hostname (opensolaris.something) in /etc/hosts.
So I removed the extension to opensolaris and after that I could
restart apache22.
h***@bofh.ca
2011-06-05 23:25:16 UTC
Permalink
Post by Andy
I think when I enabled dns server service it added a domain name to my
hostname (opensolaris.something) in /etc/hosts.
You can have both. Just list them on the same line separated by whitespace.

192.168.1.# opensolaris.something

changes to...

192.168.1.# opensolaris.something opensolaris loghost etc etc
--
Brandon Hume - hume -> BOFH.Ca, http://WWW.BOFH.Ca/
Edmund H. Ramm
2011-05-25 16:53:15 UTC
Permalink
Post by Andy
svcs -xv
svc:/network/dns/server:default (BIND DNS server)
State: maintenance since Wed May 25 06:18:35 2011
Reason: Start method failed repeatedly, last exited with status 1.
See: http://sun.com/msg/SMF-8000-KS
See: man -M /usr/man -s 1M named
See: /var/svc/log/network-dns-server:default.log
What's in the log?
Post by Andy
Impact: This service is not running.
svc:/network/http:apache22 (Apache 2.2 HTTP server)
State: maintenance since Wed May 25 06:19:57 2011
Reason: Start method failed repeatedly, last died on Killed (9).
See: http://sun.com/msg/SMF-8000-KS
See: man -M /usr/apache2/2.2/man -s 8 httpd
See: http://httpd.apache.org
See: /var/svc/log/network-http:apache22.log
Again, the answer is probably to be found in above mentioned log.
Post by Andy
Impact: This service is not running.
[...]
Eddi ._._.
--
e-mail: dk3uz AT arrl DOT net | AMPRNET: ***@db0hht.ampr.org
Linux/m68k, the best U**x ever to hit an Atari!
Continue reading on narkive:
Loading...