Home > Archive > Slony1 PostgreSQL Replication > September 2005 > Is non-sequential node numbering okay?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Is non-sequential node numbering okay?
Jim Archer

2005-09-06, 8:24 pm

Hi All...

Is there any requirement about how nodes are numbered? I see that there
is a requirement that there be a node 1 (although the FAQ says there does
not really) but I'm wondering if I can number them like 1, 101, 201, 202
and so on. I am thinking that I can create a scheme where 1xx nodes are
in one city, 2xx in another, 3xx in yet another and so on.

Do I really need a node 1? If not, I would start at 101.

Thanks...
Tim Goodaire

2005-09-07, 9:23 am

____________________
____________________
_______
Slony1-general mailing list
Slony1-general- AuKwsB3Fm+ugFIWk8tvy
RWD2FQJk+8+b@public.gmane.org
http://gborg.postgresql.org/mailman.../slony1-general

Mischa Sandberg

2005-09-07, 8:25 pm

Quoting tgoodair-swQf4SbcV9C7WVzo/KQ3Mw@public.gmane.org (Tim Goodaire)

> On Tue, Sep 06, 2005 at 05:32:43PM -0400, Jim Archer wrote:
....[color=darkred]
>=20
> You can number them any way that you want and you don't need a node
> 1 in your cluster. If you decide to not have a node 1, you should
> note that=20
> the event node parameter for many slonik commands defaults to node 1,
> so=20
> you'll have to specify event node if you don't have a node 1.


Actually, it works to your advantage to always be explicit.
That way, when you lose node 1 and node X becomes your master, your
scripts don't start breaking :-)

I tend to use id's that identify the object.
1000+ for node ids; 100,200,... for sets; 101,102,... for tables in set
(100), etc. Crude, but keeps me from tripping over myself.
Christopher Browne

2005-09-07, 8:25 pm

Tim Goodaire wrote:

>On Tue, Sep 06, 2005 at 05:32:43PM -0400, Jim Archer wrote:
>
>
>
>You can number them any way that you want and you don't need a node
>1 in your cluster. If you decide to not have a node 1, you should note that
>the event node parameter for many slonik commands defaults to node 1, so
>you'll have to specify event node if you don't have a node 1.
>
>

It actually seems somewhat preferable to NOT have a node 1 in the
cluster, as that reduces the degree of "magic" that takes place.

That is, events do not "magically" appear on node 1...

I think the "100 series for City A, 200 series for City B" approach is
an excellent one.

Internally at Afilias, we have commonly have set numbers based on the
numbers assigned by our ticketing system. That way, if you wonder what
replication set 32744 is about, you can search for ticket #32744 and
find all the discussion surrounding why that replication set was created.

Americans might find it convenient to use zip codes as a "geographic
location surrogate" :-)
Jim Archer

2005-09-07, 8:25 pm

Thanks very much for the help everyone! I'm going to get rid of node 1
and adopt a new node/set numbering scheme.



Christopher Browne said:

> Tim Goodaire wrote:
>
re[color=darkred]
02[color=darkred]
re[color=darkred]
o[color=darkred]
> It actually seems somewhat preferable to NOT have a node 1 in the
> cluster, as that reduces the degree of "magic" that takes place.
>
> That is, events do not "magically" appear on node 1...
>
> I think the "100 series for City A, 200 series for City B" approach is
> an excellent one.
>
> Internally at Afilias, we have commonly have set numbers based on the
> numbers assigned by our ticketing system. That way, if you wonder what
> replication set 32744 is about, you can search for ticket #32744 and
> find all the discussion surrounding why that replication set was create=

d.
>
> Americans might find it convenient to use zip codes as a "geographic
> location surrogate" :-)
> ____________________
____________________
_______
> Slony1-general mailing list
> Slony1-general- AuKwsB3Fm+ugFIWk8tvy
RWD2FQJk+8+b@public.gmane.org
> http://gborg.postgresql.org/mailman.../slony1-general
>

Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com