hy…
My bahmni is not loading.It is still loading but home page is not coming…
Openmrs is showing an error “openmrs is not able to start”…
Can anyone know what is this error means and how can i solve it??
Pls find the attached photos of error logs and UI photos…
You need to upload the entire openmrs.log to pastebin or in gist for us to get a better picture.
From the look of the limited log screenshot, it seems that it can not connect to the database. Have you changed the default password in “setup.yml” during installation?
Check if mysql is up and running and check if with the specified username/password for openmrs, whether you can login to mysql.
check if mysql is up and running
service mysqld status
check the “/opt/openmrs/etc/openmrs-runtime.properties” file to see what user/password is being used.
cat /opt/openmrs/etc/openmrs-runtime.properties
try to login to openmrs database with the above username/password.
mysql -U[user] -p[password] openmrs
If the above does not work, then try to post the entire openmrs.log (through pastebin)
First delete the older logs and then start the server. the logs are rolling, so it can be that the logs are spanning across multiple files.
@angshuonline
I had checked mysql status and its running…
“cat /opt/openmrs/etc/openmrs-runtime.properties” using these comments i got the username and password and i can able to login…But show table comment is showing “command not found”…
I can able to stop openmrs using openmrs stop comment but " rm -f /var/log/openmrs/ ."is saying cant remove,its a directory…
Also im attaching entire logs…From yesterday morning only this issue is started…For last one year bahmni is using in our office and before that we didnt face an issue like this…
Pls find the attached screen shots and txt file…
Yeah… In the same machine only i was working before…
I didnt done anything or changed anything yesterday… I have taken backup on 8th march… After that also it was working properly…But from yesterday morning when someone(our staffs) tried to access bahmni,but they cant able to access… Day before yesterday evng also they were working on it…
Sry for the previous wrong message… Actualy using “mysql -u(username) -p(password) openmrs” i can able to enter and there its showing only information_schema database on show database comment…openmrs db is not there…
I am assuming that you logged in as “openmrs-user”. If the user does not have access to the database, the list will show only “information_schema”.
login using root
mysql -uroot -p(password) openmrs
show databases;
If you do not still see “openmrs” database in the above query result, then there can be at least 2 reasons
mysql data directory points to a different place. to check
vi /etc/my.cnf
alternatively, you can also login to mysql prompt and check the datadir variable
show variables where Variable_name = “datadir”;
check where the data directory points to against the “datadir”, by default it would be something like
datadir=/var/lib/mysql
navigate to the datadir, mentioned above and check if there are top level directories representing databases
ls -al (datadir)/
you should have top level directories like “openmrs”, “bahmni_reports” etc in the “datadir”. if you don’t find “openmrs” directory there, then you have a problem - meaning somehow the “datadir” was either “changed” or got “replaced”.
if the “datadir” is different, then check in the default location “/var/lib/mysql”, if you find the top level directories like “openmrs” etc there, then go and edit the “/etc/my.cnf” file and change the “datadir” to point to the right place.
Btw, I am assuming you are doing this on a physical machine and not on vagrant or docker.
You should check the OS logs to find out who and when the files were deleted
I am seriously hoping that you had configured either automated backup or at least take regular backup. If so, then try restoring the last backup. If you had active/passive machine setup, then hopefully, you can activate the passive.
I am facing the same problem as Mithun. I was able to follow the steps you mentioned. i was able to access the database openmrs. what should i do next.
I am facing the same problem as Mithun. I was able to follow the steps you mentioned. i was able to access the database openmrs. what should i do next.