stratos-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nirmal Fernando <nirmal070...@gmail.com>
Subject Re: Updating stratos.sh in products
Date Thu, 09 Jan 2014 15:47:37 GMT
Hi Chris,

Where do you intend to do this? AFAIU at the time of servers start-up
right? Can we generate these scripts once the products get build? So, that
the maven built product would contain the required script to start the
respective server? wdyt?


On Thu, Jan 9, 2014 at 7:59 PM, chris snow <chsnow123@gmail.com> wrote:

> Nirmal, is this what you were thinking as well, or are you suggesting
> something else?
> On 9 Jan 2014 14:19, "chris snow" <chsnow123@gmail.com> wrote:
>
>> Hi Nirmal,
>>
>> I was thinking that the script would be manually created, but the certain
>> parts of the configuration would be extracted, so instead of this:
>>
>> while [ "$status" = "$START_EXIT_STATUS" ]
>> do
>>     $JAVACMD \
>>     -Xbootclasspath/a:"$CARBON_XBOOTCLASSPATH" \
>>     -Xms256m -Xmx1024m -XX:MaxPermSize=256m \
>>     -XX:+HeapDumpOnOutOfMemoryError \
>>    ...
>> done
>>
>> you would have something like this:
>>
>> while [ "$status" = "$START_EXIT_STATUS" ]
>> do
>>     $JAVACMD \
>>     -Xbootclasspath/a:"$CARBON_XBOOTCLASSPATH" \
>>     $JAVA_MEM_SETTINGS \
>>     -XX:+HeapDumpOnOutOfMemoryError \
>>    ...
>> done
>>
>> there would then be a custom properties file that would be read by the
>> startup script, for example
>>
>>    JAVA_MEM_SETTINGS= -Xms256m -Xmx1024m -XX:MaxPermSize=256m
>>
>> You would then have different property files for different products, e.g.
>>
>> stratos-load-balancer-startup.properties (e.g. for the load balancer
>> product when installed standalone)
>>
>>    JAVA_MEM_SETTINGS= -Xms256m -Xmx1024m -XX:MaxPermSize=256m
>>
>> stratos-manager-startup.properties (e.g. for the manager product when
>> installed standalone)
>>
>>    JAVA_MEM_SETTINGS= -Xms256m -Xmx2048m -XX:MaxPermSize=256m
>>
>> all-in-one-startup.properties (e.g. when all stratos products are
>> installed in one server)
>>
>>    JAVA_MEM_SETTINGS= -Xms1024m -Xmx4094m -XX:MaxPermSize=1024m
>>
>> I don't know if this approach would work, it depends on what startup
>> configuration varies for each of the products.
>>
>> Does this help explain?
>>
>> Many thanks,
>>
>> Chris
>>
>>
>>
>>
>>
>> On Thu, Jan 9, 2014 at 12:52 PM, Nirmal Fernando <nirmal070125@gmail.com>wrote:
>>
>>> Hi Chris/All,
>>>
>>> What do you think about the point I made?
>>>
>>>
>>> On Thu, Jan 9, 2014 at 6:05 PM, chris snow <chsnow123@gmail.com> wrote:
>>>
>>>> Hi Isuru, that sounds good.  I'm trying to think of a similar approach
>>>> in the unix world that we could borrow ideas from.  Postfix springs to
>>>> mind,  where I think there are multiple small services that can be started
>>>> individually, or all together?
>>>>
>>>>
>>>> On Thu, Jan 9, 2014 at 11:30 AM, Isuru Haththotuwa <isuruh@wso2.com>wrote:
>>>>
>>>>> Good thinking Chris. In my opinion it would be nice to have the
>>>>> capability to start the whole system at one go, using a single
>>>>> command/script, and also to be able to start/stop individual servers.
Maybe
>>>>> we can use a generic startup script in which we could specify one/more
than
>>>>> one/all server(s) that should start. WDYT?
>>>>>
>>>>>
>>>>> On Thu, Jan 9, 2014 at 4:42 PM, Isuru Perera <isurup@wso2.com>
wrote:
>>>>>
>>>>>> Hi Chris,
>>>>>>
>>>>>>
>>>>>> On Thu, Jan 9, 2014 at 4:12 PM, chris snow <chsnow123@gmail.com>wrote:
>>>>>>
>>>>>>> Would there be any benefit in having a generic startup script
by
>>>>>>> extracting the differences into a product specific properties
file that get
>>>>>>> imported by the generic script?
>>>>>>>
>>>>>> Yes! There are benefits using a generic start-up script as you
>>>>>> mentioned.
>>>>>>
>>>>>>> I'm not sure if this would be possible, but this approach would
be
>>>>>>> helpful for newbie administrators to easily identify produce
specific
>>>>>>> customisations on top of carbon. It would also allow us to maintain
only
>>>>>>> one startup script that is used across all the products?
>>>>>>>
>>>>>> This is a good idea and I think it should be possible when
>>>>>> considering the overall idea. However we need to think about this
when we
>>>>>> finalize the configurations required for the next release.
>>>>>>
>>>>>>  Currently we have the start-up script in each product distribution
>>>>>> now.
>>>>>>
>>>>>>
>>>>>> *./products/autoscaler/modules/distribution/src/main/resources/stratos.sh**
>>>>>>
>>>>>> *./products/cloud-controller/modules/distribution/src/main/resources/stratos.sh**
>>>>>>
>>>>>> ./products/cartridge-agent/modules/distribution/src/main/bin/stratos.sh
>>>>>> *./products/stratos-manager/modules/distribution/src/bin/stratos.sh**
>>>>>> ./products/stratos-cli/distribution/src/main/bin/stratos.sh
>>>>>>
>>>>>> *./products/load-balancer/modules/distribution/src/main/bin/stratos.sh**
>>>>>>
>>>>>> * - The products, which depend on WSO2 Carbon kernel and these are
>>>>>> files I'm going to update.
>>>>>>
>>>>>> AFAIK, these scripts can be the same, and there will be no product
>>>>>> specific changes. The team is doing lot of changes for next major
version
>>>>>> and there may be product specific changes. I'm in the process of
learning
>>>>>> new changes :)
>>>>>>
>>>>>> We will have to see what each product would need additionally.
>>>>>>
>>>>>> Therefore as the first step, I will try to update individual files.
>>>>>>
>>>>>> Thanks!
>>>>>>
>>>>>> Best Regards,
>>>>>>
>>>>>>
>>>>>>
>>>>>>> On 9 Jan 2014 09:34, "Isuru Perera" <isurup@wso2.com> wrote:
>>>>>>>
>>>>>>>> Hi,
>>>>>>>>
>>>>>>>> With the recent Carbon 4.2.0 upgrade, I think we should also
update
>>>>>>>> stratos.sh to match with the wso2server.sh file provided
by Carbon.
>>>>>>>>
>>>>>>>> I am going to update those now.
>>>>>>>>
>>>>>>>> I found that each stratos.sh in different products has different
>>>>>>>> configurations.
>>>>>>>>
>>>>>>>> However, I'm going to use the original startup script provided
by
>>>>>>>> Carbon and only necessary configurations for Stratos.
>>>>>>>>
>>>>>>>> So far, I found that following argument is important to Stratos.
>>>>>>>>
>>>>>>>> -Djndi.properties.dir="$CARBON_HOME/repository/conf"
>>>>>>>>
>>>>>>>> Any other important properties?
>>>>>>>>
>>>>>>>> Please let me know.
>>>>>>>>
>>>>>>>> Thanks!
>>>>>>>>
>>>>>>>> Best Regards,
>>>>>>>>
>>>>>>>> --
>>>>>>>> Isuru Perera
>>>>>>>> Senior Software Engineer | WSO2, Inc. | http://wso2.com/
>>>>>>>> Lean . Enterprise . Middleware
>>>>>>>>
>>>>>>>> about.me/chrishantha
>>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Isuru Perera
>>>>>> Senior Software Engineer | WSO2, Inc. | http://wso2.com/
>>>>>> Lean . Enterprise . Middleware
>>>>>>
>>>>>> about.me/chrishantha
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Thanks and Regards,
>>>>>
>>>>> Isuru H.
>>>>> Software Engineer, WSO2 Inc.
>>>>> +94 716 358 048* <http://wso2.com/>*
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Check out my professional profile and connect with me on LinkedIn.
>>>> http://lnkd.in/cw5k69
>>>>
>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>>
>>
>>
>>
>> --
>> Check out my professional profile and connect with me on LinkedIn.
>> http://lnkd.in/cw5k69
>>
>


-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/

Mime
View raw message