• unknown's avatar
    BUG #28421 Infinite loop on slave relay logs · c1043021
    unknown authored
    Manually deleteing one or more entries from 'master-bin.index', will
    cause master infinitely loop to send one binlog file. 
    
    When starting a dump session, master opens index file and search the binlog file
    which is being requested by the slave. The position of the binlog file in the
    index file is recorded. it will be used to find the next binlog file when current
    binlog file has dumped completely. As only the position is used, it may
    not get the correct file if some entries has been removed manually from the index file.
    the master will reopen the current binlog file which has been dump completely
    and redump it if it can not get the next binlog file's name from index file.
    It obviously is a logical error.
    
    
    Even though it is allowed to manually change index file,
    but it is not recommended. so after this patch, master
    sends a fatal error to slave and close the dump session if a new binlog file
    has been generated and master can not get it from the index file.
    c1043021
truncate_file.inc 308 Bytes