Datavere 4.3.1 installation problems - getSingleResult() did not retrieve any entities.

598 views
Skip to first unread message

Sourav Gupta

unread,
May 31, 2016, 7:33:09 AM5/31/16
to Dataverse Users Community
Hi everyone,

I have been trying install dataverse 4.3.1 since yesterday and now I am stuck at the following error. Will appreciate any help on this.
I am using the below:
 - OS: Ubuntu 16.04 in my home laptop.
 - Java: Oracle JDK 1.8.0_u91
 - Glassfish: 4.1.1
 - PostgreSQL: 9.5.3
 - JQ: jq-1.4
 - Solr: solr-4.6.1
 - Datavere 4.3.1

After installing dataverse 4.3.1 using the ./install from dvinstall i get an impression that everything went okay but when i open http://localhost:8080 I get the below error:

HTTP Status 500 - Internal Server Error


type Exception report

messageInternal Server Error

descriptionThe server encountered an internal error that prevented it from fulfilling this request.

exception

javax.servlet.ServletException

root cause

javax.ejb.EJBException

root cause

javax.persistence.NoResultException: getSingleResult() did not retrieve any entities.

note The full stack traces of the exception and its root causes are available in the GlassFish Server Open Source Edition 4.1.1 logs.


GlassFish Server Open Source Edition 4.1.1


I was suspecting postgresql settings being an issue (this is the first time I am using postgresql). So I had set the below in /etc/postgresql/9.5/main/pg_hba.conf:
# Database administrative login by Unix domain socket
local   all             postgres                                trust

# TYPE  DATABASE        USER            ADDRESS                 METHOD

# "local" is for Unix domain socket connections only
local   all             all                                     trust
# IPv4 local connections:
host    all             all             127.0.0.1/32            trust

I will really appreciate any help on this.

Many thanks,
Sourav Gupta.
server.log
dataverse-installation-log

Sourav Gupta

unread,
May 31, 2016, 7:58:40 AM5/31/16
to Dataverse Users Community
An update which I felt might be helpful:

After the installation when I try to login to the PostgreSQL using dvnapp user id in command line i get the below error (pardon my ignorance but i did not for anything in google when I searched with this error):
root@rituparna-inspiron-n5110:/etc/postgresql/9.5/main# psql -U dvnapp
psql: FATAL:  database "dvnapp" does not exist

Many thanks,
Sourav Gupta

Sourav Gupta

unread,
May 31, 2016, 8:05:20 AM5/31/16
to Dataverse Users Community
Sorry to spam but just found that psql by default tries to connect to a database by the name of the user and hence I got that error. When I tried the below it worked fine:
root@rituparna-inspiron-n5110:/etc/postgresql/9.5/main# psql -U dvnapp dvndb
psql (9.5.3)
Type "help" for help.

dvndb=>

So my original problem still remains same and I do not have much ideas how to go forward. Appreciate any help on this.

Many thanks,

Sourav Gupta


On Tuesday, 31 May 2016 17:03:09 UTC+5:30, Sourav Gupta wrote:

Philip Durbin

unread,
May 31, 2016, 9:07:43 AM5/31/16
to dataverse...@googlegroups.com
Hi Sourav,

The error "javax.persistence.NoResultException: getSingleResult() did not retrieve any entities." is an indication that the root dataverse was not created. In a previous thread* the problem was that `jq` was not installed but it seems like you have jq installed and I assume it's executable. In the other thread some output from the "install" script was provided which was extremely useful in troubleshooting the problem. If you could provide this output, I'd really appreciate it.

It might be helpful for you to compare your output of "install" to output from an execution of that script that worked. This output is from the "develop" branch rather than the 4.3.1 tag but it's pretty similar:

https://build.hmdc.harvard.edu:8443/job/phoenix.dataverse.org-deploy-develop/30/console

Note especially that after it says "Setting up the root dataverse" it says '{"status":"OK"...'

Anyway, again, the main thing that would be helpful is seeing this output. Please send as much of this output as you can.

Thanks for trying Dataverse!

Phil

--
You received this message because you are subscribed to the Google Groups "Dataverse Users Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-commu...@googlegroups.com.
To post to this group, send email to dataverse...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dataverse-community/683fc12b-cbf8-4430-a25e-7c9ad8d91e26%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--

Tim DiLauro

unread,
May 31, 2016, 9:10:58 AM5/31/16
to dataverse...@googlegroups.com
Hi Sourav,

This error might be caused by the absence of the "Root" dataverse. This automatically get configured by running the './install' script, as you mention below. The root dv is configured by 'setup-all.sh' using SQL from 'data/dv-root.json'. setup-all does not really have good error checking, so it's very possible that it was run, but did not do what it was supposed to do. This can happen for a variety of reasons including firewall blocking your access to port 8080 or glassfish not being completely restarted, though the 'install' script should fail with an error message for either of these cases.

