On Fri, Aug 31, 2012 at 5:22 PM, Glenn English <g...@slsware.com> wrote: > > Debian squeeze gets the host's domain name from the first > non-comment or non-empty line of /etc/hosts?? If it likes > that line?? > > Not from /etc/hostname and not from the "kernel.domainname = " > line in /etc/sysctl.conf? ("kernel.domainname = example.com" is > that line, commented out, in my recently installed squeeze.) > And not from /etc/resolv.conf? Or does it rely on DNS? > > I needed to change a domain name this morning on a computer > I'm working on, and I was told to do those different things > from several different websites. Setting it in /etc/hosts seems > to have worked. Why is this trivial task so obscure? > > I must be missing something big time. hostname was coming up with > the right answer, but hostname -f kept saying "Name or service not > known". Can anyone tell me what I've got wrong? And the Debian way > of setting the domain name? (It's working now, AFAIK, but I'd like > to set it correctly...)
With "libnss-myhostname" installed, I have "127.0.0.1 localhost" in "/etc/hosts" and "host.domain" in "/etc/hostname". Without "libnss-myhostname" installed, I have "127.0.0.1 localhost" and either "127.0.1.1 host.domain host" or "a.b.c.d host.domain host" in "/etc/hosts" and either "host" or "host.domain" in "/etc/hostname". -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/CAOdo=SzvESAf1L=kj0anjurqpozi1s+sv2vyhd9o6qbph7q...@mail.gmail.com