You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@stratos.apache.org by Pubudu Gunatilaka <pu...@wso2.com> on 2015/06/07 13:22:57 UTC

Kubernetes on EC2 with Single Cartridge App

Hi Devs,

I was able to set up kubernetes on ec2 with master node and one minion
node. Then I pulled the stratos/php:4.1.0 docker image to the minion node
and deployed the single cartridge app. But I got the same error mentioned
in a previous thread "Problem in Kubernetes with Stratos master branch"
although I have pulled docker image to minions.

Then I ran live test as mentioned in the above thread and it was
successful. I redeployed the application again. Then the application got
activated and I was able to access the php app. But activated pods do not
last more than one minute. Faulty member detected message comes and creates
a new pod. I think this is happening as the cartridge does not publish
events to CEP and it causes to identify this pod as inactive.

I am using stratos/php:4.1.0 docker image.

How can I overcome this problem?
Do we need to run live test every time when we create a kubernetes cluster?

Thank you!

-- 

*Pubudu Gunatilaka*
Software Engineer
WSO2, Inc.: http://wso2.com
lean.enterprise.middleware
mobile:  +94 77 4078049

Re: Kubernetes on EC2 with Single Cartridge App

Posted by Imesh Gunaratne <im...@apache.org>.
Great! Nice to hear that!

On Mon, Jun 8, 2015 at 9:03 AM, Pubudu Gunatilaka <pu...@wso2.com> wrote:

> Hi Imesh,
>
> I rechecked the kubernetes cluster json and changed my CEP_PORT to 7711
> which is the thrift SSL port. I have used the thrift port which is 7611 in
> my json. That could be the reason why cartridge agent was unable to send
> stats to cep. Now kubernetes cluster is working fine.
>
> Thank you!
>
>
> On Mon, Jun 8, 2015 at 1:47 AM, Imesh Gunaratne <im...@apache.org> wrote:
>
>> s/it was updated properly/it was not updated properly/g
>>
>> On Mon, Jun 8, 2015 at 1:46 AM, Imesh Gunaratne <im...@apache.org> wrote:
>>
>>> Hi Pubudu,
>>>
>>> Did you update the Kubernetes Cluster JSON with the IP addresses of your
>>> EC2 instances? May be it was updated properly:
>>>
>>>
>>> https://github.com/apache/stratos/blob/master/samples/kubernetes-clusters/kubernetes-cluster-ec2.json
>>>
>>>
>>>
>>> On Sun, Jun 7, 2015 at 4:52 PM, Pubudu Gunatilaka <pu...@wso2.com>
>>> wrote:
>>>
>>>> Hi Devs,
>>>>
>>>> I was able to set up kubernetes on ec2 with master node and one minion
>>>> node. Then I pulled the stratos/php:4.1.0 docker image to the minion node
>>>> and deployed the single cartridge app. But I got the same error mentioned
>>>> in a previous thread "Problem in Kubernetes with Stratos master branch"
>>>> although I have pulled docker image to minions.
>>>>
>>>> Then I ran live test as mentioned in the above thread and it was
>>>> successful. I redeployed the application again. Then the application got
>>>> activated and I was able to access the php app. But activated pods do not
>>>> last more than one minute. Faulty member detected message comes and creates
>>>> a new pod. I think this is happening as the cartridge does not publish
>>>> events to CEP and it causes to identify this pod as inactive.
>>>>
>>>> I am using stratos/php:4.1.0 docker image.
>>>>
>>>> How can I overcome this problem?
>>>> Do we need to run live test every time when we create a kubernetes
>>>> cluster?
>>>>
>>>> Thank you!
>>>>
>>>> --
>>>>
>>>> *Pubudu Gunatilaka*
>>>> Software Engineer
>>>> WSO2, Inc.: http://wso2.com
>>>> lean.enterprise.middleware
>>>> mobile:  +94 77 4078049
>>>>
>>>
>>>
>>>
>>> --
>>> Imesh Gunaratne
>>>
>>> Senior Technical Lead, WSO2
>>> Committer & PMC Member, Apache Stratos
>>>
>>
>>
>>
>> --
>> Imesh Gunaratne
>>
>> Senior Technical Lead, WSO2
>> Committer & PMC Member, Apache Stratos
>>
>
>
>
> --
>
> *Pubudu Gunatilaka*
> Software Engineer
> WSO2, Inc.: http://wso2.com
> lean.enterprise.middleware
> mobile:  +94 77 4078049
>



