From: Tom Anderson on
On Tue, 15 Jun 2010, Tony Houghton wrote:

> In <hv8e28$ggc$1(a)news.eternal-september.org>,
> Geoff Clements <bitbucket(a)electron.me.uk> wrote:
>
>> Tony Houghton wrote:
>>
>>> The main way my PCs communicate with each other is ssh, plus a bit of
>>> NFS. AIUI avahi is service-specific and I think I'd have to do some
>>> twiddling to get those services available over avahi.
>>
>> If you're not bothered about announcing the services then no twiddling is
>> necessary, avahi will just resolve the hostnames.
>
> $ nslookup tiber.local
> Server: 192.168.1.254
> Address: 192.168.1.254#53
>
> ** server can't find tiber.local: NXDOMAIN

Try:

ping tiber.local

nslookup doesn't find it because it's not going via your resolver, it's
doing DNS directly with the servers named in resolv.conf or whatever. Most
programs use your resolver, so they will find it.

I don't know if you can add the local mDNS responders to resolv.conf. I
doubt it.

Just in case your machine isn't getting the obvious name for some reason,
try:

arp -a

and see who's in the neighbourhood.

> I do have avahi running and tiber is this PC's hostname. Do you have to
> add something to /etc/nsswitch.conf?

I've not had to do that on Ubuntu. Don't know about other systems.

tom

--
Any Christmas message which ends with "... everything's pointless
...." probably doesn't need sharing -- cleanskies
From: Tony Houghton on
In <alpine.DEB.1.10.1006161701010.897(a)urchin.earth.li>,
Tom Anderson <twic(a)urchin.earth.li> wrote:

> On Tue, 15 Jun 2010, Tony Houghton wrote:
>
>> In <hv8e28$ggc$1(a)news.eternal-september.org>,
>> Geoff Clements <bitbucket(a)electron.me.uk> wrote:
>>
>>> If you're not bothered about announcing the services then no twiddling is
>>> necessary, avahi will just resolve the hostnames.
>>
>> $ nslookup tiber.local
>> Server: 192.168.1.254
>> Address: 192.168.1.254#53
>>
>> ** server can't find tiber.local: NXDOMAIN
>
> Try:
>
> ping tiber.local
>
> nslookup doesn't find it because it's not going via your resolver, it's
> doing DNS directly with the servers named in resolv.conf or whatever. Most
> programs use your resolver, so they will find it.

You're right. ping can find the name where nslookup doesn't.

--
TH * http://www.realh.co.uk
From: Geoff Clements on
Tony Houghton wrote:

> In <alpine.DEB.1.10.1006161701010.897(a)urchin.earth.li>,
> Tom Anderson <twic(a)urchin.earth.li> wrote:
>
>> On Tue, 15 Jun 2010, Tony Houghton wrote:
>>
>>> In <hv8e28$ggc$1(a)news.eternal-september.org>,
>>> Geoff Clements <bitbucket(a)electron.me.uk> wrote:
>>>
>>>> If you're not bothered about announcing the services then no twiddling
>>>> is necessary, avahi will just resolve the hostnames.
>>>
>>> $ nslookup tiber.local
>>> Server: 192.168.1.254
>>> Address: 192.168.1.254#53
>>>
>>> ** server can't find tiber.local: NXDOMAIN
>>
>> Try:
>>
>> ping tiber.local
>>
>> nslookup doesn't find it because it's not going via your resolver, it's
>> doing DNS directly with the servers named in resolv.conf or whatever.
>> Most programs use your resolver, so they will find it.
>
> You're right. ping can find the name where nslookup doesn't.
>

To test name resolution try:

$ getent hosts tiber.local

--
Geoff
From: alexd on
On 16/06/10 18:33, Tony Houghton wrote:
> In<alpine.DEB.1.10.1006161701010.897(a)urchin.earth.li>,
> Tom Anderson<twic(a)urchin.earth.li> wrote:

>> nslookup doesn't find it because it's not going via your resolver, it's
>> doing DNS directly with the servers named in resolv.conf or whatever. Most
>> programs use your resolver, so they will find it.
>
> You're right. ping can find the name where nslookup doesn't.

You may like to look at adding mdns to /etc/nsswitch.conf as well [won't
make nslookup work]. mdns-scan is also interesting.

--
<http://ale.cx/> (AIM:troffasky) (UnSoEsNpEaTm(a)ale.cx)
21:16:12 up 49 days, 23:31, 0 users, load average: 6.24, 2.15, 0.86
It is better to have been wasted and then sober
than to never have been wasted at all
From: Geoff Clements on
alexd wrote:

> On 16/06/10 18:33, Tony Houghton wrote:
>> In<alpine.DEB.1.10.1006161701010.897(a)urchin.earth.li>,
>> Tom Anderson<twic(a)urchin.earth.li> wrote:
>
>>> nslookup doesn't find it because it's not going via your resolver, it's
>>> doing DNS directly with the servers named in resolv.conf or whatever.
>>> Most programs use your resolver, so they will find it.
>>
>> You're right. ping can find the name where nslookup doesn't.
>
> You may like to look at adding mdns to /etc/nsswitch.conf as well [won't
> make nslookup work]. mdns-scan is also interesting.
>

If the name resolution worked for ping it's probably already there, but if
not the following line is probably the most useful in nsswitch.conf:

hosts: files mdns4_minimal [NOTFOUND=return] dns mdns4

--
Geoff