美文网首页
MySQL START SLAVE Syntax

MySQL START SLAVE Syntax

作者: 过往云技 | 来源:发表于2018-12-29 17:28 被阅读0次

    原文地址:https://dev.mysql.com/doc/refman/8.0/en/start-slave.html

    语法

    START SLAVE [thread_types] [until_option] [connection_options] [channel_option]
    
    thread_types:
        [thread_type [, thread_type] ... ]
    
    thread_type:
        IO_THREAD | SQL_THREAD
    
    until_option:
        UNTIL {   {SQL_BEFORE_GTIDS | SQL_AFTER_GTIDS} = gtid_set
              |   MASTER_LOG_FILE = 'log_name', MASTER_LOG_POS = log_pos
              |   RELAY_LOG_FILE = 'log_name', RELAY_LOG_POS = log_pos
              |   SQL_AFTER_MTS_GAPS  }
    
    connection_options:
        [USER='user_name'] [PASSWORD='user_pass'] [DEFAULT_AUTH='plugin_name'] [PLUGIN_DIR='plugin_dir']
    
    
    channel_option:
        FOR CHANNEL channel
    
    gtid_set:
        uuid_set [, uuid_set] ...
        | ''
    
    uuid_set:
        uuid:interval[:interval]...
    
    uuid:
        hhhhhhhh-hhhh-hhhh-hhhh-hhhhhhhhhhhh
    
    h:
        [0-9,A-F]
    
    interval:
        n[-n]
    
        (n >= 1)
    

    在MySQL8 使用 START SLAVE 遇到下面警告!

    Storing MySQL user name or password information in the master info repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START SLAVE; see the 'START SLAVE Syntax' in the MySQL Manual for more information

    使用例句

    START SLAVE USER='userName' PASSWORD='password'
    

    相关文章

      网友评论

          本文标题:MySQL START SLAVE Syntax

          本文链接:https://www.haomeiwen.com/subject/oxsplqtx.html