~chuck-bell/mysql-utilities/mysql-utilities

« back to all changes in this revision

Viewing changes to mysql/utilities/command/rpl.py

  • Committer: chuck.bell at oracle
  • Date: 2011-09-29 14:14:38 UTC
  • Revision ID: chuck.bell@oracle.com-20110929141438-clzfl7m2769wt2jm
WL#5983 : allow user to specify binary log file and position (mysqlreplicate)

This patch adds new features to mysqlreplicate to permit starting replication
from the beginning, starting from a specific log file, and starting from a
specific log file and position.

Show diffs side-by-side

added added

removed removed

Lines of Context:
51
51
    master = servers[0]
52
52
    slave = servers[1]
53
53
    
 
54
    rpl_options = options.copy()
 
55
    rpl_options['verbosity'] = verbosity > 0
 
56
    
54
57
    # Create an instance of the replication object
55
 
    rpl = Replication(master, slave, verbosity > 0)
 
58
    rpl = Replication(master, slave, rpl_options)
56
59
    errors = rpl.check_server_ids()
57
60
    for error in errors:
58
61
        print error
124
127
    }
125
128
    servers = connect_servers(master_vals, slave_vals, conn_options)
126
129
    
 
130
    rpl_options = options.copy()
 
131
    rpl_options['verbosity'] = options.get("verbosity", 0) > 0
 
132
 
127
133
    # Create an instance of the replication object
128
 
    rpl = Replication(servers[0], servers[1], options.get("verbosity", 0) > 0)
 
134
    rpl = Replication(servers[0], servers[1], rpl_options)
129
135
    
130
136
    if not quiet:
131
137
        print "Test Description",