MikeKane
asked on
SVN problem - Repo will not load
Any thoughts on the following:
We have several svn repository's located in /svn/repos/ such as
/svn/repos/project1
/svn/repos/project2
We have a backup script which essentially runs, as the www-data user, the following command on every repo:
svnadmin dump /svn/repos/project1 | bzip2 -9 >
/backup/project1-backup.sv ndump.bz2
This worked fine for a long time until something changed and /backup was recreated blank and the ownership of the older was wrong. www-data no longer had access to write to /backup so the backup would have failed.
For whatever reason though, in all the repo's key system files are missing now, files that make svn recognize the folder as "svn enabled".
The /svn/repos/project1/format file was missing, when I put the "format"
file back from a newly created repo, svnadmin verify then complained the /svn/repos/project1/locks/ db.lock file was missing. When I put that file back in place from a newly created svn repo, then svnadmin verify complained about /svn/repos/project1/db/DB_ CONFIG file missing. So at least 3 key files are missing, presumably much more. The only explanation is that the svnadmin dump command removed these core files but not sure why or how to repair the svn structure. The folders themselves are large, so the data is there/in-tact but I have no idea how to get svn to rebuild the missing files.
www-data@svnserv:/svn$ svnadmin verify /svn/repos/project1/
svnadmin: Can't open file '/svn/repos/project1/forma t': No such file or directory
www-data@svnserv:/svn$ svnadmin recover /svn/repos/project1/
svnadmin: Can't open file '/svn/repos/project1/forma t': No such file or directory
www-data@svnserv:/svn$ cp /svn/repos/newtestrepo/for mat /svn/repos/project1/ www-data@svnserv:/svn$ svnadmin verify /svn/repos/project1/
svnadmin: Error opening db lockfile
svnadmin: Can't open file '/svn/repos/project1/locks /db.lock': No such file or directory
www-data@svnserv:/svn$ svnadmin recover /svn/repos/project1/
svnadmin: Error opening db lockfile
svnadmin: Can't open file '/svn/repos/project1/locks /db.lock': No such file or directory
www-data@svnserv:/svn$ cp repos/newtestrepo/locks/db .lock repos/project1/locks/ www-data@svnserv:/svn$ svnadmin verify /svn/repos/project1/
svnadmin: Berkeley DB error for filesystem '/svn/repos/project1/db'
while opening environment:
svnadmin: Can't open file '/svn/repos/project1/db/DB _CONFIG': No such file or directory
www-data@svnserv:/svn$ svnadmin recover /svn/repos/project1/ Repository lock acquired.
Please wait; recovering the repository may take some time...
svnadmin: Can't open file '/svn/repos/project1/db/DB _CONFIG': No such file or directory
We have several svn repository's located in /svn/repos/ such as
/svn/repos/project1
/svn/repos/project2
We have a backup script which essentially runs, as the www-data user, the following command on every repo:
svnadmin dump /svn/repos/project1 | bzip2 -9 >
/backup/project1-backup.sv
This worked fine for a long time until something changed and /backup was recreated blank and the ownership of the older was wrong. www-data no longer had access to write to /backup so the backup would have failed.
For whatever reason though, in all the repo's key system files are missing now, files that make svn recognize the folder as "svn enabled".
The /svn/repos/project1/format
file back from a newly created repo, svnadmin verify then complained the /svn/repos/project1/locks/
www-data@svnserv:/svn$ svnadmin verify /svn/repos/project1/
svnadmin: Can't open file '/svn/repos/project1/forma
www-data@svnserv:/svn$ svnadmin recover /svn/repos/project1/
svnadmin: Can't open file '/svn/repos/project1/forma
www-data@svnserv:/svn$ cp /svn/repos/newtestrepo/for
svnadmin: Error opening db lockfile
svnadmin: Can't open file '/svn/repos/project1/locks
www-data@svnserv:/svn$ svnadmin recover /svn/repos/project1/
svnadmin: Error opening db lockfile
svnadmin: Can't open file '/svn/repos/project1/locks
www-data@svnserv:/svn$ cp repos/newtestrepo/locks/db
svnadmin: Berkeley DB error for filesystem '/svn/repos/project1/db'
while opening environment:
svnadmin: Can't open file '/svn/repos/project1/db/DB
www-data@svnserv:/svn$ svnadmin recover /svn/repos/project1/ Repository lock acquired.
Please wait; recovering the repository may take some time...
svnadmin: Can't open file '/svn/repos/project1/db/DB
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER