MRatWork Forum by Mustafa Ramadhan
Sawo Project - Kloxo-MR Discussions => Kloxo-MR Technical Helps => Topic started by: chrisf on 2014-04-30, 04:44:24
-
I have latest 6,5.1b (042902) and I tried switching Apache to Hiawatha proxy, no matter what I do I get this:
[root@cc-server ~]# sh /script/restart-web
Stopping httpd: [ OK ]
Starting httpd: [ OK ]
Stopping Hiawatha web server: [FAILED]
Starting Hiawatha web server: [ OK ]
listen(http(s)): Address already in use
Stopping php-fpm: [ OK ]
Starting php-fpm: [ OK ]
[root@cc-server ~]#
I try reboot. Fixweb, old trick changed webserver to nginx, back to Hiawatha proxy. Reboot, restart-all.
Nothing works. Please advise.
-
Another trick use 'killall hiawatha; sh /script/restart-all'. The same way for httpd with 'killall httpd'.
-
Still fails, same error.
-
Look like port 80 used by other (possible httpd). Try 'sh /script/fixweb'.
-
I ran all the fix scripts, rebooted, restarted, something isn't right. This Apache has a SSL certificate for a domain, could it be some problem with port 443 since all the recent changes?
It just will not start.:
-
I think not related to ssl but maybe something wrong with /etc/httpd/conf/httpd.conf.
This file must content ('Listen 80' must disabled):
# MR -- must be disable here because can not overrite! -- importance for proxy-to-apache
# Listen 80
And or possible old files not removed in /home/apache/conf/defaults and /home/apache/conf/domains. Try remove current files in both directories and then run 'sh /script/fixweb'.
-
I deleted files, fixweb, error remains. Checked httpd conf, listen 80 was commented out '#'.
Switched to nginx proxy, all working:
[root@cc-server ~]# sh /script/restart-web
Stopping httpd: [ OK ]
Starting httpd: [ OK ]
Stopping nginx: [ OK ]
Starting nginx: [ OK ]
Stopping php-fpm: [ OK ]
Starting php-fpm: [ OK ]
[root@cc-server ~]#
KloxoMR panel, switch program, Hiawatha proxy, fails!
[root@cc-server ~]# sh /script/restart-web
Stopping httpd: [ OK ]
Starting httpd: [ OK ]
Stopping Hiawatha web server: [FAILED]
Starting Hiawatha web server: [ OK ]
listen(http(s)): Address already in use
Stopping php-fpm: [ OK ]
Starting php-fpm: [ OK ]
[root@cc-server ~]#
So I can not get Hiawatha proxy to switch. I have tried about everything! Any more suggestions?
-
Just tried 'Hiawatha' with no proxy. It will not start. Same error, reboot, same error. I have Hiawatha running on other servers, no problems. This server has SSL domains.
Hiawatha, no proxy, same error:
[root@cc-server ~]# sh /script/restart-web
Stopping Hiawatha web server: [FAILED]
Starting Hiawatha web server: [ OK ]
listen(http(s)): Address already in use
Stopping php-fpm: [ OK ]
Starting php-fpm: [ OK ]
[root@cc-server ~]# sh /script/restart-web
Stopping Hiawatha web server: [FAILED]
Starting Hiawatha web server: [ OK ]
listen(http(s)): Address already in use
Stopping php-fpm: [ OK ]
Starting php-fpm: [ OK ]
[root@cc-server ~]# service hiawatha stop
Stopping Hiawatha web server: [FAILED]
[root@cc-server ~]# service hiawatha start
Starting Hiawatha web server: [ OK ]
[root@cc-server ~]# listen(http(s)): Address already in use
I think something is wrong, Hiawatha and Hiawatha proxy will not start.
-
No. Your hiawatha able to start but something wrong in stop process.
-
I don't think so. Stop fails because there is nothing to stop, Hiawatha never runs/starts properly.
I have Hiawatha running on four other servers, no problem. No ssl certs either.
Please investigate this problem.
-
Basically, nothing wrong with stop process. But, sometimes not work. It's similar situation for apache. I found latest apache have this issue. Look like apache back to their old issue (certain version have this issue).
In context, hiwatha-proxy, the process are restart httpd and then hiawatha (possible better restart hiawatha and then httpd).
-
In your case, try 'killall httpd; sh /script/restart-web'.
-
Mustafa, nginx proxy, lightppd proxy both work.
Hiawatha, NO proxy, will not start. Nothing in the error.log at all. Just that 'listen http(s) error message'. There is no httpd to kill, just Hiawatha.
If Hiawatha doesn't start, Hiawatha proxy won't either.
I still think related to port 443, that is only difference in my servers.
-
This error is related to Hiawatha configuration and the binding option. I have not looked further at this point, but searching Hiawatha forums explains this error.
Logic to me is, four servers running Hiawatha perfect, no SSL. 1 server with SSL, Hiawatha will not start.
Problem must be in the configuration for binding port 443.
-
If you sure it's related to ssl, try re-create self-assign for IP and or domains ssl.
-
IT IS DUE TO SSL BINDING / port 443. Proof. I deleted the conf file from hiawatha/conf/domains for the domain which has the ssl. Hiawatha started perfectly.
Ran fixweb to recreate the domain with ssl. Hiawatha FAILS!
SSH transcript:
[root@cc-server domains]# rm convictionshosting.com.conf
rm: remove regular file `convictionshosting.com.conf? y
[root@cc-server domains]# sh /script/restart-web
Stopping httpd: [ OK ]
Starting httpd: [ OK ]
Stopping Hiawatha web server: [FAILED]
Starting Hiawatha web server: [ OK ]
Stopping php-fpm: [ OK ]
Starting php-fpm: [ OK ]
[root@cc-server domains]# sh /script/restart-web
Stopping httpd: [ OK ]
Starting httpd: [ OK ]
Stopping Hiawatha web server: [ OK ]
Starting Hiawatha web server: [ OK ]
Stopping php-fpm: [ OK ]
Starting php-fpm: [ OK ]
[root@cc-server domains]# sh /script/fixweb
- For help, type '/script/fixweb --help'
- No argument supplied. Defaulting to localhost (master) servers
Fixing Web server config
- 'defaults' pages at 'localhost'
- 'cc-server.us' ('admin') at 'localhost'
- '.htaccess' for 'cc-server.us' ('admin') at 'localhost'
- 'convictionshosting.com' ('admin') at 'localhost'
- '.htaccess' for 'convictionshosting.com' ('admin') at 'localhost'
[root@cc-server domains]# sh /script/restart-web
Stopping httpd: [ OK ]
Starting httpd: [ OK ]
Stopping Hiawatha web server: [ OK ]
Starting Hiawatha web server: [ OK ]
listen(http(s)): Address already in use
Stopping php-fpm: [ OK ]
Starting php-fpm: [ OK ]
[root@cc-server domains]# sh /script/restart-web
Stopping httpd: [ OK ]
Starting httpd: [ OK ]
Stopping Hiawatha web server: [FAILED]
Starting Hiawatha web server: [ OK ]
listen(http(s)): Address already in use
Stopping php-fpm: [ OK ]
Starting php-fpm: [ OK ]
[root@cc-server domains]#
Hiawatha fails with a domain with SSL. It is through admin and IP (old way).
Please investigate and fix,
-
Using latest version of Kloxo-MR 6.5.1.b and ssl self-assign?.
-
Yes, latest KloxoMR 6.5.1b. The SSL is assigned through old way (admin ->IP->SSL) because it has been assigned for nearly half a year running Apache no proxy.
So there is a IP assigned to this domain as well. I was reading on Hiawatha forums this error normally happens when using the 'interface' option under binding - but don't know for sure.
I just know that Hiawatha will not start.
-
Try not using .ca file if using self-assign (not ssl from thirdparty) in /home/kloxo/httpd/ssl.
-
It is a rapidSSL and the intermediate file (ca) is required. It could also be the additional IP - there are different reasons for that error to be displayed - BUT, they all are due to configuration errors.
Something is wrong.
-
Check your /home/hiawatha/tpl/domains.conf.tpl. In previous you will see 'if (file_exists("{$certname}.ca")) {' and also using '.pem' instead '.crt'.
-
I switched back to pure Apache. This is a live site, and customers use it. I reported all of this because there is a obvious error in the Hiawatha configuration.
I don't know if it is due to the additional IP or the ssl, but I am sure it's wrong.
-
Have you found the cause of this error ?
-
Because I didn't have thirdparty ssl certificate, I don't know what's happen for your ssl.
If you permit, send to my PM your thirdparty ssl certificate.
-
try
yum remove hiawatha -y
yum install hiawatha -y
service restart hiawatha
-
try
yum remove hiawatha -y
yum install hiawatha -y
service restart hiawatha
If you try this commands, '/etc/hiawatha/hiawatha.conf' file is from hiawatha.rpm ('generic' hiawatha.conf). Kloxo-MR use 'special' hiawatha and taken from '/home/hiawatha/etc/conf/hiawatha.conf'.
As we know, other services (like apache, nginx, lighttpd and others) also using 'special' config.
-
I am not sure this is related to the CA file. I think it has to do with additional IP and ssl. I am not sure. I can not get Hiawatha to start. I have no idea why the configuration is wrong.
Sorry, I can not give you a copy of my ssl.
This actually is a serious problem. Add a ssl and IP to Hiawatha and it stops working.
-
Try update Kloxo-MR and then run 'sh /script/cleanup'.
I am not sure, but try install polarssl with 'yum install polarssl'.
-
running latest 6.5.1b, installed polarssl, same error.
listen(http(s)): Address already in use
In Hiawatha forums this error is due to incorrect binding. I use an additional IP with this site, could that be a problem.
I changed all my servers to Hiawatha proxy, if a customer wants ssl, is everything going to break?
This is a critical bug in the configuration of Hiawatha.
-
Found the problem. It is not because of the SSL, it is because of the IP set for that domain.
From Creator of Hiawatha:
Hugo Leisink
When not specifying an interface in a Binding block, Hiawatha will bind all available interfaces. When a second block has the interface option, that interface is already binded by the previous binding block. To solve this, specify an interface in the first binding block.
In Hiawatha defaults init.conf you don't use the interface option, you bind Hiawatha to all IP's. In my website, I added exclusive IP, and you use interface option in binding it. But, it is already bound to first init.conf binding id port_443.
You have to list all available ip's in the init.conf, using interface option.
This is a critical bug in KloxoMR and adding any exclusive IP to a website will break Hiawatha.
Please fix. Thank you.
-
It's different behaviour between hiawatha and other webservers.
-
Yes, I was able to get it working like this:
These are examples.
If my server had 5 ip's with 2 dedicated / exclusive for a site, Hiawatha conf needs to be:
1.1.1.1, 1.1.1.2, 1.1.1.3
1.1.1.4 is exclusive IP for website, 1.1.1.5 exclusive for website
In init.conf for Hiawatha in binding part add
Interface options for 1.1.1.1-3 ONLY
in domain conf use interface for corresponding IP
It works. But on fixweb/cleanup init.conf is rewrote.
-
Don't modified init.conf directly but modified custom.defaults.conf.tpl.
-
I never got it working completely. Php wasn't working. I got Hiawatha to start, but had problems.
You should investigate, since KloxoMR uses Hiawatha/Hiawatha proxy. Adding a site with exclusive IP breaks KloxoMR.
-
Anything Mustafa?
-
I can't testing in my servers because every server only have 1 IP address.
-
In a couple weeks I will be provisioning a server for vps sales. At this time I can let you use a vps to fix Hiawatha, it will have atleast 4 ip's available.
This vps could be available to you for a month.
Agreed?