Create NEW raid 1 device and mount for mysql

Discussion in 'Installation/Configuration' started by ShadoweElf, Sep 29, 2012.

  1. ShadoweElf

    ShadoweElf New Member

    Hi all

    I have a perfect setup centos 6.2 with ispconfig 3 installed.
    It is a production server.

    Database are very big (100 G) and I want to add a raid ssd device for mysql

    I want to buy 2 ssd hdd, create a raid1 device and mount it in /var/lib/mysql where is the deault folder.

    I need help because is a production server. With a test server I can try and play, but I can't do test's in my situation...

    i'm looking for something like a perfect setup

    thx
     
  2. falko

    falko Super Moderator

    This isn't possible without stopping MySQL for some seconds. You must mount your RAID device somewhere, stop MySQL, copy /var/lib/mysql to the new device, rename /var/lib/mysql to something else (like /var/Lib/mysql_old), create a new and empty /var/Lib/mysql directory, remount the RAID device to /var/lib/mysql, chown /var/lib/mysql to mysql:mysql, and start MySQL.
     
  3. ShadoweElf

    ShadoweElf New Member

    thx falco

    Thx falco, but I need the commands to run

    I have unformatted devices sdc and sdd

    I want to know how I create a new ext4 raid1 device...

    Thx
     
  4. Puck

    Puck New Member

    Read man mdadm. it's very clear :cool:
     

Share This Page