title: Moving a MySQL slave to new hard drives - do I need mysqld-relay-bin logs?
body: <p>I am moving a MySQL slave from one set of HDs to another. The configuration of the machine denies me the ability to have both old and new hard drives on it at the same time. So I rsync'ed the data directory to another machine.</p>
  
  <p>Whe the new hard drives came online, I rsyn'ed the data dir back. This worked fine.</p>
  
  <p>However, I cannot start replication. This is the error I get.</p>
  
  <pre><code>120314  4:23:07 [Warning] Neither --relay-log nor --relay-log-index were used; so replication may break when this MySQL server acts as a slave and has his hostname changed!! Please use '--relay-log=mysqld-relay-bin' to avoid this problem.
  120314  4:23:07 [ERROR] Failed to open the relay log '/var/lib/mysqllogs/mysqld-relay-bin.000273' (relay_log_pos 677043943)
  120314  4:23:07 [ERROR] Could not find target log during relay log initialization
  120314  4:23:07 [ERROR] Failed to initialize the master info structure
  </code></pre>
  
  <p>I found this comment:
  <a href="https://serverfault.com/questions/61471/moving-a-mysql-slave-to-a-new-host-failed-to-open-the-relay-log">https://serverfault.com/questions/61471/moving-a-mysql-slave-to-a-new-host-failed-to-open-the-relay-log</a></p>
  
  <blockquote>
    <p>If it is just complaining about the relay logs, in most cases, they
    are disposable if the master still has the binary logs around. You can
    just run CHANGE MASTER TO on the slave and it will flush the existing
    relay logs and start anew. You don't need to make a new fresh copy.</p>
  </blockquote>
  
  <p>This seems to suggest that I do not need these log files. </p>
  
  <p>The host name is not changing.</p>
  
  <p>My Questions:</p>
  
  <p>Do I need these log files?</p>
  
  <p>If not, what do I need to do to get replication started? Will it remember where it left off?</p>
  
  <p>If I do need these log files, is there anything else I'm forgetting?</p>