How to start a new application

Submitted by Zigy on Wed, 2007-05-23 01:06.

Hello all,

I have a problem with running my own application.

I created a new model, I followed all the steps from the Modeling Tutorial, I made the image for my Model, I deployed it on the target machine, but when I tried to run it, it did not appear in the models that could be handled.

When I run the command complist, my application was not there, only the test applications that come with the sources.

I made a new project area, where I put only my Model, no sample applications, I created the image, deploy it, and the same thing happened.

My question is how to insert my Model into that image, and also how could I import the sample applications into the IDE, to see how they were modeled?

Thanks

Submitted by harikrishna_gp on Wed, 2007-05-23 18:04.

Hi,
You should be building ASP with your model instead of overlaying your code on to the evaluation model.
Please use ./configure --with-model-name='ur-model-name' to build ASP and your model together. The steps in section 4.2.2 of evaluation guide'OpenClovis_EvaluationGuide-2.2.pdf' should help you understand how to build your model.

HTH,
Hari

Submitted by Zigy on Thu, 2007-05-24 02:16.

Hello Hari,

The steps in creating my application are the following:

1. I created my model using the IDE, validated the project, built it.
2. I modified the file target.conf in /SISP/models/MyModel/target.conf
3. In /SISP: ./configure --with-model-name=MyModel
4. make
5. make images
6. I copied /target/MateiModel/images/SysNodeInstance0.tgz to /root/SISP/
7. I unpacked the archive
8. In /root/SISP/etc/init.d/ : ./sisp start
9. In /root/SISP/bin/: ./debug.sh
10. setc 1
11 set cpm
12. complist

And here, I don’t see anything related to my model.
I used the command: amsLockAssignment sg Sys_SG where Sys_SG is a service group defined in MyModel end the output is: admin operation[lock assignment] failed

When I run the command complist I saw there components related to the evaluation models and I don’t understand why are there because I used : ./configure --with-model-name=MyModel (it should have been only my component, or not?)

Zigy

Submitted by harikrishna_gp on Thu, 2007-05-24 09:29.

Hi,
Please post amf*.xml files from /root/sisp/etc/

Thanks
Hari

Submitted by Zigy on Thu, 2007-05-24 23:09.

amfConfig.xml:

?xml version="1.0" encoding="UTF-8"?
amfConfig xmlns="cpmconfig.ecore" version="B.01.01">
cpmConfigs>
cpmConfig nodeType="SysNode" cpmType="GLOBAL">
bootConfigs>
bootConfig name="default" maxBootLevel="6" defaultBootLevel="5"/>
/bootConfigs>
sispServiceUnits>
sispServiceUnit name="eventSU"/>
sispServiceUnit name="nameSU"/>
sispServiceUnit name="ckptSU"/>
sispServiceUnit name="corSU"/>
sispServiceUnit name="oampSU"/>
sispServiceUnit name="logSU"/>
sispServiceUnit name="txnSU"/>
sispServiceUnit name="gmsSU"/>
/sispServiceUnits>
/cpmConfig>
/cpmConfigs>
nodeInstances>
nodeInstance name="SysNodeInstance0" type="SysNode" nodeMoId="\Chassis:0\SysBlade:0">
serviceUnitInstances>
serviceUnitInstance name="SysSUInstance0" type="Sys_SU" rank="0">
componentInstances>
componentInstance name="SysCompInstance0" type="SysComp"/>
/componentInstances>
/serviceUnitInstance>
/serviceUnitInstances>
dependencies node=""/>
/nodeInstance>
/nodeInstances>
serviceGroups>
serviceGroup name="SysSG" type="Sys_SG">
serviceInstances>
serviceInstance name="SysSI" type="Sys_SI">
componentServiceInstances>
componentServiceInstance name="SysCSI" type="Sys_CSI"/>
/componentServiceInstances>
dependencies serviceInstance=""/>
prefferedServiceUnits>
prefferedServiceUnit>SysSUInstance0 /prefferedServiceUnit>
/prefferedServiceUnits>
/serviceInstance>
/serviceInstances>
associatedServiceUnits associatedServiceUnit=""/>
/serviceGroup>
/serviceGroups>
/amfConfig>

amfDefinitions.xml:

