Replace a failing brick in a replicated GlusterFS Volume

On one of the servers with GlusterFS, I use USB-Disks in a replicated GlusterFS volume. Although once in a while a disk just "dies" and using "replace brick" command is not an option.

So I figured out the following steps:

  1. Stop the GlusterFS Daemon

  2. Remove the faulty brick

  3. Configure the new brick to mount on the same mountpoint as the old one

  4. Start GlusterFS Daemon

  5. Trigger a self-heal on the GlusterFS Volume

  6. Get coffee/..

  7. The new brick will contain the data :-)

Please note, this only works for replicated volumes!