Christopher Browne cbbrowne at ca.afilias.info
Tue Dec 4 13:05:20 PST 2007
<postgres at dac.e4ward.com> writes:
> I've correctly dropped my node2 (still have node1 which is the set1
> origin and node3 which is a slave) using this command:
>
> slonik_drop_node node2 | slonik
>
> The documentation says that this would try to kill the running slon
> for that node but it didn't. Could it be because postgres is running
> with user postgres and the slons are running as root?
>
> It correctly dropped the node because it's not listed anymore on the
> origins sl_node, sl_subscribe ad sl_path tables. But it's still is
> listed when I ask for replication status on sl_status:
>
> # SELECT * from _replication.sl_status ;
>  st_origin | st_received | st_last_event |      st_last_event_ts
> | st_last_received |    st_last_received_ts     |
> st_last_received_event_ts  | st_lag_num_events |   st_lag_time
> -----------+-------------+---------------+----------------------------+------------------+----------------------------+----------------------------+-------------------+-----------------
>          1 |           2 |         34498 | 2007-12-04 13:36:29.145529
> |            34422 | 2007-12-04 13:23:46.859689 | 2007-12-04
> 13:23:46.835432 |                76 | 00:12:48.167806
>          1 |           3 |         34498 | 2007-12-04 13:36:29.145529
> |            34497 | 2007-12-04 13:36:23.466897 | 2007-12-04
> 13:36:19.108237 |                 1 | 00:00:15.895001
> (2 rows)
>
> Is this going to be a problem if I create a new node and assign it
> number 2? Will slony think it's the old node2 coming back again and
> just try to sync those 76 unsynced events?

The dead node will go away from that view in ~10 minutes, the next
time the cleanup thread runs against the node where you ran that
query.

You will be able to create node #2 again, but I'd want to wait about
1/2h in order for traces of the "old instantiation" to get cleared out
on all the nodes.  If you recreated node 2 right away, I could see
there being a fair bit of confusion.
-- 
let name="cbbrowne" and tld="cbbrowne.com" in name ^ "@" ^ tld;;
http://cbbrowne.com/info/multiplexor.html
"Windows/NT - From the people who brought you EDLIN" 
-- Herb.Peyerl at novatel.cuc.ab.ca


More information about the Slony1-general mailing list