You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@couchdb.apache.org by vamsi dhar <g....@gmail.com> on 2010/05/25 22:29:24 UTC

Cannot connect to Couch DB after unplanned system reboot

Hi All,

 I have installed the latest version of Couch DB in Linux machine. I have
been working with out any issues till today morning when i had to manually
reboot the machine because it got hanged. After this when i try to connect
to Couch DB from UI i get the below error message.

Database information could not be retrieved: {{badmatch,{error,eacces}},
 [{couch_file,init,1},{gen_server,init_it,6},{proc_lib,init_p_do_apply,3}]}

I investigated through several forums and found that it might be because of
permission issue. I tried to change the permission of the Couch DB, ran it
as root . Nothing helped. Can any one please point me out on how to approach
this problem ? Are there any repair / restore tools available with Couch DB
?

Thanks,
Vamsi.

Re: Cannot connect to Couch DB after unplanned system reboot

Posted by Manokaran K <ma...@gmail.com>.
On Wed, May 26, 2010 at 1:59 AM, vamsi dhar <g....@gmail.com> wrote:

> Hi All,
>
>  I have installed the latest version of Couch DB in Linux machine. I have
> been working with out any issues till today morning when i had to manually
> reboot the machine because it got hanged. After this when i try to connect
> to Couch DB from UI i get the below error message.
>
> Database information could not be retrieved: {{badmatch,{error,eacces}},
>  [{couch_file,init,1},{gen_server,init_it,6},{proc_lib,init_p_do_apply,3}]}
>
> I investigated through several forums and found that it might be because of
> permission issue. I tried to change the permission of the Couch DB, ran it
> as root . Nothing helped. Can any one please point me out on how to
> approach
> this problem ? Are there any repair / restore tools available with Couch DB
> ?
>

It is possible that all couchdb related files are owned by the user
'couchdb'. Try:

sudo -i -u couchdb couchdb

regds,
mano

Re: couchdb local.ini set up

Posted by J Chris Anderson <jc...@gmail.com>.
On Jun 10, 2010, at 10:14 AM, farad wrote:

> Randall Leeds <ra...@...> writes:
> 
>> 
>> Hi, Tomy.
>> 
>> Not sure what you mean by UI. If you refer to the Futon web interface
>> it should be enabled by default. Simply launch couchdb and go to
>> http://127.0.0.1/_utils in your browser.
>> 
>> Did you install from source/homebrew or using CouchDB X?
>> 
>> -Randall
>> 
>> 
> Hi, Randall,
> all ui files of my project is in the dir 'share/couchdb/www/myproject'. My
> program takes user entry data from ui and serialize it in to json file. Next
> what i need save this json file to mydb at cuouchdb. And then fetch data from
> mydb to display them on ui 
> 

You should probably take a look at the CouchApp project, which allows you to move this myproject directory to a CouchDB document, so that it can replicate along with the data.

http://couchapp.org (is a couchapp)

http://github.com/couchapp/couchapp (the dev tool)

http://books.couchdb.org/relax/example-app/design-documents (how to use it)

> thanks,
> farad
> 
> 
> 


Re: couchdb local.ini set up

Posted by tomy <to...@yahoo.com>.
Thanks a lot guys for ur help I really appreciate it:
Could u please explain how can I modify
this 'app.db.saveDoc({channel:cname,message:message});' for my application,
how the saveDoc() function works

