You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by "Filipe Manana (JIRA)" <ji...@apache.org> on 2010/08/05 11:57:17 UTC

[jira] Commented: (COUCHDB-844) Documents missing after CouchDB restart

    [ https://issues.apache.org/jira/browse/COUCHDB-844?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12895626#action_12895626 ] 

Filipe Manana commented on COUCHDB-844:
---------------------------------------

Sascha,

This is likely because you have delayed commits turned on in your .ini config (they're enabled by default).
With delayed commits on, Couch writes the doc to the DB file, then replies to the client with an HTTP 201 code, and then after 1 second it does an fsync.

So if the crash/restart happened in less than 1 second after saving the doc...

> Documents missing after CouchDB restart
> ---------------------------------------
>
>                 Key: COUCHDB-844
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-844
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Database Core
>    Affects Versions: 1.0
>         Environment: Debian Version 5.0.5, Linux *** 2.6.29-xs5.5.0.17 #1 SMP Mon Aug 3 17:37:37 UTC 2009 i686 GNU/Linux, XenServer Guest
>            Reporter: Sascha Reuter
>            Priority: Critical
>
> After a CouchDB restart, recently added/changed documents+designdocuments (min. 2 weeks timeline!) are missing and cant be accessed trough REST Calls / Futon. 
> All documents that are still available trought REST/Futon only exist in old revisions.
> All documents/revisions can be found doing a manual search (less/egrep/...) in the datafile (/var/lib/couchdb/<database>.couch)
> Example:
> strings dtap.couch | grep -i "226b2e6c-24b7-4336-92c7-257abf923b11"
> $226b2e6c-24b7-4336-92c7-257abf923b11h
> $226b2e6c-24b7-4336-92c7-257abf923b11l
> $226b2e6c-24b7-4336-92c7-257abf923b11l
> $226b2e6c-24b7-4336-92c7-257abf923b11l
> $226b2e6c-24b7-4336-92c7-257abf923b11l
> $226b2e6c-24b7-4336-92c7-257abf923b11l
> $226b2e6c-24b7-4336-92c7-257abf923b11l
> $226b2e6c-24b7-4336-92c7-257abf923b11l
> $226b2e6c-24b7-4336-92c7-257abf923b11l
> $226b2e6c-24b7-4336-92c7-257abf923b11h
> $226b2e6c-24b7-4336-92c7-257abf923b11h
> curl http://localhost:5984/dtap/226b2e6c-24b7-4336-92c7-257abf923b11
> {"error":"not_found","reason":"missing"}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.