MRatWork Forum by Mustafa Ramadhan

Sawo Project - Kloxo-MR Discussions => Kloxo-MR Technical Helps => Topic started by: suplover on 2013-08-08, 19:59:47

Title: lxphp.exe: command not found
Post by: suplover on 2013-08-08, 19:59:47
I was having some problems with dns and webserver while i try to fix it i tried a few things but after i run "yum update"

/script/cleanup command give me "-bash: /script/cleanup: Permission denied"

and then i run sh /script/upcp and reboot but now /script/cleanup command gives me "line 14: lxphp.exe: command not found"

What should i do? Thanks.
Title: Re: lxphp.exe: command not found
Post by: chrisf on 2013-08-08, 20:37:12
First be sure you updated to newest MR repo.
Code: [Select]
cd /etc/yum.repos.d/
rm kloxo-mr.repo
wget https://raw.github.com/mustafaramadhan/kloxo/release/kloxo-mr.repo

Then just to be safe:
Code: [Select]
yum update
yum remove lxphp
yum install php52s
sh /script/cleanup
sh /script/restart-all

If you get an error like no lxphp package installed that is ok. :)

That will fix everything :)
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-08, 21:01:25
Don't install lxphp but php52s.

It's look like your Kloxo-MR not latest version. So, need update.
Title: Re: lxphp.exe: command not found
Post by: chrisf on 2013-08-08, 21:04:06
Thats what I said :)
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-08, 21:13:48
Quote from: "MRatWork"
Don't install lxphp but php52s.

It's look like your Kloxo-MR not latest version. So, need update.

I just did what Christopher said and kloxo works again (thanks for that) now but still have problem with webserver

Current Kloxo Version:   6.5.0.f-2013080701
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-08, 21:25:54
Look like you have custom files inside /home/<driver>/tpl. You need modified custom files. Different from previous, latest upload use socket rather then ip-port based for php-fpm.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-08, 21:59:28
Quote from: "MRatWork"
Look like you have custom files inside /home/<driver>/tpl. You need modified custom files. Different from previous, latest upload use socket rather then ip-port based for php-fpm.

sorry i confused a little bit now but as i remember i modified only this file
'/etc/sysconfig/network-scripts/ifcfg-eth0'

and i think now i have a progress, i see 502 Bad Gateway, nginx/1.5.2
Title: Re: lxphp.exe: command not found
Post by: chrisf on 2013-08-08, 22:02:19
If you have custom. tpl files you will need to update them accordingly.  If you have no idea what we are talking about :) you don't have them.

If not try this:  Kloxo panel.  Switch Programs.  Change Webserver to a different webserver.  Wait for it to update properly.  Switch back to your webserver.  Update.

So: if use apache: try
nginx then back to apache.

This old trick sometimes fixes problems :)
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-08, 22:07:58
Quote from: "chrisf"
If you have custom. tpl files you will need to update them accordingly.  If you have no idea what we are talking about :) you don't have them.

If not try this:  Kloxo panel.  Switch Programs.  Change Webserver to a different webserver.  Wait for it to update properly.  Switch back to your webserver.  Update.

So: if use apache: try
nginx then back to apache.

This old trick sometimes fixes problems :)

Yes mine was "i have no idea" :) now i'm playing with those settings as you suggest thanks
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-08, 22:25:15
Ok i tried nginx then back to apache also reverse and different Php Branch and i also run sh /script/fixweb and sh /script/restart-all  to be sure but still same
Title: Re: lxphp.exe: command not found
Post by: chrisf on 2013-08-08, 23:56:30
Try looking here please:

