How to fix SVN Error Commit failed; Unable to open an ra_local session to URL

You may get this error if your svn repository moved:
svn: Commit failed (details follow):
svn: Unable to open an ra_local session to URL
svn: Unable to open repository 'file:///path/to/repository'
You will need to relocate your svn source repository. Here's the scenario:
Repository was located in:
Repository moved to:
Files are located in:
Open terminal and do the following to update the location of the repository: Check where the current location of the repository is using:
cd /var/www/
svn info
Look for "Repository Root:" ("file:///home/user/var/www/repositories/") Now to switch the repository root, do the following:
cd /var/www/
svn switch --relocate file:///home/user/var/www/repositories/ file:///home/user/mounts/
That is, svn switch --relocate old_repo new_repo. Again, do svn info to check that the repository root has been updated.
svn info
NOTE: Remember there are three (3) slashes after file in file:///
If you liked this posting, please feel free to leave me a comment below.
View this page on GitHub.
Posted .


  1. anonymous

    THANKS you saved me a bunch of time.

  2. anonymous


  3. anonymous

    thank you!!

Leave a Reply