0

Hey Serverfault community,

So what are the best practices for managing backups of various configuration files on a production unix/linux systems?

for example, (and why I am asking). I am part of a team managing some production radius servers(FreeRADIUS). We need a way to efficiently manage, document and backup changes to to config files.

Right now I just added a dir with configbackups and just append a date to the backup. The problem is various configs are stored all over the system and there is now way to easily track changes made and quickly restore. plus it becomes a nasty mess in the long run.

Any ideas?

Also, any links to questions or answers that have great ideas/scripts used for backup would be most appreciated.

Thanks!

bobloblaw
  • 5
  • 1
  • 3

2 Answers2

2

The best-practice today is to use some form of a configuration management system. You could easily couple this with a version control system.

There are a lot of options in the space, but a solution centered around Puppet, for instance, would give you the ability to ensure that the configuration files across systems are consistent. It's actually a form of documentation.

However, this has been covered here before... There's no single best solution, but you can integrate parts of solutions and mold them to fit your environmental/political/business requirements.

ewwhite
  • 194,921
  • 91
  • 434
  • 799
2

There are two ways to do this:

One Recommended way is to track and manage all changes using Puppet or Chef. i would prefer Puppet because of its ease of use. Puppet maintains full track of any change in any configuration file on any of its clients, so you can easily track the changes and revert them back as well in case of any problem.

Seconds solution is to manage all your configuration files using SVN, where for example /etc directory will be checked out version of an SVN respository, and whenever you have to make any change in any file, just use svn commit command. This way all of your configuratin files will have revisions maintained by SVN.

I recommend first method, which is little complex but best.

Farhan
  • 4,210
  • 9
  • 47
  • 76
  • 1
    Instead of using SVN, look into using FSVS instead, which is far better suited for storing /etc in an SVN repository, without needing to create a .svn folder. – tgharold Aug 12 '13 at 04:34