stratos-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gayan Gunarathne <gay...@wso2.com>
Subject Re: How to use the Load Balancer with openstack
Date Sat, 06 Jun 2015 05:48:52 GMT
Hi,

On Sat, Jun 6, 2015 at 5:08 AM, Athanasios Tsitsipas <
athanasios.tsitsipas@uni-ulm.de> wrote:

> I tried to start nginx extention…
>
>
>
> It is get notified that an application exists but I get the following error
>
>
>
> [2015-06-05 23:34:03,654]  INFO - [TopologyProvider] Member added to
> cluster: [cluster] test.ghost.ghost.domain [member] 192.168.8.42
>
> [2015-06-05 23:34:04,211]  INFO - [Nginx] Generating nginx configuration...
>
> [2015-06-05 23:34:04,218]  INFO - [Main] Configuration written to file:
> /tmp/nginx.cfg
>
> [2015-06-05 23:34:04,218]  INFO - [Nginx] Starting nginx instance...
>
> [2015-06-05 23:34:04,219] ERROR - [Nginx] Could not start nginx instance
>
> [2015-06-05 23:34:04,219] ERROR - [LoadBalancerExtension] Could not start
> load balancer
>
> org.apache.stratos.load.balancer.extension.api.exception.LoadBalancerExtensionException:
> java.io.IOException: Cannot run program "nginx": error=2, No such file or
> directory
>
>         at org.apache.stratos.nginx.extension.Nginx.start(Nginx.java:92)
>

Seems load balancer can't find the program nginx. Did you download and
extract Nginx binary distribution and provide that nginx file
path( -Dexecutable.file.path)  in nginx-extension.sh? [1]

[1]
https://github.com/apache/stratos/blob/master/extensions/load-balancer/nginx-extension/INSTALL.md

>
>         at
> org.apache.stratos.load.balancer.extension.api.LoadBalancerExtension.configureAndStart(LoadBalancerExtension.java:247)
>
>         at
> org.apache.stratos.load.balancer.extension.api.LoadBalancerExtension.access$100(LoadBalancerExtension.java:46)
>
>         at
> org.apache.stratos.load.balancer.extension.api.LoadBalancerExtension$1.onEvent(LoadBalancerExtension.java:184)
>
>         at
> org.apache.stratos.messaging.listener.EventListener.update(EventListener.java:42)
>
>         at java.util.Observable.notifyObservers(Observable.java:159)
>
>         at
> org.apache.stratos.messaging.event.EventObservable.notifyEventListeners(EventObservable.java:51)
>
>         at
> org.apache.stratos.messaging.message.processor.topology.CompleteTopologyMessageProcessor.process(CompleteTopologyMessageProcessor.java:68)
>
>         at
> org.apache.stratos.messaging.message.processor.MessageProcessorChain.process(MessageProcessorChain.java:61)
>
>         at
> org.apache.stratos.messaging.message.receiver.topology.TopologyEventMessageDelegator.run(TopologyEventMessageDelegator.java:73)
>
>         at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>
>         at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>
>         at java.lang.Thread.run(Thread.java:745)
>
> Caused by: java.io.IOException: Cannot run program "nginx": error=2, No
> such file or directory
>
>         at java.lang.ProcessBuilder.start(ProcessBuilder.java:1047)
>
>         at java.lang.Runtime.exec(Runtime.java:617)
>
>         at java.lang.Runtime.exec(Runtime.java:450)
>
>         at java.lang.Runtime.exec(Runtime.java:347)
>
>         at
> org.apache.stratos.common.util.CommandUtils.executeCommand(CommandUtils.java:43)
>
>         at org.apache.stratos.nginx.extension.Nginx.start(Nginx.java:88)
>
>         ... 12 more
>
> Caused by: java.io.IOException: error=2, No such file or directory
>
>         at java.lang.UNIXProcess.forkAndExec(Native Method)
>
>         at java.lang.UNIXProcess.<init>(UNIXProcess.java:186)
>
>         at java.lang.ProcessImpl.start(ProcessImpl.java:130)
>
>         at java.lang.ProcessBuilder.start(ProcessBuilder.java:1028)
>
>         ... 17 more
>
> [2015-06-05 23:34:04,228]  INFO - [Nginx] Stopping nginx...
>
> [2015-06-05 23:34:04,229] ERROR - [Nginx] Could not stop nginx
>
>
>
> I added the information for the activemq to jndi.properties file. Also I
> changed the script file accordingly and the thrift xml.
>
>
>
> *From:* Imesh Gunaratne [mailto:imesh@apache.org]
> *Sent:* Friday, June 5, 2015 9:05 PM
> *To:* dev
> *Subject:* Re: How to use the Load Balancer with openstack
>
>
>
> Hi Athanasios,
>
>
>
> It's nice to hear that you are using the latest codebase, it has three
> load balancing options:
>
>
>
> 1. Stratos Load Balancer
>
> 2. Nginx (via extension)
>
> 3. HAproxy (via extension)
>
>
>
> First you could try to run either of these against your Stratos deployment
> and see whether they are working as expected (before trying the puppet
> module). Load balancer only requires ActiveMQ and CEP information (IP,
> port) to run.
>
>
>
> Do a complete build and find 1 in the following folder:
>
>
> https://github.com/apache/stratos/tree/master/products/load-balancer/modules/distribution
>
>
>
> Update loadbalancer.conf and thrift-client-config.xml with the above
> values and start the product.
>
>
>
> Thanks
>
>
>
> On Wed, Jun 3, 2015 at 7:23 PM, Athanasios Tsitsipas <
> athanasios.tsitsipas@uni-ulm.de> wrote:
>
> Hi there,
>
>
>
> We are trying to install Stratos 4.1.0 and ok we got over some bugs in the
> files. More or less we can create many cartridges and use them with
> applications. But we need a load balancer now connected with a ghost
> application integrated with nodejs. What is the lb module in the puppet
> master modules and what is the haproxy. How we will subscribe the
> application we need to the load balancer and access the load balancer and
> redirect us to the  multiple instances of the application above. Is there
> any guide we can use?
>
>
>
> Many thanks in advance
>
>
>
> Athanasios Tsitsipas
>
>
>
>
>
> --
>
> Imesh Gunaratne
>
>
>
> Senior Technical Lead, WSO2
>
> Committer & PMC Member, Apache Stratos
>



-- 

Gayan Gunarathne
Technical Lead, WSO2 Inc. (http://wso2.com)
Committer & PMC Member, Apache Stratos
email : gayang@wso2.com  | mobile : +94 766819985

Mime
View raw message