To see if the root dataverse is likely the issue, connect to your dataverse database (by default this is 'dvndb') and run the following command:

select * from dataverse where alias = 'root';

The result should be a single row.

Cheers,
~Tim


> On May 31, 2016, at 7:33 AM, Sourav Gupta <gkso...@gmail.com> wrote:
>
> Hi everyone,
>
> I have been trying install dataverse 4.3.1 since yesterday and now I am stuck at the following error. Will appreciate any help on this.
> I am using the below:
> - OS: Ubuntu 16.04 in my home laptop.
> - Java: Oracle JDK 1.8.0_u91
> - Glassfish: 4.1.1
> - PostgreSQL: 9.5.3
> - JQ: jq-1.4
> - Solr: solr-4.6.1
> - Datavere 4.3.1
>
> After installing dataverse 4.3.1 using the ./install from dvinstall i get an impression that everything went okay but when i open http://localhost:8080 I get the below error:
>
> HTTP Status 500 - Internal Server Error
>
> type Exception report
>
> messageInternal Server Error
>
> descriptionThe server encountered an internal error that prevented it from fulfilling this request.
>
> exception
>
> javax.servlet.ServletException
> root cause
>
> javax.ejb.EJBException
> root cause
>
> javax.persistence.NoResultException: getSingleResult() did not retrieve any entities.
> note The full stack traces of the exception and its root causes are available in the GlassFish Server Open Source Edition 4.1.1 logs.
>
> GlassFish Server Open Source Edition 4.1.1
>
>
>
> I was suspecting postgresql settings being an issue (this is the first time I am using postgresql). So I had set the below in /etc/postgresql/9.5/main/pg_hba.conf:
> # Database administrative login by Unix domain socket
> local all postgres trust
>
> # TYPE DATABASE USER ADDRESS METHOD
>
> # "local" is for Unix domain socket connections only
> local all all trust
> # IPv4 local connections:
> host all all 127.0.0.1/32 trust
>
> I will really appreciate any help on this.
>
> Many thanks,
> Sourav Gupta.
>
> --
> You received this message because you are subscribed to the Google Groups "Dataverse Users Community" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-commu...@googlegroups.com.
> To post to this group, send email to dataverse...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/dataverse-community/ff9ef0dc-ca78-4308-a170-013ef9e5f992%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
> <server.log><dataverse-installation-log>

signature.asc

Tim DiLauro

unread,
May 31, 2016, 9:31:56 AM5/31/16
to dataverse...@googlegroups.com

> On May 31, 2016, at 9:07 AM, Philip Durbin <philip...@harvard.edu> wrote:
>
> Hi Sourav,
>
> The error "javax.persistence.NoResultException: getSingleResult() did not retrieve any entities." is an indication that the root dataverse was not created. In a previous thread* the problem was that `jq` was not installed but it seems like you have jq installed and I assume it's executable. In the other thread some output from the "install" script was provided which was extremely useful in troubleshooting the problem. If you could provide this output, I'd really appreciate it.
>

<snip />

> Phil
>
> p.s. Since we get this question from time to time it sounds like we should probably update http://guides.dataverse.org/en/4.3.1/installation/installation-main.html#troubleshooting . The source for this page is at https://github.com/IQSS/dataverse/blob/develop/doc/sphinx-guides/source/installation/installation-main.rst . I just added this to our todo list at https://github.com/IQSS/dataverse/issues/2944

Hi Phil,

It would be good to catch this exception in DataverseServiceBean.findRootDataverse() or in one of its upstream java and JSF callers and produce a helpful error message indicating that the installation may not have completed successfully.

Cheers,
~Tim
signature.asc

Philip Durbin

unread,
May 31, 2016, 12:10:36 PM5/31/16
to dataverse...@googlegroups.com
Good idea. Thanks for creating https://github.com/IQSS/dataverse/issues/3148 , Tim!

--
You received this message because you are subscribed to the Google Groups "Dataverse Users Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-commu...@googlegroups.com.
To post to this group, send email to dataverse...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Sourav Gupta

unread,
May 31, 2016, 2:05:11 PM5/31/16
to Dataverse Users Community, philip...@harvard.edu
Hi Phil & Tim,

First of all thanks a lot for responding to this so promptly. I really appreciate your time and help!

Apologies that I did not mention that
 1. I had seen the previous post which was very similar to mine who had problems with JQ and I verified that before posting this.
 2. I had also uploaded the ./install script execution output and the glassfisn domain1 logs in the original post. I am attaching both again for easy reference - please refer to these attachments only. I tried 3-4 times and forgot to clean up server logs. Am uploading all of them in case that gives any clue. And hope it is not too much of a burden.

Thanks again!

