I am endeavouring to run the Program Patient State Report (but the problem is general) and am always redirected to this screen:
I guessed that as a user I am short of some privilege and so I have given superman all roles and for the role Reports-app have given all privileges. I hope the 2 images below confirm this.
The wiki describes a method of adding the reports app to the bahmni dashboard which has already been done in the distro for the vagrant box and I have no problems in gaining access to the reports menu, but when I run the report (now) I get sent back to the logon screen as above.
Queuing the report produces a further but different error condition which I am currently researching.
.
I am making some small progress but I would really appreciate some help here as the inability to run reports invalidates all the good work Bahmni is demonstrating in collecting data.
Progess: It seems that the distro that I have did not have a bahmni_config/i18n/reports/locale_en.json and so I “borrowed” the version from bahmniapps.
The google chrome console shows “undefined” against https://192.168.8.202:8082/bahmni/reports/reports.min.9ea83dee.js each time I click “Run Now”. The rather large js file clearly exists and so I guess there is some undefined variable being referenced from within. I have stopped openmrs, created a new openmrs.log restarted openmrs and clicked “Run Now” on 3 occasions with about 1 min separation. The log contains a number of errors, but I am unable to separate those that relate to the absence of openelis from those relating to this problem.
Hi @mafrica,
Apologies for not being good help. Can you please answer the below questions?
Which version of Bahmni?
From where did you follow the deployment steps? Did you get to redeploy Bahmni just to ensure that the installation steps were not missed.
Can you stop openmrs service -> remove /opt/openmrs/.openmrs-lib-cache i.e “rm -rf /opt/openmrs/.openmrs-lib-cache” and “rm -rf /opt/openmrs/run/work” and -> start openmrs -> and tell us any difference you see.
Rebuild Search index from OpenMRS -> Administration -> Search Index under Maintenance section
Please let us know any observations.[quote=“mafrica, post:1, topic:11337”]
I am endeavouring to run the Program Patient State Report (but the problem is general) and am always redirected to this screen:
[/quote]
The file remove instructions caused at permanent bout of You are not authenticated or your session expired. Please login ie I in response to all login attempts with all user ids and passwords.
Vagrant Reload put things back to normal.
I am afraid the index rebuild made no difference to behaviour.
Here is the log…I am sorry I did not know there was a special log for reports. Anyway I have just repeated the report request (dated 3/6/17) and there is no indication of a problem in the log. However, scrolling back there are a number of warnings which I am afraid I do understand.
reportslog.txt (268.5 KB)
I am afraid that as a poor implementer this is well beyond my competence.
However, my reading is that these problems are cased by some sort of network transient between system (Vagrant?) startup and the report request. However, it seems curious that all the other database accesses seem to work fine.
Anyway as a small test I deleted bahmni-reports.log and reloaded vagrant and immediately tried the reporting function with failed in the same way.
Here is the much reduced log file. Note the reports was requested at c. 09.40 with no specific error message.
newreportslog.txt (4.3 KB)
When I fired up Vagrant I was told that an upgrade to 0.89 was available and so I have applied the upgrade which I guess would include a reload of bahmni-reports? I check bahmni-reports status and get Service bahmni-reports is running with pid: 1534.
Running the reports then produced the same failure. The log seems to show more of these
2017-06-05 06:20:08,564 WARN [bahmnireports][com.mchange.v2.c3p0.impl.NewPooledConnection] [c3p0] A PooledConnection that has already signalled a Connection error is still in use!
2017-06-05 06:20:08,570 WARN [bahmnireports][com.mchange.v2.c3p0.impl.NewPooledConnection] [c3p0] Another error has occurred [ com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: No operations allowed after connection closed. ] which will not be reported to listeners!
com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: No operations allowed after connection closed.
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:411)
at com.mysql.jdbc.Util.getInstance(Util.java:386)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1015)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:989)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:975)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:920)
at com.mysql.jdbc.ConnectionImpl.throwConnectionClosedException(ConnectionImpl.java:1304)
at com.mysql.jdbc.ConnectionImpl.checkClosed(ConnectionImpl.java:1296)
at com.mysql.jdbc.ConnectionImpl.rollback(ConnectionImpl.java:5028)
at com.mchange.v2.c3p0.impl.NewProxyConnection.rollback(NewProxyConnection.java:855)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.quartz.impl.jdbcjobstore.AttributeRestoringConnectionInvocationHandler.invoke(AttributeRestoringConnectionInvocationHandler.java:73)
at com.sun.proxy.$Proxy32.rollback(Unknown Source)
at org.quartz.impl.jdbcjobstore.JobStoreSupport.rollbackConnection(JobStoreSupport.java:3666)
at org.quartz.impl.jdbcjobstore.JobStoreSupport.executeInNonManagedTXLock(JobStoreSupport.java:3825)
at org.quartz.impl.jdbcjobstore.JobStoreSupport.acquireNextTriggers(JobStoreSupport.java:2756)
at org.quartz.core.QuartzSchedulerThread.run(QuartzSchedulerThread.java:272)
Caused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
I am afraid I am way out of my depth in analyzing this, but is it possible that the Vagrant Box does not like the port that bahmni-reports is trying to use?