Openemr-3.2.0 - Connecting to MySQL Server

schneidz15 wrote on Sunday, March 27, 2011:

hi,  i am trying to run open-emr using these instructions:
http://www.openmedsoftware.org/wiki/OpenEMR_3.2_Linux_Installation

i get as far as step 3 where this screen never seems to connect to mysql:

OpenEMR Setup

Step 3

Configuring OpenEMR…

Connecting to MySQL Server…

i think i have everything installed:

[liveuser@localhost html]$ rpm -q mysql-server php httpd
mysql-server-5.1.55-1.fc14.x86_64
php-5.3.5-1.fc14.x86_64
httpd-2.2.16-1.fc14.x86_64
[liveuser@localhost ~]$ uname -a -m -p
Linux localhost.localdomain 2.6.35.6-45.fc14.x86_64 #1 SMP Mon Oct 18 23:57:44 UTC 2010 x86_64 x86_64 x86_64 GNU/Linux

is there something i am supposed to do to bind apache to mysql or something.

thanks,
schneidz

schneidz15 wrote on Sunday, March 27, 2011:

also:
hi,  i am trying to run open-emr using these instructions:
http://www.openmedsoftware.org/wiki/OpenEMR_3.2_Linux_Installation

i get as far as step 3 where this screen never seems to connect to mysql:

OpenEMR Setup

Step 3

Configuring OpenEMR…

Connecting to MySQL Server…

i think i have everything installed:

[liveuser@localhost html]$ rpm -q mysql-server php httpd
mysql-server-5.1.55-1.fc14.x86_64
php-5.3.5-1.fc14.x86_64
httpd-2.2.16-1.fc14.x86_64
[liveuser@localhost ~]$ uname -a -m -p
Linux localhost.localdomain 2.6.35.6-45.fc14.x86_64 #1 SMP Mon Oct 18 23:57:44 UTC 2010 x86_64 x86_64 x86_64 GNU/Linux

is there something i am supposed to do to bind apache to mysql or something.

thanks,
schneidz

schneidz15 wrote on Sunday, March 27, 2011:

sorry, i cant figure out how to edit posts:

$ sudo service mysqld status
mysqld (pid 4428) is running…
$ sudo service httpd status
httpd (pid  3316) is running…
$ mysql
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 11
Server version: 5.1.55 Source distribution

Copyright © 2000, 2010, Oracle and/or its affiliates. All rights reserved.
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL v2 license

Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the current input statement.

mysql> use test
Database changed
mysql> \s

mysql  Ver 14.14 Distrib 5.1.55, for redhat-linux-gnu (x86_64) using readline 5.1

Connection id: 11
Current database: test
Current user: liveuser@localhost
SSL: Not in use
Current pager: stdout
Using outfile: ‘’
Using delimiter: ;
Server version: 5.1.55 Source distribution
Protocol version: 10
Connection: Localhost via UNIX socket
Server characterset: latin1
Db     characterset: latin1
Client characterset: latin1
Conn.  characterset: latin1
UNIX socket: /var/lib/mysql/mysql.sock
Uptime: 1 hour 3 min 33 sec

Threads: 1  Questions: 67  Slow queries: 0  Opens: 30  Flush tables: 1  Open tables: 23  Queries per second avg: 0.17

thanks,

schneidz15 wrote on Sunday, March 27, 2011:

i see this in the logs:

[liveuser@localhost html]$ sudo tail -f /var/log/httpd/error_log
[Sat Mar 26 23:08:09 2011] [error] [client 127.0.0.1] PHP Fatal error:  Call to undefined function mysql_connect() in /var/www/html/openemr/setup.php on line 237, referer: http://localhost/openemr/setup.php

i dont know how to correct it… any advice ?

schneidz15 wrote on Sunday, March 27, 2011:

this was the solution:

sudo yum install php-mysql
sudo service mysqld restart
sudo service httpd restart

marka1211 wrote on Sunday, March 27, 2011:

I ran across this issue, too.  I had an old mysql installation, which I purged and reinstalled in order to test with OpenEMR.  I used a “dpkg -l php*” command which showed php-mysql as being uninstalled.

As you point out, this problem shows up as a mysterious “hang” during the installation script.  Is there a way to make this fail with more info as to the cause?  It’s not too hard to figure out, but there could be others being bothered by this.