title: mysql: alter large table, disk space issue
body: <p>I want to alter an over 100Gb MySQL table.<br>
  According to manual MySQL is first creating an altered copy of the table, then replace it with the new one.</p>
  
  <p>But, MySQL tries to create the copy in /tmp but the filesystem there is much smaller.
  In result, mysql fails with the following error:</p>
  
  <pre><code>ERROR 3 (HY000) at line 1: Error writing file '/tmp/STa3x0Vi' (Errcode: 28)
  </code></pre>
  
  <p>How can I make mysql go a smarter way?</p>