Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm considering hardlinking config files into a working copy of my SVN config repository. Is there any reason why not to manage config files this way?

Assume /home/user/confmgr/confs is a working copy of my config repository. Then I could hardlink config files as follows-

ln /etc/php.ini /home/user/confmgr/confs/php.ini
ln /etc/httpd/conf/httpd.conf /home/user/confmgr/confs/httpd.conf

Then when I need to edit a config file it's this simple

cd /home/user/confmgr/confs
vi httpd.conf
/sbin/service httpd configtest
/sbin/service httpd graceful
svn commit -m 'adding virtual host to httpd.conf for new project'
share|improve this question

A few observations in almost reverse order:

  1. Why not symlink instead?
  2. Consider turning your workflow around. Safely make your changes to a second working copy, review and commit, then svn up the working copy in live use.
  3. There are more sophisticated tools to manage complex config structures from version control. Consider using Puppet, BCFG2, etckeeper and so on.
share|improve this answer

I wouldn't put them in /home

Place the config files somewhere in the root filesystem.

This is because / is mounted before the other filesystems and there is a chance it might need config files that are located on a not yet mounted filesystem.

I would also use symlinks and not hardlinks. Cross filesystem hardlinks aren't allowed (iirc) and you might get broken links when you check out updated files from SVN (changing inodes).

You'll need to be very careful but I can't see a reason why you can't run with this config.

share|improve this answer

etc-keeper is probably a good reference design for you:

etckeeper is a collection of tools to let /etc be stored in a git, mercurial, darcs, or bzr repository.

It stores the repo in /etc/.$RCS, but it doesn't support SVN. I'm not sure why; the author merely states he tried it and it sucks. Essentially, this approach makes /etc the working copy.

share|improve this answer
For those of us who are invested in SVN, it looks like <a href="">fsvs</a>; is a similar product which uses a SVN backend. – Stefan Lasiewski May 17 '10 at 23:06
Fixed link: – user9876 May 28 '15 at 16:15

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.