|Ørjan Horpestad||Sep 25, 2009 2:10 am|
|Benjamin Reed||Sep 25, 2009 6:56 am|
|Ørjan Horpestad||Sep 25, 2009 8:43 am|
|Ted Dunning||Sep 25, 2009 8:51 am|
|Eric Bowman||Sep 25, 2009 9:05 am|
|Benjamin Reed||Sep 25, 2009 9:30 am|
|Leonard Cuff||Sep 25, 2009 3:04 pm|
|Eric Bowman||Sep 25, 2009 3:46 pm|
|Benjamin Reed||Sep 25, 2009 4:16 pm|
|Patrick Hunt||Sep 26, 2009 12:48 am|
|Leonard Cuff||Sep 28, 2009 9:56 am|
|Ørjan Horpestad||Sep 29, 2009 1:19 am|
|Jason Venner||Sep 29, 2009 7:34 am|
|Ted Dunning||Sep 29, 2009 8:44 am|
|Patrick Hunt||Sep 29, 2009 10:01 am|
|Flavio Junqueira||Sep 30, 2009 2:14 am|
|Subject:||Re: The idea behind 'myid'|
|From:||Benjamin Reed (bre...@yahoo-inc.com)|
|Date:||Sep 25, 2009 9:30:17 am|
you and ted are correct. the id gives zookeeper a stable identifier to use even if the ip address changes. if the ip address doesn't change, we could use that, but we didn't want to make that a built in assumption. if you really do have a rock solid ip address, you could make a wrapper startup script that starts up and creates the myid file based on the ip address. i gotta say though, i've found that such assumptions are often found to be invalid.
Eric Bowman wrote:
Another way of doing it, though, would be to tell each instance which IP to use at startup.
That way the config can be identical for all users, and there can be whatever logic is required to figure out the right IP address, in the place where logic executing anyhow.
I do agree that maintaining the myid file is ackward compared to other approaches that are working elsewhere. It's not really clear what purpose the my id serves except to bind an ip address to a running instance.
Ted Dunning wrote:
A server doesn't have a unique IP address.
Each interface can have 1 or more IP addresses and there can be many interfaces. Furthermore, an IP address can move from one machine to another.
2009/9/25 Ørjan Horpestad <orj...@gmail.com>
Well, im just wondering why the server's own unique IP-address isn't good enough as a valid identifyer; it strikes me to be a bit exhausting to manually set the id for each server in the cluster. Or maybe there is some details im not getting here :-)
On Fri, Sep 25, 2009 at 3:56 PM, Benjamin Reed <bre...@yahoo-inc.com> wrote:
can you clarify what you are asking for? are you just looking for motivation? or are you trying to find out how to use it?
the myid file just has the unique identifier (number) of the server in
cluster. that number is matched against the id in the configuration file. there isn't much to say about it: http://hadoop.apache.org/zookeeper/docs/r3.2.1/zookeeperStarted.html
Ørjan Horpestad wrote:
Hi! Can someone pin-point me to a site (or please explain ) where I can read about the use of the myid-file for configuring the id of the ZooKeeper servers? I'm sure there is a good reason for using this approach, but it is the first time I have come over this type of non-automatic way for administrating replicas.