Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

It appears overnight our Master RDS mysql server went offline for 3-4 minutes. When it came back online the replication was broken.

On the slave, issuing SHOW SLAVE STATUS\G;

"Got fatal error 1236 from master when reading data from binary log: 'Client requested master to start replication from impossible position'"

In AWS monitoring, slave lag shows "-1.0".

Is there a way to get the slave replication restarted, or should I just create a new slave?

share|improve this question

1 Answer 1

up vote 0 down vote accepted

There's really no harm in just spooling up a new slave, so I'd go that route.

share|improve this answer
    
I am in this situation and want to replace the malfunctioning replica. The problem is the hostname: can I rename the old replica to something, and then rename the new one to the old one's name, and keep the same hostname as before? Is there anything I need to be aware of? Can something go terribly wrong? –  FrontierPsycho Jun 17 at 14:30
    
@FrontierPsycho You can promote a replica to master, but I don't think you can promote a replica to another replica's spot. We use DNS for this - our master is db.internal.example.com, our read-replica is read-db.internal.example.com, so switching replicas is just a Route53 record change. –  ceejayoz Jun 17 at 14:33
    
That's a better way to do it, although we're using the internal RDS hostname currently, and I'd like to avoid having to change that everywhere it's used. I guess I'll try it and see. –  FrontierPsycho Jun 17 at 14:54

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.