Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Doctor Q

Administrator
Original poster
Staff member
Sep 19, 2002
40,453
9,322
Los Angeles
I poked around in my log files out of curiosity. To my horror, I found that every 30 seconds, all day long, three messages are being written to the system log for each other computer on my local network.

Details: I'm on Mac OS X 10.3.8. I looked at the system log (file /var/log/system.log), which you can view most easily with the Console application in the Utilities folder.

The messages I see have the following form, where "doctorq" is the name of another host on my local network and 192.9.200.100 is its IP address.
Code:
Mar 30 14:29:17 localhost netinfod local[119]: notify's udp binder connection to doctorq[192.9.200.100]/local failed during opening (UDP) - socket_open failed

Mar 30 14:29:17 localhost netinfod local[119]: notify's tcp binder connection to doctorq[192.9.200.100]/local failed during opening (TCP) - socket_connect failed

Mar 30 14:29:17 localhost netinfod local[119]: update 0 to doctorq[192.9.200.100]/local failed during binder contacting - couldn't getregister
To see what I could learn from a fresh start, I cleared the log and rebooted. I got the following two messages, following by the every-30-second behavior again.
Code:
Mar 30 17:49:24 localhost netinfod local[121]: ni_crashed's udp binder connection to doctorq[192.9.200.100]/local failed during opening (UDP) - socket_open failed

Mar 30 17:49:24 localhost netinfod local[121]: ni_crashed's tcp binder connection to doctorq[192.9.200.100]/local failed during opening (TCP) - socket_connect failed
What started this is not a mystery. The computers on my local network each have manually assigned (static) IP addreses, and weeks ago I used the NetInfo Manager utility to add "doctorq" to my local NetInfo database, as follows:
/machines/doctorq:
ip_address = 192.9.200.100
name = doctorq
serves = ./local​
That lets me use hostname "doctorq" in URLs and commands in Terminal such as ping, telnet, ftp, etc. I did the same for other hosts on the network. Apparently, I've been getting these messages from netinfod ever since then.

I'm used to editing /etc/hosts on my Unix systems, and I was trying to do the equivalent by using NetInfo on my Mac, since the "BSD Flag File and NIS" choice in the "Directory Access" utility isn't on by default. I figured I was doing things the proper "Mac way" by using NetInfo to define the IP addresses for the various hosts. Apparently that wasn't a good idea. But why not?

I can switch to use of /etc/hosts and turn on "BSD Flag File and NIS" if that's the only way it would work, and remove these entries from NetInfo, but I'd like to understand what's going on.

What ARE the proper ways to let a Mac know the names/addresses of other computers with manually assigned IP addresses? And why am I getting these messages?
 
Wow, this one has sat around for awhile with no replies, which is a little surprising. I've been looking to do this as well (hence how I found this) and after reading through your dilemma, I did a little searching.

Everything I've found seems to indicate that this is the way to do it. The only thing I can think of that may be causing problems (and this is a bit of a guess) is if doctorq is a Windows machine and there is some firewall issue with accepting the netinfo requests (the socket issues).

I'll try setting something up when I get home to see what I get.
 
Unless one is a NetInfo geek, I'd say just put it in the /etc/hosts file. I've done that for a bunch of names, and I have no problem with it. Mac OS X by default will check the /etc/hosts files so unless you turned that off, you shouldn't have to do anything but add doctorq to the /etc/hosts file.
 
oaklandbum said:
Unless one is a NetInfo geek, I'd say just put it in the /etc/hosts file. I've done that for a bunch of names, and I have no problem with it. Mac OS X by default will check the /etc/hosts files so unless you turned that off, you shouldn't have to do anything but add doctorq to the /etc/hosts file.
I agree. Netinfo is Apple-specific, whereas /etc/hosts file in universal in Unix/Linux-based systems. OS X has tried to become more in line with standard Unix systems as OS X has matured. The one drawback to using /etc/hosts is in a larger network environment, but for several home systems it works fine.
 
Panther now consults the /etc/hosts file by default, so that may be the easiest place to put it. It's looking more and more that Apple may eventually dump NetInfo (since no one else uses it, and LDAP, etc. offer similar functionality and are more commonly used).

If you do want to do it the NetInfo Way, try leaving off the "serves = ./local" key in your new machine entries - I believe that tells the local NetInfo directory to consult the listed machine for directory info. That would explain the error messages every 30 seconds or so - it's trying to connect to to the other machine, but that machine isn't configured to serve NetInfo requests (normally you'd only set this up if you were doing network logons and such, and only on one machine). NOTE: The "localhost" entry contains the key to provide the NetInfo functionality to the local machine (it should be left alone, otherwise I imagine the whole OS will fail in spectacular ways). Without the "serves = " key, in theory NetInfo should be able to just use the name and IP address to supplement the usual DNS sources, which I believe is all that you want (/etc/hosts does the same thing).

I should note that on pre-Panther systems, you could also put your entries in /etc/hosts, and then run 'niload' with the proper options to load the file into NetInfo. (You could do this on Panther too, but it's not necessary anymore - just editing /etc/hosts is sufficient.)

These sites have some useful info, if you pick through them enough:

http://www.macwrite.com/criticalmass/%20mac-os-x-hosts-panther.php

http://www.macosxhints.com/article.php?story=20010328234510985
 
I appreciate all of your advice. I will try the two suggested solutions and report back.
 
I promised to report back with my results.

As EminenceGrise suggested, I removed the "serves = ./local" NetInfo values. I also removed them from the program I wrote to add these mistaken keys in the first place! Sure enough, my system.log messages stopped!

Thanks a million and one!
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.