开发者

SVN - Not able to commit files (Can't create directory - no such file or directory)

I wanted to move our 开发者_C百科existing repository (from location A) to a new linux server (location B). So, I created a new repository in that server (location B) with the command:-

svnadmin create --fs-type fsfs <repository_name>

Then I copied the db folder from location A and overwrote that of location B, because I want to keep the previous revisions. I created a system user in location B using the command:-

useradd sandeepan
passwd sandeepan

I did not specify any permissions for the user on the repository.

After that I took checkout from URL svn+ssh://<IP>/<path to repository> and it worked successfully. I am able to update to previous revisions but not able to commit. It says -

Commit failed - Can't create directory 'path/to/repository/db/transactions/1852-1.txn' no such file or directory

So, I tried to provide access to the repository for that user like this:-

groupadd svn_users
usermod -a -G svn_users harry
chgrp -R svn_users /var/backup/hello

But still getting the same error. I am using Smart SVN 5.0.4

Thanks,

Sandeepan

Update

Even after following Greg's recommendation, I am not able to commit. The error now says Permission denied:-

Commit failed - Can't create directory 'path/to/repository/db/transactions/1855-1.txn': 
Permission denied


When moving a Subversion repository from one machine to another, I would strongly recommend that you use svnadmin dump and svnadmin load to copy the repository. There are subtle differences between minor versions of Subversion that make copying the repository database problematic.


I did a similar move, and have a similar problem. The transactions directory in db did not exist, or I did not copy it. My fix was to manually create the db/transaction directory. I can now commit.


It was because chmod was not done!!

I did chmod -R 770 and it solved the problem.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