~ubuntu-branches/ubuntu/maverick/slony1/maverick

« back to all changes in this revision

Viewing changes to src/ducttape/test_2_handover_to_2

  • Committer: Bazaar Package Importer
  • Author(s): Peter Eisentraut
  • Date: 2006-11-17 17:19:48 UTC
  • mfrom: (1.1.2 upstream) (2.1.1 etch)
  • Revision ID: james.westby@ubuntu.com-20061117171948-jd89seng1dcff6rc
Tags: 1.2.1-1
* New upstream release
  - Updated no-client-log.patch
  - Obsoleted patches: hardcoded-paths.patch
* Updated watch file
* Reenabled Perl tools
* Added missing final newline to slon.conf-sample
* Updated test script

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/bin/sh
 
2
 
 
3
# **********
 
4
# test_1_handover_to_2
 
5
#
 
6
#       Script to change the origin of set 1 from node 1 to node 2.
 
7
#       This still requires that node 1 is alive. This is called
 
8
#       handover or move, not failover.
 
9
# **********
 
10
 
 
11
export PATH
 
12
TMPOUT=/tmp/output.$$
 
13
DB1=slony_test1
 
14
DB2=slony_test2
 
15
 
 
16
######################################################################
 
17
# Move set 1 to node 2
 
18
######################################################################
 
19
 
 
20
echo "**** Move set 1 to node 2"
 
21
slonik <<_EOF_
 
22
        cluster name = T1;
 
23
        node 1 admin conninfo = 'dbname=$DB1';
 
24
        node 2 admin conninfo = 'dbname=$DB2';
 
25
 
 
26
        lock set (id = 1, origin = 1);
 
27
        move set (id = 1, old origin = 1, new origin = 2);
 
28
_EOF_
 
29