-- 
Imesh Gunaratne

Senior Technical Lead, WSO2
Committer & PMC Member, Apache Stratos

Re: Kubernetes on EC2 with Single Cartridge App

Posted by Pubudu Gunatilaka <pu...@wso2.com>.
Hi Imesh,

I rechecked the kubernetes cluster json and changed my CEP_PORT to 7711
which is the thrift SSL port. I have used the thrift port which is 7611 in
my json. That could be the reason why cartridge agent was unable to send
stats to cep. Now kubernetes cluster is working fine.

Thank you!


On Mon, Jun 8, 2015 at 1:47 AM, Imesh Gunaratne <im...@apache.org> wrote:

> s/it was updated properly/it was not updated properly/g
>
> On Mon, Jun 8, 2015 at 1:46 AM, Imesh Gunaratne <im...@apache.org> wrote:
>
>> Hi Pubudu,
>>
>> Did you update the Kubernetes Cluster JSON with the IP addresses of your
>> EC2 instances? May be it was updated properly:
>>
>>
>> https://github.com/apache/stratos/blob/master/samples/kubernetes-clusters/kubernetes-cluster-ec2.json
>>
>>
>>
>> On Sun, Jun 7, 2015 at 4:52 PM, Pubudu Gunatilaka <pu...@wso2.com>
>> wrote:
>>
>>> Hi Devs,
>>>
>>> I was able to set up kubernetes on ec2 with master node and one minion
>>> node. Then I pulled the stratos/php:4.1.0 docker image to the minion node
>>> and deployed the single cartridge app. But I got the same error mentioned
>>> in a previous thread "Problem in Kubernetes with Stratos master branch"
>>> although I have pulled docker image to minions.
>>>
>>> Then I ran live test as mentioned in the above thread and it was
>>> successful. I redeployed the application again. Then the application got
>>> activated and I was able to access the php app. But activated pods do not
>>> last more than one minute. Faulty member detected message comes and creates
>>> a new pod. I think this is happening as the cartridge does not publish
>>> events to CEP and it causes to identify this pod as inactive.
>>>
>>> I am using stratos/php:4.1.0 docker image.
>>>
>>> How can I overcome this problem?
>>> Do we need to run live test every time when we create a kubernetes
>>> cluster?
>>>
>>> Thank you!
>>>
>>> --
>>>
>>> *Pubudu Gunatilaka*
>>> Software Engineer
>>> WSO2, Inc.: http://wso2.com
>>> lean.enterprise.middleware
>>> mobile:  +94 77 4078049
>>>
>>
>>
>>
>> --
>> Imesh Gunaratne
>>
>> Senior Technical Lead, WSO2
>> Committer & PMC Member, Apache Stratos
>>
>
>
>
> --
> Imesh Gunaratne
>
> Senior Technical Lead, WSO2
> Committer & PMC Member, Apache Stratos
>



-- 

*Pubudu Gunatilaka*
Software Engineer
WSO2, Inc.: http://wso2.com
lean.enterprise.middleware
mobile:  +94 77 4078049

Re: Kubernetes on EC2 with Single Cartridge App

Posted by Imesh Gunaratne <im...@apache.org>.
s/it was updated properly/it was not updated properly/g

On Mon, Jun 8, 2015 at 1:46 AM, Imesh Gunaratne <im...@apache.org> wrote:

