2

So I've setup RAID1 with an LVM on that and then used the LVM as a physical disk for DRBD. I'm planning on mounting the DRBD to /mnt/data and then moving all config and data files for apache2, mysql, and ftp to /mnt/data respectively. Is this setup ok? Recommended for or against? Thought? First time setting this up. Thanks in advance.

edit: Can I use DRBD as a base for the entire OS except /boot and just be done with it?

2 Answers 2

2

If your goal is to keep consistent copies of your configuration files across multiple machines, a tool such as Puppet may be more suited to the task.

This probably makes things more intuitive for the next person to look at the system and keeps the package management software from freaking out. Also, configuration files are often hard-coded into place in software, so you'll either be recompiling or making symlinks until the cows home.

Use a configuration management system and implement offline backups. See also Configuration Deployment to Linux Systems

edit: Can I use DRBD as a base for the entire OS except /boot and just be done with it?

No! For starters, your systems will have the same hostname (/etc/hostname) and the same IP unless you use DHCP. Then how will you point them at each other for DRDB use?

4
  • I'm struggling to understand how Puppet will help. Will it keep the apache2, mysql and ftp config files (possibly any other config files in sync with each other? May 24, 2012 at 19:56
  • @DavidNeudorfer Yes. You edit your configurations in a central place and they are pulled down by the servers. You can also set variables based on machine, collected data and distribute to other machines, etc. May 24, 2012 at 19:58
  • Interesting. And they allow you to manage 10 nodes for free. I'm definitely going try this out. May 24, 2012 at 20:04
  • Crap. You're right. Ok so I'm thinking drbd mount points for each data folder I want to keep in sync. apache2;/var/www -- mysql;/opt/mysql and then puppet to sync the config files. May 24, 2012 at 20:15
0

What you are proposing is certainly a common configuration.

It makes most sense if you combine it with some sort of cluster resource manager so that all your services and the active DRBD volume automatically move to your secondary host in the event of a failure.

1
  • I will be using heartbeat and pacemaker for this. I also agree with you regarding the configuration files. Am I better off creating an LVM mount points for each of the configuration file locations on top of the DRBD? May 24, 2012 at 19:57

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .