Ошибка mod_lsapi mysql
Форум
  1. Forums
  2. General
  3. General Discussion
  1. kernow
  2. Thursday, 17 July 2014
  3.  Subscribe via email
Hi,
Just installed mod_lsapi on cpanel server, install went OK but found websites running wordpress get this error:
Your PHP installation appears to be missing the MySQL extension which is required by WordPress.
uninstalling mod_lsapi and all now OK. Any suggestions please to what went wrong?
Rate this post:
  1. 18.07.2014 06:07:11
  2. # 1
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
I presume you enabled mysql in php selctor ?
  1. 18.07.2014 06:07:49
  2. # 2
kernow Accepted Answer
Posts: 72
Joined: 06.08.2010
0
Votes
Undo
Hi,
Its enabled by default. ( native 5.4)  If it wasn't enabled mysql wouldn't  be working would it.
  1. 18.07.2014 07:07:45
  2. # 3
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
1. we don\'t use native PHP in mod_lsapi --> as it doesn\'t have lsphp build, and we don\'t rebuild it.
2. mysql is not working for lsphp from what I can see from this message: \"Your PHP installation appears to be missing the MySQL extension which is required by WordPress.\"
So, yes... please, check if you have MySQL enabled in PHP selector.
  1. 18.07.2014 07:07:28
  2. # 4
kernow Accepted Answer
Posts: 72
Joined: 06.08.2010
0
Votes
Undo
In the php selector Mysql is only listed in the native 5.4 version, in other versions its not even listed.  This is the instructions we followed ( cagefs already running)
yum install liblsapi liblsapi-devel --enablerepo=cloudlinux-updates-testing
$ yum install cpanel-mod-lsapi --enablerepo=cloudlinux-updates-testing
 
 $ /usr/bin/switch_mod_lsapi --setup
$  /usr/bin/switch_mod_lsapi --enable-global
$ service httpd restart
  1. 18.07.2014 07:07:11
  2. # 5
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
Have you installed alt-php ?

[url]http://docs.cloudlinux.com/index.html?installation.html[/url]
  1. 18.07.2014 07:07:25
  2. # 6
Alexey Berezhok Accepted Answer
Posts: 35
Joined: 20.04.2010
0
Votes
Undo
Hello,

native lsphp for cPanel is copied lsphp 5.4 binary from php selector:

/usr/local/bin/lsphp -i | grep php.ini
Configuration File (php.ini) Path => /opt/alt/php54/etc
Loaded Configuration File => /opt/alt/php54/etc/php.ini

And it used as non full functional php without extensions (because cPanel haven\'t yet lsphp built by default). You should switch php for user in php selector and enable needed extensions for it.
  1. 18.07.2014 07:07:14
  2. # 7
Alexey Berezhok Accepted Answer
Posts: 35
Joined: 20.04.2010
0
Votes
Undo
Hello,

can you send us screenshot of php selector web page for this user? You can create ticket here http://helpdesk.cloudlinux.com/ with screenshots.
  1. 18.07.2014 07:07:55
  2. # 8
kernow Accepted Answer
Posts: 72
Joined: 06.08.2010
0
Votes
Undo
Ah! it seems alp-php was not installed.
Thanks.
  1. 18.07.2014 10:07:54
  2. # 9
kernow Accepted Answer
Posts: 72
Joined: 06.08.2010
0
Votes
Undo
Hi,
OK installed now and mysql is available to select in other php versions. Questions:
On install we choose /usr/bin/switch_mod_lsapi --enable-global do we still have to visit each clients cpanel and select the php version to use mod_lsapi ?
Where is mod_lsapi listed?  its  not in any php version module selector.
In the docs section is an example config file, where is this file or what file is it added to?
Comand  to check this mod is running /status?
  1. 18.07.2014 10:07:32
  2. # 10
Alexey Berezhok Accepted Answer
Posts: 35
Joined: 20.04.2010
0
Votes
Undo
Hello,

1) if you switch on mod_lsapi global, all clients automatically works with mod_lsapi after apache restart

2) mod_lsapi not integrated in cPanel web interface yet. You can check it by command: /usr/local/apache/bin/httpd -M | grep lsapi

3) for cPanel this file is - /usr/local/apache/conf/conf.d/lsapi.conf

4) to check that module running for site, make simple php script (test.php):
phpinfo();
check it via browser and should be string in output:

Server API     LiteSpeed V6.6
  1. 18.07.2014 11:07:16
  2. # 11
kernow Accepted Answer
Posts: 72
Joined: 06.08.2010
0
Votes
Undo
Excellent! all working OK.
Thanks for your time and help.
Regards.
  1. 04.08.2015 11:08:38
  2. # 12
Budd Grant Accepted Answer
Posts: 1
Joined: 04.08.2015
0
Votes
Undo
I ran into this issue today as well.  I was going to say that it should say that Alt-PHP is required in order to run this successfully but it is already in the documentation. :) Great work guys keep it up.
  • Page :
  • 1


There are no replies made for this post yet.
Be one of the first to reply to this post!
гость
Submit Your Response
Upload files or images for this discussion by clicking on the upload button below. Supports gif,jpg,png,zip,rar,pdf
• Insert • Remove Upload Files (Maximum File Size: 2 MB)
Captcha
To protect the site from bots and unauthorized scripts, we require that you enter the captcha codes below before posting your question.