DRBD Active/Passive facts

  • Hi All.
    My goal was to build a DRBD A/P cluster working with OMV on top of it. In particular: LVM on DRBD devices; services iscsitarget, samba and nfs; one failover IP to reach the services. Openmediavault for administering all. So also the GUI would be redundant through the two servers.


    While setup of DRBD on Linux is almost an easy task, getting synchronized users accounts, configurations and other things between two OMV installation is not trivial.


    Basically, i wrote a small piece of software called omvcheck.py (check attachment) to merge omv configuration between two nodes: in this way the parts of config.xml that contains specific machine configurations (like network and hostname for example) are preserved while all other configuration sections are merged from the newest file.


    Then I've setup csync2 for synchronizing other system files between two nodes.


    Csync2 and omvcheck are run from crontab every 5 minutes. That's because there's a remote possibility that one will switch the cluster immediately after a user is added or a new lun is added on an iscsitarget. However some improvements on this part are possible.


    At this point, i've faced a little trouble with iscsitarget plugin: infact, IQNs are generated starting from hostname and there's no way to manipulate them (without a manual intervent on plugin code!): the risk is that if one manipulate IQN from server2 while IQN is generated from server1, the name can change and things will eventually break.
    I hope that in the future OMV developers will take care about this thing.


    I needed to exclude from startup all services i need to manage from cluster software, like samba, iscsi and nfs. So I've installed pacemaker and corosync and configured the cluster to manage resources.


    At this time all things seems to work: more testing is required (i.e. NFS). On request, i can document all the steps or write a small tutorial.

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!