www.nginxtips.com/502-bad-gateway-using-nginx/ (http://www.nginxtips.com/502-bad-gateway-using-nginx/)

Let me know if any of that helps.
Title: Re: lxphp.exe: command not found
Post by: chrisf on 2013-08-09, 00:01:24
Does apache run?  Try suphp.  Does any other combination work?

I am not familiar with nginx.  But it appears to be a php-fpm issue.  Try running straight apache.

If nothing.  Try apache / suphp.  Be sure to click fix all permissions at bottom of webconfig area.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-09, 00:17:49
Quote from: "chrisf"
Does apache run?  Try suphp.  Does any other combination work?

I am not familiar with nginx.  But it appears to be a php-fpm issue.  Try running straight apache.

If nothing.  Try apache / suphp.  Be sure to click fix all permissions at bottom of webconfig area.

before i was using nginx but i can use apache too no problem just both doesn't work. I set apache and then when i try to set suphp it says " httpd_restart_failed" and remain as it is.
Title: Re: lxphp.exe: command not found
Post by: chrisf on 2013-08-09, 01:15:50
What does the error logs say?  Mustafa WILL know better than me since he has ran into many problems and solved them!

Interesting that appache won't start.  Sounds like a conf problem.

Was this a fresh install or upgrade?
Title: Re: lxphp.exe: command not found
Post by: djscooby on 2013-08-09, 01:27:05
I have the same problem with nginx but apache runs fine... Already tried all the known solutions.. nginx wont work...
Title: Re: lxphp.exe: command not found
Post by: djscooby on 2013-08-09, 01:56:49
nginx error.log :
Code: [Select]
2013/08/08 22:40:44 [emerg] 448#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to [::]:80 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to 0.0.0.0:443 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to [::]:443 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to [::]:80 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to 0.0.0.0:443 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to [::]:443 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to [::]:80 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to 0.0.0.0:443 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to [::]:443 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to [::]:80 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to 0.0.0.0:443 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to [::]:443 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to [::]:80 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to 0.0.0.0:443 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: bind() to [::]:443 failed (98: Address already in use)
2013/08/08 22:40:44 [emerg] 448#0: still could not bind()

Then saw that httpd was still running !
So i restarted the server and just in case i did
Code: [Select]
service httpd status
httpd is stopped <--correct now

sh script/fixweb
service php-fpm restart
service nginx restart

Then it seems from error log that nginx was running (*but only when i acessed from browser [ip adress]:80)
here is the log output:
Code: [Select]
2013/08/08 22:43:14 [warn] 551#0: *36 using uninitialized "rootdir" variable, client: 208.xx.x.xxxx, server: _, request: "GET /apple-touch-icon.png HTTP/1.1", host: "xxxx.xxxxxxx.info"

But when i access a domain then nothing on the log and still 502 error on browser...


Any idea ?
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-09, 10:54:12
Depend on using apache, nginx or nginx-proxy (nginx as frontend and apache in backed).

Frontend (also apache and nginx alone) using port 80 and backend using port 30080. If you found issue for port conflict it's maybe this port try to use by more then 1 applications.

Another issue, Kloxo-MR using 'special' /etc/httpd/conf/httpd.conf and /etc/nginx/nginx.conf where taken from /home/apache/etc/conf and /home/nginx/etc/conf.  Running /script/cleanup will be fix this issue. If still not fixed after, need reboot or stop apache and or nginx manually with 'service httpd stop' and 'service nginx stop' before running 'sh /script/restart-services'.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-09, 12:12:04
on me it was like this;

Code: [Select]
# service httpd status
httpd: unrecognized service

then i run

Code: [Select]
yum update
yum install httpd nginx

switched between nginx and apache and run

Code: [Select]
sh /script/fix-chownchmod
script/cleanup
sh /script/restart-all

now i again  have same;
Code: [Select]
# service httpd status
httpd: unrecognized service
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-09, 12:48:44
Inform here 'cat /usr/local/lxlabs/kloxo/etc/slavedb/driver'
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-09, 13:04:00
Quote from: "MRatWork"
Inform here 'cat /usr/local/lxlabs/kloxo/etc/slavedb/driver'

Code: [Select]
# cat /usr/local/lxlabs/kloxo/etc/slavedb/driver
O:6:"Remote":1:{s:4:"data";a:4:{s:3:"web";s:6:"apache";s:3:"dns";s:4:"bind";s:4:"spam";s:12:"spamassassin";s:7:"pserver";s:9:"localhost";}}[root@simonov ~]#
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-09, 13:07:52
So, you see that.

Your setting using apache/httpd as web server. Install/reinstall httpd and nginx and then running clean will be remove nginx and update httpd config.

That it.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-09, 13:46:44
Quote from: "MRatWork"
So, you see that.

Your setting using apache/httpd as web server. Install/reinstall httpd and nginx and then running clean will be remove nginx and update httpd config.

That it.

Ok i did

Code: [Select]
yum install httpd
yum install nginx
script/cleanup
sh /script/restart-all

and i get;

Code: [Select]
Stopping named: .                                          [  OK  ]
Starting named:                                            [  OK  ]
Stopping httpd:                                            [FAILED]
Starting httpd: httpd: Syntax error on line 63 of /etc/httpd/conf/httpd.conf: Sy                            ntax error on line 3 of /etc/httpd/conf.d/suphp52.conf: Cannot load /etc/httpd/m                            odules/mod_suphp.so into server: /etc/httpd/modules/mod_suphp.so: cannot open sh                            ared object file: No such file or directory
                                                           [FAILED]
Restarting qmail:
* Stopping qmail-smtpd.
* Sending qmail-send SIGTERM and restarting.
* Restarting qmail-smtpd.
Stopping xinetd:                                           [  OK  ]
Starting xinetd:                                           [  OK  ]
Stopping mysqld:                                           [  OK  ]
Starting mysqld:                                           [  OK  ]
Stopping kloxo-phpcgi:                                     [  OK  ]
Starting kloxo-phpcgi:                                     [  OK  ]
Stopping kloxo-hiawatha:                                   [  OK  ]
Starting kloxo-hiawatha:                                   [  OK  ]
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-09, 14:09:05
Try running 'sh /script/cleanup'.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-09, 14:30:54
Quote from: "MRatWork"
Try running 'sh /script/cleanup'.

ok this time i only get this error

Code: [Select]
cp: cannot stat `/home/kloxo/httpd/webmail/horde/scripts/sql/horde_groupware.mys                                               ql.sql': No such file or directory
sh: /home/kloxo/httpd/webmail/horde/scripts/sql/groupware.mysql.sql: No such fil                                               e or directory
cp: cannot stat `/home/kloxo/httpd/webmail/horde/config/horde_conf.php': No such                                                file or directory
cp: cannot stat `/home/kloxo/httpd/webmail/t-dah/inc/config/t-dah_config.mail.ph                                               p': No such file or directory
cp: cannot stat `/home/kloxo/httpd/webmail/t-dah/inc/config/t-dah_config.paths.p                                               hp': No such file or directory
cp: cannot stat `/home/kloxo/httpd/webmail/t-dah/inc/config/t-dah_config.php': N                                               o such file or directory

and sh /script/restart-all gives me;

Code: [Select]
Stopping httpd:                                            [FAILED]
Starting httpd: httpd: Syntax error on line 63 of /etc/httpd/conf/httpd.conf: Syntax error on line 3 of /etc/httpd/conf.d/suphp52.conf: Cannot load /etc/httpd/modules/mod_suphp.so into server: /etc/httpd/modules/mod_suphp.so: cannot open shared object file: No such file or directory
                                                           [FAILED]
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-09, 14:38:36
Horde and t-dah already remove from Kloxo-MR. delete /home/kloxo/webmail/horde and /home/kloxo/webmail/t-dah.

For httpd issue, try change to another web server (say it lighttpd) and change back to previous (say it apache or nginx-proxy) on 'switch applications'.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-09, 15:14:19
Quote from: "MRatWork"
Horde and t-dah already remove from Kloxo-MR. delete /home/kloxo/webmail/horde and /home/kloxo/webmail/t-dah.

For httpd issue, try change to another web server (say it lighttpd) and change back to previous (say it apache or nginx-proxy) on 'switch applications'.

ok i did it and then i run these commands to see if i can get back web server working but didn't helped;

Code: [Select]
sh /script/fix-chownchmod
sh /script/fixweb
sh /script/fixdns
sh /script/fixphp
sh /script/cleanup
sh /script/restart-all

and restart i get again same error;

Code: [Select]
Stopping httpd:                                            [FAILED]
Starting httpd: httpd: Syntax error on line 63 of /etc/httpd/conf/httpd.conf: Syntax error on line 3 of /etc/httpd/conf.d/suphp52.conf: Cannot load /etc/httpd/modules/mod_suphp.so into server: /etc/httpd/modules/mod_suphp.so: cannot open shared object file: No such file or directory
                                                           [FAILED]

now playing with Php Branch and Php Type
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-09, 15:16:34
Try disable secondary php. And then enable again.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-09, 15:25:42
Quote from: "MRatWork"
Try disable secondary php. And then enable again.

I don't able to disable, it says; Alert: httpd_restart_failed and remain as enabled.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-09, 15:39:00
and also don't able to change Php Type it stuck as php-fpm_event every time i try i get same alert "httpd_restart_failed" but i able to play with Php Branch
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-09, 15:51:58
Try copy /home/apache/etc/conf/httpd.conf to /etc/httpd/conf/httpd.conf. It's because because use 'modified' httpd.conf and Kloxo-MR think this 'modified' file already overwrite 'original' httpd.conf.
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-09, 15:54:01
In many situation, change to another webserver (better lighttpd) and change back to previous (apache or nginx-proxy) will be fix apache issue.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-09, 16:11:30
Quote from: "MRatWork"
In many situation, change to another webserver (better lighttpd) and change back to previous (apache or nginx-proxy) will be fix apache issue.

i try many time but unfortunately it didn't worked for me...
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-09, 16:15:01
Quote from: "MRatWork"
Try copy /home/apache/etc/conf/httpd.conf to /etc/httpd/conf/httpd.conf. It's because because use 'modified' httpd.conf and Kloxo-MR think this 'modified' file already overwrite 'original' httpd.conf.

I did it but still have issue

on sh /script/fixphp i'm getting this for every clients
Code: [Select]
PHP Fatal error:  Directive 'register_long_arrays' is no longer available in PHP in Unknown on line 0
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-09, 17:21:38
Look like your php.ini still using from php 5.2 where in your server using php 5.3/5.4.

I don't know what happens until you found this situation. Usually run 'sh /script/fixweb' will be fixed web server, php.ini and php-fpm configs.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-09, 17:46:07
Quote from: "MRatWork"
Look like your php.ini still using from php 5.2 where in your server using php 5.3/5.4.

I don't know what happens until you found this situation. Usually run 'sh /script/fixweb' will be fixed web server, php.ini and php-fpm configs.

Well everything was fine, i was using nginx, djbdns, php53u, php-fpm_event then i had problem with webmail and to fix it updated kloxo then i had a problem with dns server, all i did is using those fix comments and yum update
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-09, 17:59:17
after update and then always run 'sh /script/cleanup' and then restart services and kloxo with 'sh /script/restart-all'.
Title: Re: lxphp.exe: command not found
Post by: chrisf on 2013-08-09, 18:10:53
Looks like apache mod_suphp is missing for some reason.

Try
Code: [Select]
yum install mod_suphp

And when restart services if you get another http error like: cannot load mod_rewrite... or whatever mod_???  just install them UNTIL you can get httpd to start.

Then use Kloxo to switch php branch.  Version. Then web server switch.

I agree with Mustafa - usually all problems can be fixed with switch webserver / sh/script/cleanup.

Something went bad :(  If you still cannot get it to work you may need to yum remove both webservers - manually delete all config files (not kloxo files) then re-install.  sh/script/cleanup.  It appears your config files are not getting fixed.
Title: Re: lxphp.exe: command not found
Post by: starbolt on 2013-08-10, 07:48:28
I'm still not able to use lxphp. If I install it using yum, when I run /script/cleanup, it will automatically vanish lxphp.

What's the fix for this issue?
Title: Re: lxphp.exe: command not found
Post by: chrisf on 2013-08-10, 08:02:55
There is no lxphp any longer.  Mustafa replaced it with php52s.
Title: Re: lxphp.exe: command not found
Post by: starbolt on 2013-08-10, 09:20:25
Yes, I read that. But /script/upcp tries to run lxphp.exe when executing some scripts like fixdns. I'm wondering if my scripts are outdated or I'm missing something.

If anyone was able to fix the same issue, please share :)
Title: Re: lxphp.exe: command not found
Post by: chrisf on 2013-08-10, 12:46:26
It sounds like you didn't update your repo file.  I would suggest doing that first:

Code: [Select]
cd /etc/yum.repos.d/
rm -rf kloxo-mr.repo
wget https://raw.github.com/mustafaramadhan/kloxo/release/kloxo-mr.repo
yum update
yum reinstall kloxomr
yum remove lxphp
yum install php52s
sh /script/cleanup
sh /script/restart-all

That should do it.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-10, 16:14:10
Everything works fine on me now thanks to Mustafa, just have one question; when i run sh /script/restart-all there is problem with one client
Code: [Select]
Stopping php-fpm:                                          [FAILED]
Starting php-fpm: [10-Aug-2013 10:55:46] ERROR: An another FPM instance seems to already listen on /home/php-fpm/sock/nefiarda.sock
[10-Aug-2013 10:55:46] ERROR: FPM initialization failed
                                                           [FAILED]

i deleted this user from kloxo and run
Code: [Select]
adduser nefiarda; sh /script/fixweb; service php-fpm restart;

but still same do you guys have any idea what can i do about it?
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-10, 16:56:28
Try run 'service php-fpm stop; rm -rf /home/php-fpm/sock/nefiarda.sock; sh /script/fix-phpfpm; service php-fpm start'.

So, it's delete file first and then fixweb and restart php-fpm. If not work, try delete client the name nefiarda.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-10, 17:03:58
Quote from: "MRatWork"
Try run 'service php-fpm stop; rm -rf /home/php-fpm/sock/nefiarda.sock; sh /script/fix-phpfpm; service php-fpm start'.

So, it's delete file first and then fixweb and restart php-fpm. If not work, try delete client the name nefiarda.

Code: [Select]
[root@simonov ~]# service php-fpm stop; rm -rf /home/php-fpm/sock/nefiarda.sock; sh /script/fix-phpfpm; ser                vice php-fpm start
Stopping php-fpm:                                          [FAILED]
sh: /script/fix-phpfpm: No such file or directory
Starting php-fpm: [10-Aug-2013 11:50:40] ERROR: An another FPM instance seems to already listen on /home/ph                p-fpm/sock/moche.sock
[10-Aug-2013 11:50:40] ERROR: FPM initialization failed
                                                           [FAILED]
[root@simonov ~]#
Title: Re: lxphp.exe: command not found
Post by: MRatWork on 2013-08-10, 17:20:17
Sorry, wrong. Use 'sh /script/fixphpfpm'.
Title: Re: lxphp.exe: command not found
Post by: suplover on 2013-08-10, 18:30:23
Quote from: "MRatWork"
Sorry, wrong. Use 'sh /script/fixphpfpm'.

Perfect! Thanks again Mustafa