?xml version="1.0" encoding="UTF-8"?>
amfDefinitions:amfTypes xmlns:amfDefinitions="amfDefinitions.ecore">
nodeTypes>
nodeType name="SysNode">
id>0 /id>
classType>CL_AMS_NODE_CLASS_B /classType>
subClassType> /subClassType>
isSwappable>CL_TRUE /isSwappable>
isRestartable>CL_TRUE /isRestartable>
isSISPAware>CL_TRUE /isSISPAware>
suFailoverDuration>10000 /suFailoverDuration>
suFailoverCountMax>5000 /suFailoverCountMax>
adminState>CL_AMS_ADMIN_STATE_UNLOCKED /adminState>
/nodeType>
/nodeTypes>
sgTypes>
sgType name="Sys_SG">
failbackOption>CL_FALSE /failbackOption>
restartDuration>10000 /restartDuration>
numPrefActiveSUs>1 /numPrefActiveSUs>
numPrefStandbySUs>0 /numPrefStandbySUs>
numPrefInserviceSUs>1 /numPrefInserviceSUs>
numPrefAssignedSUs>2 /numPrefAssignedSUs>
numPrefActiveSUsPerSI>1 /numPrefActiveSUsPerSI>
maxActiveSIsPerSU>1 /maxActiveSIsPerSU>
maxStandbySIsPerSU>1 /maxStandbySIsPerSU>
compRestartDuration>10000 /compRestartDuration>
compRestartCountMax>0 /compRestartCountMax>
suRestartDuration>10000 /suRestartDuration>
suRestartCountMax>0 /suRestartCountMax>
adminState>CL_AMS_ADMIN_STATE_UNLOCKED /adminState>
redundancyModel>CL_AMS_SG_REDUNDANCY_MODEL_NO_REDUNDANCY /redundancyModel>
loadingStrategy>CL_AMS_SG_LOADING_STRATEGY_LEAST_SI_PER_SU /loadingStrategy>
autoRepair>CL_FALSE /autoRepair>
/sgType>
/sgTypes>
suTypes>
suType name="Sys_SU">
adminState>CL_AMS_ADMIN_STATE_UNLOCKED /adminState>
isPreinstantiable>CL_TRUE /isPreinstantiable>
isRestartable>CL_TRUE /isRestartable>
isContainerSU>CL_TRUE /isContainerSU>
numComponents>1 /numComponents>
/suType>
/suTypes>
siTypes>
siType name="Sys_SI">
rank>0 /rank>
numCSIs>1 /numCSIs>
numStandbyAssignments>0 /numStandbyAssignments>
adminState>CL_AMS_ADMIN_STATE_UNLOCKED /adminState>
/siType>
/siTypes>
compTypes>
compType name="SysComp">
csiType>ComponentServiceInstance0_type0 /csiType>
capabilityModel>CL_AMS_COMP_CAP_X_ACTIVE_OR_Y_STANDBY /capabilityModel>
property>CL_AMS_SA_AWARE /property>
processRel>CL_CPM_COMP_SINGLE_PROCESS /processRel>
instantiateCommand>comp_SAF_Aware_Component00 /instantiateCommand>
args/>
envs/>
terminateCommand> /terminateCommand>
cleanupCommand> /cleanupCommand>
isRestartable>CL_TRUE /isRestartable>
nodeRebootCleanupFail>CL_TRUE /nodeRebootCleanupFail>
instantiateLevel>0 /instantiateLevel>
instantiateDelay>10000 /instantiateDelay>
numMaxInstantiate>1 /numMaxInstantiate>
numMaxInstantiateWithDelay>1 /numMaxInstantiateWithDelay>
numMaxTerminate>1 /numMaxTerminate>
numMaxAmStart>1 /numMaxAmStart>
numMaxAmStop>1 /numMaxAmStop>
numMaxActiveCSIs>1 /numMaxActiveCSIs>
numMaxStandbyCSIs>1 /numMaxStandbyCSIs>
recoveryOnTimeout>CL_AMS_RECOVERY_NO_RECOMMENDATION /recoveryOnTimeout>
amStartCommand> /amStartCommand>
amStopCommand> /amStopCommand>
timeouts>
instantiateTimeout>10000 /instantiateTimeout>
terminateTimeout>10000 /terminateTimeout>
cleanupTimeout>10000 /cleanupTimeout>
amStartTimeout>10000 /amStartTimeout>
amStopTimeout>10000 /amStopTimeout>
quiescingCompleteTimeout>10000 /quiescingCompleteTimeout>
csiSetTimeout>10000 /csiSetTimeout>
csiRemoveTimeout>10000 /csiRemoveTimeout>
proxiedCompInstantiateTimeout>10000 /proxiedCompInstantiateTimeout>
proxiedCompCleanupTimeout>10000 /proxiedCompCleanupTimeout>
/timeouts>
/compType>
/compTypes>
csiTypes>
csiType name="Sys_CSI">
type>ComponentServiceInstance0_type0 /type>
rank>0
nameValueLists/>
/csiType>
/csiTypes>
/amfDefinitions:amfTypes>"

Thanks,
Zigy

Submitted by Zigy on Fri, 2007-05-25 04:45.

I made the model again, i followed the same steps, and now it works :D
I don't know what was the problem, but the important thing is that now works.

Thanks for the help.
Zigy