On 12/21/06, Kevin O'Gorman <[EMAIL PROTECTED]> wrote:
On 12/21/06, Jeff Rollin <[EMAIL PROTECTED]> wrote:
> On 21/12/06, Kevin O'Gorman <[EMAIL PROTECTED]> wrote:
> > I'm beginning to think my system configuration is a mess.  It started with
> > worrying about Postfix, but has quickly escalated.
> >
> > I was trying to figure out what Postfix knows and where it knows it when
> > I found that I seem to have no domain name.  That is, the shell command
> > domainname(1) returns "(none)".  This seems odd, because I've got
> > it set up as nearly as I can see according to gentoo docs
> >    
http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=1&chap=8#doc_chap2
> > since my /etc/conf.d/net contains (among other things)
> >    dns_domain="kosmanor.com"
> > BTW: it also says to set dns_domain_lo, but I have no name for my
> > internal network, and
> > haven't seen a reason to create one.
> >
> > Nevertheless, even the system calls getdomainname(2) and uname(2) return the
> > string "(none)".
> >
> > What am I missing?
> >
>
> That's because the command domainname and the systemcalls
> getdomainname(2) are return the NIS domainname, not the IP domainname.
> uname(2) returns the domainname of the machine the kernel was compiled
> on, at the time when it was compiled. To find the tcp/ip domain name
> of a system, use hostname(1).
>
> Yes, it is daft - but, that's what happens when an OS acquires a
> history, I suppose

Thanks, but that won't get me an IP domainname, because all that is there
is the name of the node.  Should I change that in /etc/conf.d/net???


Oops.  I should have known I could answer my own question with a little more
digging.  I now see that there's
   hostname
   hostname --fqdn
   dnsdomainname
and they all work by looking in /etc/host.conf, and if (as is true
here) that says
to use the hosts file first, it looks for it in /etc/hosts, which has the fqdn.
I seem to dimly recall that it actually looks for the first
non-comment, but that
cannot be quite right, because localhost comes first in my copy.
Maybe it's the first
routable IP number?

I think this sub-problem is solved.  I've commented my config files a
bit more, so I
won't make the same mistake again.

++ kevin

--
Kevin O'Gorman, PhD
--
gentoo-user@gentoo.org mailing list

Reply via email to