Many thanks,
Sourav
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-community+unsub...@googlegroups.com.

To post to this group, send email to dataverse...@googlegroups.com.
dataverse-installation-log.log
glassfish-domain-logs.tar.gz

Philip Durbin

unread,
May 31, 2016, 2:21:33 PM5/31/16
to dataverse...@googlegroups.com
D'oh! Sorry for not noticing you had attached those files! They're helpful but the file I *really* need should be called something like setup-all.sh.1234.log where 1234 is some arbitrary number. This file will contain all the output from setup-all.sh (a bunch of curl commands) and will help us diagnose what's going wrong. Please send it along. Thanks!

To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-commu...@googlegroups.com.
To post to this group, send email to dataverse...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Dataverse Users Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-commu...@googlegroups.com.

To post to this group, send email to dataverse...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Philip Durbin

unread,
Jun 1, 2016, 7:55:15 AM6/1/16
to dataverse...@googlegroups.com
Sourav, were you able to find that log file? At least for me (running under Vagrant) it was saved to scripts/api/setup-all.sh.8212.log but again, the number will vary (it's the process id of the script). Hopefully it will give us some insight. I'm not sure where the file will be saved for you.

Sourav Gupta

unread,
Jun 1, 2016, 10:28:43 AM6/1/16
to Dataverse Users Community, philip...@harvard.edu
Hi Phil,

Please find attached the setup-logs for all 3 runs. I also checked the database and saw that there are no records in the dataverse table indicating that the data did not get inserted. I also had a quick glance to these setup logs and could see that there are a number of errors although I am not able to trace them to their root causes.

Thank you for all your help so far on this!

Many thanks,
Sourav
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-community+unsub...@googlegroups.com.
To post to this group, send email to dataverse...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Dataverse Users Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-community+unsub...@googlegroups.com.

To post to this group, send email to dataverse...@googlegroups.com.

Sourav Gupta

unread,
Jun 1, 2016, 10:30:29 AM6/1/16
to Dataverse Users Community, philip...@harvard.edu
Sorry, missed the attachment in my last post...
setup-all-logs.tar.gz

Kraffmiller, Stephen E

unread,
Jun 1, 2016, 3:17:23 PM6/1/16
to dataverse...@googlegroups.com, gkso...@gmail.com, Durbin, Philip
This may be due to using Glassfish 4.1.1 - We’ve had an issue with using it and on;y support the use of Glassfish 4.0


Kraffmiller, Stephen E

unread,
Jun 1, 2016, 3:31:24 PM6/1/16
to dataverse...@googlegroups.com, gkso...@gmail.com, Durbin, Philip
Sorry - typo. 

You should be using Glassfish 4.1



Philip Durbin

unread,
Jun 1, 2016, 3:51:27 PM6/1/16
to dataverse...@googlegroups.com, gkso...@gmail.com
Steve's right (thanks!). The problem must be Glassfish 4.1.1. Please try Glassfish 4.1 instead as we advise at http://guides.dataverse.org/en/4.3.1/installation/prerequisites.html#glassfish at please let us know if it works.

Thanks,

Phil

p.s. I just checked the glassfish-4.1.1-server.log.txt file I uploaded to https://github.com/IQSS/dataverse/issues/2628#issuecomment-158197478 and it does seem to be the same problem.





For more options, visit https://groups.google.com/d/optout.

Sourav Gupta

unread,
Jun 1, 2016, 10:34:59 PM6/1/16
to Dataverse Users Community, gkso...@gmail.com, philip...@harvard.edu
Thank you Steve & Phil. I will try with Glassfish 4.1 and let you know the outcome.
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-community+unsub...@googlegroups.com.
To post to this group, send email to dataverse...@googlegroups.com.



-- 

-- 
You received this message because you are subscribed to the Google Groups "Dataverse Users Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-community+unsub...@googlegroups.com.

To post to this group, send email to dataverse...@googlegroups.com.



-- 



-- 

-- 
You received this message because you are subscribed to the Google Groups "Dataverse Users Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-community+unsub...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Dataverse Users Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-community+unsub...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Dataverse Users Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-community+unsub...@googlegroups.com.

To post to this group, send email to dataverse...@googlegroups.com.

Sourav Gupta

unread,
Jun 1, 2016, 11:21:49 PM6/1/16
to Dataverse Users Community, gkso...@gmail.com, philip...@harvard.edu
Success! After changing Glassfish to 4.1 it seem to have worked fine. I am not able to see the dashboard at localhost:8080. Clicked through a few links including creating a new dataverse & a dataset and all worked without any problems.
Any other checks I should do before I can confirm that everything is set up?

Also, you may want to claim that your installation script works on Ubuntu 16.04!

Many thanks for all your time and support on this. Really appreciate!

Many thanks,
Sourav Gupta
Reply all
Reply to author
Forward
0 new messages