Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Run a networked netinfo database on a laptop Network
I am running our master network netinfo database on my TiBook and a couple of clones on other portables. Why? Well, in our company we all use portables and we don't have a Mac OS X based server.

I have been fighting with this configuration for quite a while as it is pretty unstable once you change the network location (e.g. forever bouncing apps). The problem is that no matter what network location you choose, nibindd (the process which controls your netinfo processes) will always start all the netinfo databases no matter if they are appropriate for you current network location or not.

Read the rest of the article for a workaround to this problem...

When you change to a location where you don't want to run a networked netinfo database, just execute the following script as root:
#!/bin/sh

KILL=/bin/kill
NIBINDD_PID=`cat /var/run/nibindd.pid`
LOOKUPD_PID=`cat /var/run/lookupd.pid`

$KILL -TERM $NIBINDD_PID
cd /var/db/netinfo
netinfod -s local
$KILL -HUP $LOOKUPD_PID
This will restart netinfo in standalone mode (only the local netinfo db gets started, nibindd won't get started at all).

A proper solution would be to add information about the network location a netinfo database is supposed to run in, and when you select a new location, check for the tag and start the netinfo setup correctly (too much hassle for me right now ;-)
    •    
  • Currently 3.00 / 5
  You rated: 4 / 5 (3 votes cast)
 
[2,997 views]  

Run a networked netinfo database on a laptop | 2 comments | Create New Account
Click here to return to the 'Run a networked netinfo database on a laptop' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
specifics
Authored by: JayBee on Mar 28, '02 07:33:20AM

This is more a question about my own setup, and the relevance here.

I've noticed that when I disconnect my iBook from the network (usually to take to demo a website to a client), when I wake him from sleep, he is determined not to find the local apache server (from "localhost", "127.0.0.1" or my IP as set in Network -> TCP/IP) until I dive into the TCP/IP settings in Sys Prefs, and change something there (usually the netmask).

I usually have to close sys prefs WITHOUT clicking on "apply now" so that it pops up the "do you want to save your config" for the changes to stick, and then boom, everything cool.

Is this a symptom of NetInfo not updating when the LAN connection goes down?



[ Reply to This | # ]
apache / netinfo
Authored by: NikWest on Mar 28, '02 11:25:24AM

I don't think that this is a symptom of netinfo. At least if you run netinfo as it is configured out of the box.

There are a couple of other things, which could be the problem:

- if you have mod_unique enabled, apache does not like to run without an dns entry

- There is also some mysteriouses with IE connecting to the local machine (e.g. if you forward a port through ssh, IE won't connect to it)

- From a previous live I remember that IE on Windows did not like to connect to the loopback interface, if you don't have another interface up (could be a completely different problem)

Just check if it is an apache problem or an IE problem. For testing purposes you could try to use curl to connect to apache from the command line ( curl -O http://localhost/ ) and see what it does return.

Greetings

Dominik



[ Reply to This | # ]