function joinChannel(app, cname) {
  var authorRand = Math.random().toString();
  $("#frPage").submit(function() {
    var apl, apid, first, last, dsc, email, _id;
    apl = $("#app").val();
    apid = $("#appid").val();
    first = $("#first").val();
    last = $("#last").val();
    dsc = $("#desc").val();
    email = $("#email").val();
    if (apl) {
      var message = {
        _id:idGenerator(),
        apinfo: { apl : apl,  apid:apid, dsc:dsc
        },
        owner:{ first:first, last:last, email:email
        },
        date : new Date()
      };
      alert(JSON.stringify(message));
      app.db.saveDoc({channel:cname,message:message});
    }
    return false;
  }) 

thanks



Re: couchdb local.ini set up

Posted by J Chris Anderson <jc...@gmail.com>.
On Jun 10, 2010, at 5:27 PM, farad wrote:

> Randall Leeds <ra...@...> writes:
> 
>> 
>> There is no reason to put your application data in the www directory.
>> CouchDB can serve files as attachments to database documents without a
>> problem, which is how CouchApp functions. You should not need to
>> modify local.ini.
>> 
>> On Thu, Jun 10, 2010 at 10:14, farad <to...@...> wrote:
>>> Randall Leeds <ra...@...> writes
> 
>> 
>> 
> Function which i'm using returns jObj = {}. All data look like 
> {"app":"Intersept","appid":"1212321","first":"John","desc":"some info
> here","last":"Peterson","email":"my@may.com","srvs":"cache,queue,asset"}
> Using click event how can i save this data to 'mydb' at couchdb. 

http://github.com/jchris/toast/blob/selectorstash/_attachments/app.js#L57


> 
> thanks,
> farad
> 
> 
> 


Re: couchdb local.ini set up

Posted by farad <to...@yahoo.com>.
Randall Leeds <ra...@...> writes:

> 
> There is no reason to put your application data in the www directory.
> CouchDB can serve files as attachments to database documents without a
> problem, which is how CouchApp functions. You should not need to
> modify local.ini.
> 
> On Thu, Jun 10, 2010 at 10:14, farad <to...@...> wrote:
> > Randall Leeds <ra...@...> writes

> 
> 
Function which i'm using returns jObj = {}. All data look like 
{"app":"Intersept","appid":"1212321","first":"John","desc":"some info
here","last":"Peterson","email":"my@may.com","srvs":"cache,queue,asset"}
Using click event how can i save this data to 'mydb' at couchdb. 

thanks,
farad




Re: couchdb local.ini set up

Posted by Randall Leeds <ra...@gmail.com>.
There is no reason to put your application data in the www directory.
CouchDB can serve files as attachments to database documents without a
problem, which is how CouchApp functions. You should not need to
modify local.ini.

On Thu, Jun 10, 2010 at 10:14, farad <to...@yahoo.com> wrote:
> Randall Leeds <ra...@...> writes:
>
>>
>> Hi, Tomy.
>>
>> Not sure what you mean by UI. If you refer to the Futon web interface
>> it should be enabled by default. Simply launch couchdb and go to
>> http://127.0.0.1/_utils in your browser.
>>
>> Did you install from source/homebrew or using CouchDB X?
>>
>> -Randall
>>
>>
> Hi, Randall,
> all ui files of my project is in the dir 'share/couchdb/www/myproject'. My
> program takes user entry data from ui and serialize it in to json file. Next
> what i need save this json file to mydb at cuouchdb. And then fetch data from
> mydb to display them on ui
>
> thanks,
> farad
>
>
>
>

Re: couchdb local.ini set up

Posted by farad <to...@yahoo.com>.
Randall Leeds <ra...@...> writes:

> 
> Hi, Tomy.
> 
> Not sure what you mean by UI. If you refer to the Futon web interface
> it should be enabled by default. Simply launch couchdb and go to
> http://127.0.0.1/_utils in your browser.
> 
> Did you install from source/homebrew or using CouchDB X?
> 
> -Randall
> 
> 
Hi, Randall,
all ui files of my project is in the dir 'share/couchdb/www/myproject'. My
program takes user entry data from ui and serialize it in to json file. Next
what i need save this json file to mydb at cuouchdb. And then fetch data from
mydb to display them on ui 

thanks,
farad




Re: couchdb local.ini set up

Posted by Randall Leeds <ra...@gmail.com>.
Hi, Tomy.

Not sure what you mean by UI. If you refer to the Futon web interface
it should be enabled by default. Simply launch couchdb and go to
http://127.0.0.1/_utils in your browser.

Did you install from source/homebrew or using CouchDB X?

-Randall

Re: couchdb local.ini set up

Posted by Jarrod Roberson <ja...@vertigrated.com>.
google "couchapp"

couchdb local.ini set up

Posted by tomy <to...@yahoo.com>.
Hi All,
I'm a brand new beginner on couchdb, and really have a problem to set up the
local.ini file for my ui. I'm using OS X, if some one there can send me some
sample how do it, and where i have to put my ui files in couchdb.
How to connect my ui to db?
Any help will be appreciated

regards,
tomy



Re: Cannot connect to Couch DB after unplanned system reboot

Posted by Manokaran K <ma...@gmail.com>.
On Wed, May 26, 2010 at 1:59 AM, vamsi dhar <g....@gmail.com> wrote:

> Hi All,
>
>  I have installed the latest version of Couch DB in Linux machine. I have
> been working with out any issues till today morning when i had to manually
> reboot the machine because it got hanged. After this when i try to connect
> to Couch DB from UI i get the below error message.
>
> Database information could not be retrieved: {{badmatch,{error,eacces}},
>  [{couch_file,init,1},{gen_server,init_it,6},{proc_lib,init_p_do_apply,3}]}
>
> I investigated through several forums and found that it might be because of
> permission issue. I tried to change the permission of the Couch DB, ran it
> as root . Nothing helped. Can any one please point me out on how to
> approach
> this problem ? Are there any repair / restore tools available with Couch DB
>

It is possible that all couchdb related files are owned by the user
'couchdb'. Try: