Blank screen on first start of OpenEMR 5.0.2

It wasn’t a patch that broke my install, in fact as far as I know my install is not broken, the backup or restore process is broken.

The problem is that the backup produced by the docker installation of one computer does not work properly on a regular installation on another computer (same version of openemr).

That is, I make a backup on my docker installation on computer 1. I want to put that data onto my regular openemr installation on computer 2. I run the restore script. The script tells me that it has concluded successfully.

But when I navigate either to localhost or localhost/openemr, I cannot see the openemr login screen.

This is what I have written in my preceding posts.

The database is mysql 5.7

I see, I had not understood what the problem was.
What is the file extension of the backup?
If you are moving a file, could you be putting it in the incorrect directory?

emr_backup.tar

I am not moving any files. I am simply running the backup script.

Yes, I get it, I wonder if it is a permissions problem check out your file system. Make sure the script untared everything in the correct place and then placed the permissions corrrectly.
Alternatively you can go into the file system yourself. that must be the problem.

Yes, check out the error:

“Fatal error: require_once(): Failed opening required ‘sites/default/sqlconf.php’ (include_path=’.:/u…”

It says “failed opening”
your may need to get in there and change your permissions.
Do you know how to do that?
If that fixes the problem, then we can tell those guys that wrote the script that it has that problem.

Get in where, exactly?

And change the permissions of what to what?

I’m afraid this is going over my head. Unless I can get precise troubleshooting steps, I am lost.

So, it looks like the script makes an archive of the complete openemr web directory then replaces the one you had at the new location.
You wold need to go to the web directory of the new second installation and be sure that your user and permissions are correct.
Particularly for the sqlconf.php file.

Here are the permissions that I found:

/var/www/openemr : owner and group are root, read and write access
/var/www/openemr/sites : owner and group are root, read and write access
/var/www/openemr/sites/default : owner is Robert, group is root, no access
/var/www/openemr/sites/default/sqlconf.php : owner is Robert, group is root, no access

I changed ‘default’ and ‘sql.php’ to read and write access, but this has made no difference.

you need to make sure your whole openemr directory has the correct user:group and permissions. That is what I mean. It should be accesible by the server not Robert and not root. For example. I run FreeBSD. In my case, it should be www. I know some Linux systems use data or something like that. I am not sure.

I am afraid I do not know what the permissions should be, and have not been able to find out. Maybe somebody here can tell me?

Of course, which is your platform? which server do you use? Which webserver?
I understand you are using linux, correct? Try these:

# cd /var/www
# chown -R www:www openemr

If you are using a non root user, add sudo in the beginning like so:

# sudo cd /var/www
# sudo chown -R www:www openemr

Sandra

Linux Mint 19.1.
Apache 2.
Not quite sure what is meant by ‘webserver’ here. My computers are not connected to any kind of network.

robert@robert-ideacentre-AIO-520-22IKU:~$ sudo cd /var/www
[sudo] password for robert:       
sudo: cd: command not found
robert@robert-ideacentre-AIO-520-22IKU:~$ cd /var/www
robert@robert-ideacentre-AIO-520-22IKU:/var/www$ sudo chown -R www:www openemr
chown: invalid user: ‘www:www’

Your webserver is apache 2. Apache 24 is probably better.

“www:www” is the user:group combo for apache in FreeBSD. You need to replace that with the equivalent in Linux Mint…
Looks like these are your commands:

cd /var/www
sudo chown -R www-data:www-data openemr

Check this out:

https://community.linuxmint.com/tutorial/view/1288

For some reason I am not seeing your messages in a timely fashion. It might be better if you email me. This forum has the ability to send email. I will try to figure it out.

I would think you should see the index.html of apache welcome page @ localhost at least?

What caught my attention in this thread on may 12 Brady pointed you to use localhost and not localhost/openemr to reach the log-in page….
In your computer 2 that runs regular installation of openemr you reach it localhost/openemr, and computer 1 that runs docker installation you reach your log-in page localhost …so they are different in the way the folder of openemr is placed, MAY BE when you restore computer 2 from files in 1 it throws it off when it over writes it with the script and you cannot reach the log-in page nor the apache welcome page.
I could be wrong but it is a thought I had when I saw that the docker installation was reached at localhost rather than localhost/openemr.
In my installation localhost leads me to the apache’s welcome page index.html
localhost/openemr leads me to the log-in page.
Just a thought…

That is correct, I do see the index.html of apache welcome page @ localhost.

With regard to the permissions, I do not think that is correct. I have an old backup from a regular installation of openemr that was on computer 1 before the OS upgrade prompted me to use the docker installation. This backup works on computer 2. The permissions are ‘root’.

As mentioned above, I have an old backup from a regular installation of openemr that was on computer 1 before the OS upgrade prompted me to use the docker installation. In this old backup, which worked, in sqlconf.php, I find this:

$host = ‘localhost’;
$port = ‘3306’;
$login = ‘openemr’;
$pass = ‘AnAlphanumericalPassword’;
$dbase = ‘openemr’;

Whereas, in the docker backup, I find this:

$host = ‘mysql’;
$port = ‘3306’;
$login = ‘openemr’;
$pass = ‘openemr’;
$dbase = ‘openemr’;

However, changing the latter to the former in my installation makes no difference to the blank screen problem.

try setting
display_errors=Off
to
display_errors=On
in php.ini
this way you will see errors displayed in your screen

When you get a blank screen, what is in the address bar?

display_errors in php.ini was already set to “On”

With the blank screen ‘localhost/openemr’ is in the address bar.

I have just found out that the blank screen is only with Firefox. In Chrome I get “This page isn’t working
localhost is currently unable to handle this request. HTTP ERROR 500”.