> Hi Pubudu,
>
> Did you update the Kubernetes Cluster JSON with the IP addresses of your
> EC2 instances? May be it was updated properly:
>
>
> https://github.com/apache/stratos/blob/master/samples/kubernetes-clusters/kubernetes-cluster-ec2.json
>
>
>
> On Sun, Jun 7, 2015 at 4:52 PM, Pubudu Gunatilaka <pu...@wso2.com>
> wrote:
>
>> Hi Devs,
>>
>> I was able to set up kubernetes on ec2 with master node and one minion
>> node. Then I pulled the stratos/php:4.1.0 docker image to the minion node
>> and deployed the single cartridge app. But I got the same error mentioned
>> in a previous thread "Problem in Kubernetes with Stratos master branch"
>> although I have pulled docker image to minions.
>>
>> Then I ran live test as mentioned in the above thread and it was
>> successful. I redeployed the application again. Then the application got
>> activated and I was able to access the php app. But activated pods do not
>> last more than one minute. Faulty member detected message comes and creates
>> a new pod. I think this is happening as the cartridge does not publish
>> events to CEP and it causes to identify this pod as inactive.
>>
>> I am using stratos/php:4.1.0 docker image.
>>
>> How can I overcome this problem?
>> Do we need to run live test every time when we create a kubernetes
>> cluster?
>>
>> Thank you!
>>
>> --
>>
>> *Pubudu Gunatilaka*
>> Software Engineer
>> WSO2, Inc.: http://wso2.com
>> lean.enterprise.middleware
>> mobile:  +94 77 4078049
>>
>
>
>
> --
> Imesh Gunaratne
>
> Senior Technical Lead, WSO2
> Committer & PMC Member, Apache Stratos
>



-- 
Imesh Gunaratne

Senior Technical Lead, WSO2
Committer & PMC Member, Apache Stratos

Re: Kubernetes on EC2 with Single Cartridge App

Posted by Imesh Gunaratne <im...@apache.org>.
Hi Pubudu,

Did you update the Kubernetes Cluster JSON with the IP addresses of your
EC2 instances? May be it was updated properly:

https://github.com/apache/stratos/blob/master/samples/kubernetes-clusters/kubernetes-cluster-ec2.json



On Sun, Jun 7, 2015 at 4:52 PM, Pubudu Gunatilaka <pu...@wso2.com> wrote:

> Hi Devs,
>
> I was able to set up kubernetes on ec2 with master node and one minion
> node. Then I pulled the stratos/php:4.1.0 docker image to the minion node
> and deployed the single cartridge app. But I got the same error mentioned
> in a previous thread "Problem in Kubernetes with Stratos master branch"
> although I have pulled docker image to minions.
>
> Then I ran live test as mentioned in the above thread and it was
> successful. I redeployed the application again. Then the application got
> activated and I was able to access the php app. But activated pods do not
> last more than one minute. Faulty member detected message comes and creates
> a new pod. I think this is happening as the cartridge does not publish
> events to CEP and it causes to identify this pod as inactive.
>
> I am using stratos/php:4.1.0 docker image.
>
> How can I overcome this problem?
> Do we need to run live test every time when we create a kubernetes
> cluster?
>
> Thank you!
>
> --
>
> *Pubudu Gunatilaka*
> Software Engineer
> WSO2, Inc.: http://wso2.com
> lean.enterprise.middleware
> mobile:  +94 77 4078049
>



-- 
Imesh Gunaratne

Senior Technical Lead, WSO2
Committer & PMC Member, Apache Stratos

Re: Kubernetes on EC2 with Single Cartridge App

Posted by Lahiru Sandaruwan <la...@wso2.com>.
Hi Pubudu,

Shall we have a look on cartridge agent logs?

Thanks.

On Sun, Jun 7, 2015 at 4:52 PM, Pubudu Gunatilaka <pu...@wso2.com> wrote:

> Hi Devs,
>
> I was able to set up kubernetes on ec2 with master node and one minion
> node. Then I pulled the stratos/php:4.1.0 docker image to the minion node
> and deployed the single cartridge app. But I got the same error mentioned
> in a previous thread "Problem in Kubernetes with Stratos master branch"
> although I have pulled docker image to minions.
>
> Then I ran live test as mentioned in the above thread and it was
> successful. I redeployed the application again. Then the application got
> activated and I was able to access the php app. But activated pods do not
> last more than one minute. Faulty member detected message comes and creates
> a new pod. I think this is happening as the cartridge does not publish
> events to CEP and it causes to identify this pod as inactive.
>
> I am using stratos/php:4.1.0 docker image.
>
> How can I overcome this problem?
> Do we need to run live test every time when we create a kubernetes
> cluster?
>
> Thank you!
>
> --
>
> *Pubudu Gunatilaka*
> Software Engineer
> WSO2, Inc.: http://wso2.com
> lean.enterprise.middleware
> mobile:  +94 77 4078049
>



-- 
--
Lahiru Sandaruwan
Committer and PMC member, Apache Stratos,
Senior Software Engineer,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

phone: +94773325954
email: lahirus@wso2.com blog: http://lahiruwrites.blogspot.com/
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146