SVN repository in shared directory

Discussions about using Linux guests in VirtualBox.
Post Reply
dziadgba
Posts: 2
Joined: 23. Jun 2010, 15:52
Primary OS: MS Windows 7
VBox Version: OSE other
Guest OSses: Ubuntu

SVN repository in shared directory

Post by dziadgba »

Hy,

I use a host windows 7 system which has an automatic Backupsoftware running.
In order to backup svn repository which I am using in the Ubuntu Guest System I created the SVN repository in the mounted shared folder.
I can read and write the shared folder from ubuntu as well as from windows 7.

Creation of the repository with

Code: Select all

svnadmin create /home/dziadgba/host/
works fine.
But when I try to import:

Code: Select all

svn import /home/dziadgba/mb/ file:///home/dziadgba/host
Adding         /home/dziadgba/mb/trunk
Skipped '/home/dziadgba/mb/.svn'
Adding         /home/dziadgba/mb/branches
Adding         /home/dziadgba/mb/tags
svn: Can't read directory '/home/dziadgba/host/db/transactions/0-0.txn': Partial results are valid but processing is incomplete
svn: Your commit message was left in a temporary file:
svn:    'svn-commit.4.tmp'
... a error is diplayed.

Repeating the same procedure on a normal folder in linux (not shared) works fine.

Somebody has an idea what I am doing wrong?

thanks
dziadgba
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: SVN repository in shared directory

Post by Sasquatch »

I've seen other users with SVN problems in combination with Shared Folders. For some, a check-out of an SVN repo fails when the destination is an SF. I however wasn't able to reproduce that problem.
As a work-around, I would suggest that you use a local SVN repo that you sync every x minutes or so (or when you make an update) to a shared folder for your Host backup system.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
dziadgba
Posts: 2
Joined: 23. Jun 2010, 15:52
Primary OS: MS Windows 7
VBox Version: OSE other
Guest OSses: Ubuntu

Re: SVN repository in shared directory

Post by dziadgba »

Thanks! I followed your hint.
Maybe somebody is interested in how I proceeded:

1) install unison (program for file syncronisation)

Code: Select all

apt-get install unison
2) create profile file svnTohostsvn containing directories to be synchronised

Code: Select all

# Unison preferences file
root = /home/dziadgba/svn
root = /home/dziadgba/host/svn

3) Script containing commands "mySync"

Code: Select all

unison svnTohostsvn -perms 0 -batch -log -logfile /home/dziadgba/.unison/myLog
echo "Syncorization Successful: $(date)" >> /home/dziadgba/.unison/myLog
4) The script has to be called periodically

Code: Select all

crontab -e
adding following line:

Code: Select all

30 13,19 * * * /home/dziadgba/.unison/mySync
(do not forget to put a new line)

Now the local folder svn will be synchronised with the shared folder host/svn twice a day at 13:30 and 19:30
Post Reply