[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

addition to project_faq (out of free space == repository crashed, no recovery possible)

From: Arkadiusz Miskiewicz <arekm_at_pld-linux.org>
Date: 2004-07-12 00:50:18 CEST

Hi,

Out of disk space combined with checkouts causes BDB to crash
in a way where even db_recover doesn't work.

This happened to me recently - apache 2.0.50, subversion 1.0.5, db 4.2.52
(+ two patches from berkeley db web site). My setup was simple repository
with few files accessible via http and one process on other host doing
svn up once per minute. When there was no free space on svn server
BDB crashed in a way that svnadmin recovery didn't work - tried
db_recover - also didn't work:

[root@maja subversion]# db_recover -cve -h db
db_recover: Finding last valid log LSN: file: 70 offset 436312
db_recover: Recovery function for LSN 69 11635 failed
db_recover: PANIC: Is a directory
db_recover: PANIC: fatal region error detected; run recovery
[...]
db_recover: PANIC: fatal region error detected; run recovery
db_recover: PANIC: fatal region error detected; run recovery
db_recover: PANIC: fatal region error detected; run recovery
db_recover: DB_ENV->open: DB_RUNRECOVERY: Fatal error, run database recovery

People on #svn tell me that:
- there is no way to check how much of free space is needed
  by BDB to do some operation (I was proposing that svn simply refused to work when
  there was less than XYZ MB of free space)
- there is no portable way to check available disk space
- FSFS is supposed to be more immune to such problems

Unfortunately using subversion 1.0 would be too big risk because I have no control
over free disk space here :/ I'm hoping that FSFS will really work better in such cases.

Something like this should be added to FAQ:

Index: project_faq.html
===================================================================
--- project_faq.html (revision 10242)
+++ project_faq.html (working copy)
@@ -1264,6 +1264,7 @@
   <li>the process crashing/segfaulting</li>
   <li>the process being forcibly killed</li>
   <li>the process exiting when it hits a permission problem</li>
+ <li>out of disk space</li>
 </ul>

 <p>To make the repository function again, simply run "svnadmin
@@ -1297,6 +1298,9 @@
     to make this scenario safer.</li>
 </ul>

+<p>Unfortunately out of disk space errors combined with frequent
+checkouts or updates can cause repository crash in a way
+where recovery is not possible (so keep backups!).</p>.

 <![CDATA[-----------------------------------------------------------]]>

-- 
Arkadiusz Mi¶kiewicz     CS at FoE, Wroclaw University of Technology
arekm.pld-linux.org, 1024/3DB19BBD, JID: arekm.jabber.org, PLD/Linux
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Jul 12 00:50:41 2004

This is an archived mail posted to the Subversion Dev mailing list.