Errors while deploying a new module

19 views
Skip to first unread message

dimitar

unread,
Jun 11, 2012, 11:39:08 PM6/11/12
to ControlTier

I have issues with installing a custom module (MyJBoss) on client
nodes. It looks like some files are missing and the procedure is
buggy.

In short I followed the example on developing on a new Type with the
Graphical Type Editor provided here http://doc36.controltier.org/wiki/Graphical_type_editor


1) The Install fails due to a missing file on the client node. See
File IO error below.
=======================================================================
[root@ctier-server ~]# ctl -p E4-QA -I tags=q02 -m Managed-Entity -c
Install-Module -- -module MyJBoss
bash: ctl: command not found
Error: Remote command failed with exit status 127
[root@ctier-server ~]# ctl -p E4-QA -I tags=q02 -m Managed-Entity -c
Install-Module -- -module MyJBoss
[root@node01 E4-QA.Module Install-Module][INFO] Getting:
http://ctier-server:7080/jackrabbit/repository/controltier/projects/E4-QA/artifacts/modules/MyJBoss-head.jar
[root@node01 E4-QA.Module Install-Module][INFO] To: /opt/software/
ctier/ctl/projects/E4-QA/artifacts/modules/MyJBoss-head.jar
[root@node01 E4-QA.Module Install-Module][INFO] Created dir: /opt/
software/ctier/ctl/projects/E4-QA/modules/MyJBoss
[root@node01 E4-QA.Module Install-Module][INFO] Expanding: /opt/
software/ctier/ctl/projects/E4-QA/artifacts/modules/MyJBoss-head.jar
into /opt/software/ctier/ctl/projects/E4-QA/modules/MyJBoss
Error: The following error occurred while executing this line:
/opt/software/ctier/ctl/modules/Module/commands/Install-Module.xml:
128: java.io.FileNotFoundException: /opt/software/ctier/ctl/modules/
MyJBoss/module.properties (No such file or directory)
Error: Remote command failed with exit status 1

2. I had to manually install the missing module.properties file by
downloading it from the server repository
After which the command above works fine.

3. However the attempt to execute a command in the custom module fails
due to the following error:
[root@ctier-server ~]# ctl -p E4-QA -I tags=q02 -m MyJBoss -c
controlE4 -- -cmd status
Error: The following error occurred while executing this line:
/opt/software/ctier/ctl/projects/E4-QA/modules/MyJBoss/lib/command.xml:
10: "${entity.attribute.mgmtStrategy}" management strategy is not
supported: cannot load /opt/software/ctier/ctl/projects/E4-QA/modules/
MyJBoss/lib/strategies/${entity.attribute.mgmtStrategy}.xml.
Error: Remote command failed with exit status 1

If I edit the following file and remove the file check mentioned in
the error, the command could be executed successfully.
/opt/software/ctier/ctl/projects/E4-QA/modules/MyJBoss/lib/command.xml

<condition>
<not>
<available file="${module.dir}/lib/strategies/$
{entity.attribute.mgmtStrategy}.xml"/>
</not>
</condition>
</fail>

Unfortunately I couldn't come up with any explanation for these weird
errors. I am using no-standard port (7080) for ControlTier and
version CTL version 3.6.1 (20110924). The non-standard port has been
source of issues in the past.

Why are these files missing?

Thanks,

Dimitar

Anthony Shortland

unread,
Jun 12, 2012, 12:29:40 PM6/12/12
to contr...@googlegroups.com
Hi Dimitar,

Are you sure the module has been properly built and staged in the ControlTier server?

By the way, having created the new sub-type if you made an instance and assigned it to your target node (in Workbench) you could use "ctl-project" to install it cleanly in the client.

Anthony.
> --
> You received this message because you are subscribed to the Google Groups "ControlTier" group.
> To post to this group, send email to contr...@googlegroups.com
> To unsubscribe from this group, send email to controltier...@googlegroups.com
> For more options, visit this group at http://groups.google.com/group/controltier?hl=en
> http://wiki.controltier.org


dimitar

unread,
Jun 12, 2012, 5:47:36 PM6/12/12
to contr...@googlegroups.com
Hi Anthony,

I just did that and ctl-project execute without any errors on the two QA nodes. Three sub-type MyJBoss instances are assigned to two nodes each in the E4-QA project.  Everything is fine until I try to run a command from the sub-type MyJBoss module:

ctl -p E4-QA  -m MyJBoss -c controlE4 -- -cmd status

Error: The following error occurred while executing this line:
/opt/software/ctier/ctl/projects/E4-QA/modules/MyJBoss/lib/command.xml:10: "${entity.attribute.mgmtStrategy}" management strategy is not supported: cannot load /opt/software/ctier/ctl/projects/E4-QA/modules/MyJBoss/lib/strategies/${entity.attribute.mgmtStrategy}.xml

$ ls -l /opt/software/ctier/ctl/projects/E4-QA/modules/E4JBoss/lib/strategies
ls: /opt/software/ctier/ctl/projects/E4-QA/modules/E4JBoss/lib/strategies: No such file or directory

It looks like some file don't get installed with the deployment of the module on the nodes. I don't see any errors in creation of the module. I can query it with ctl -p E4-QA  -m MyJBoss on both nodes in the project.

Thanks,

Dimitar
> To unsubscribe from this group, send email to controltier-unsubscribe@googlegroups.com

Anthony Shortland

unread,
Jun 12, 2012, 11:00:27 PM6/12/12
to contr...@googlegroups.com
Looking at your error messages, not only is there no type level attribute value for "entity.attribute.mgmtStrategy" set, but the command.xml is trying to resolve the location for the strategy file in your MyJBoss sub-type (when its located in JBossServer module super type that I'm assuming you're using).

I should note that the JBossServer module is not designed to run "statically" and hence should be invoked via a resource. e.g.:

ctl -p E4-QA -t  MyJBoss -r myResource -c controlE4 -- -cmd status
 
Anthony.
 
To unsubscribe from this group, send email to controltier...@googlegroups.com

dimitar

unread,
Jun 20, 2012, 5:27:16 PM6/20/12
to contr...@googlegroups.com

I think the source of my problems is the use of the non-default HTTP port (7080) for the ControlTier server. After a client installation or project deployment I have to manually edit the port settings in the client project properties file.  I consider this as a bug in ContolTier because the clients were installed with the correct server name and ports values.

I'll try to implement the desired functionality with the scripting approach first and later try to repeat the tests with a default CT server installation.

Dimitar
Reply all
Reply to author
Forward
0 new messages