Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

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 was looking for a way to backup all our SVN repositories, and came across this:

Because our repositories are organized in a client / project directory structure, i changed the script into this:




echo 'dumping client: ' $CLIENT


echo 'dumping repository: ' $REPOSITORY


After running it (it completed the backup successfully), i get the following error on every repository that was to be backed up:

<m:human-readable errcode="2">
Could not open the requested SVN filesystem

I looked in the apache error log, and this is what i found:

(20014)Internal error: Can't open file '/var/svn/repos/Test2/Test3.gz/format': No such file or directory, referer:

The way i see it, somehow the backup script added the .gz at the end of the repo path ([...]Test2/Test3**.gz**). After further cheking i noticed the single quotes surrounding the .gz extension in the script.

Any thoughts ?

share|improve this question
up vote 2 down vote accepted

Ok, i'm feeling very embarassed right now ... it seems that everything was ok, but since i had the brilliant idea of saving the backups in public_html/ with the exact same directory structure as the repositories, and had a in an Apache conf file, somehow the .gz files were being treated as repositories.

To clarify, i had the following structure for the backups:


... and this one for the repositories:


in a Apache conf file i had:

<Location /svn>
    DAV svn

When navigating with the browser to /svn, i encountered the specified error. Renaming or moving the backup folder from public_html/ solved the problem and made me feel stupid.

share|improve this answer
Well that explains a lot - I didn't even consider your backup path (other than it was legal and ended in a '/') - Big oops on my part. – Chealion Jun 16 '09 at 16:17

If you descend into /var/svn/repos, are the backup archives listed there? /var/svn/repos/Test2/Test3.gz should not exist as such; it only exist in /home/hyperactive/public_html/svn

share|improve this answer
No, they are not in /var/svn/repos, they are indeed in /home/hyperactive/[...] – Victor Stanciu Jun 16 '09 at 14:48

In the script - to clarify:

Repositories are laid out as follows:

/var/svn/repos/CLIENT/REPOSITORY_NAME? Test2 is the client and Test3 is the repository in your example? It's unclear.

Removing those folders should fix the issue (I recommend moving them before actually running rm on them)


 echo 'dumping client: ' $CLIENT

Where is the done to finish the loop? It's not added to the question - I'm assuming it's at the end of the file.

The '.gz' with single quotes is added to make sure .gz is added to the gzip file and not part of the variable $REPOSITORY

I gave the script a run myself - and it worked fine.

Old Answer

Have you unzipped the backup?

The line svnadmin dump $SVN_REPOSITORIES_ROOT_DIR$CLIENT/$REPOSITORY | gzip > $BACKUP_DIRECTORY$CLIENT/$REPOSITORY'.gz' dumps the subversion repository and then zips it up into one smaller file. Try running unzip REPOSITORY.gz and your folder structure will be revealed.

share|improve this answer
The problem is with the repos after backing them up, not with the resulting zipped dumps. After running the script that made the dumps, the repos that were backed up broke. – Victor Stanciu Jun 16 '09 at 14:34

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.