What would keep my configure-, start- & stopHooks from being called?

Hi Bill,

On Thu, Jan 31, 2013 at 11:59 PM, <William [dot] L [dot] West [..] ...> wrote:
> Hi,
>
> I'm converting my code base that uses Orocos 1.x to Orocos 2.0, and have
> succeeded in squishing all the compiler and linker bugs.
>
> However, now I'm seeing that each of my components get constructed, and upon
> exit, get their cleanupHooks called, but their configureHooks, startHooks and
> stopHooks never get called
>
> Anything obvious I should look at?

Are you using an 1.x XML file as an -s argument to the deployer... ?

Normally, AutoConf and AutoStart should still work in 2.x, so if you
kickstart a file,
all these hooks should be called. The signatures of the hooks didn't
change either,
so it's most likely something in the deployer and not in your component.

You should post some output of the -ldebug log level of the deployer because the
info we get now is to vague to draw any conclusions.

>
> Thanks for any ideas,
> Bill.

Peter

What would keep my

Thanks for the response.

Yes, my .cpf files haven't changed since 1.x. Should they? Maybe that's my problem?

I ran the deployer with -ldebug, and the results are below. I grep'ed them for MB (the name of one of my components), but if you need full 400+ lines, I can post that as well.

Thanks!

Bill.

0.118 [ Debug  ][DeploymentComponent::import] Succesfully loaded MB
0.119 [ Info   ][DeploymentComponent::import] Loaded component type 'Rats::Orocos::MB'
0.126 [ Debug  ][DeploymentComponent::loadComponent] Trying to create component MB of type Rats::Orocos::MB
0.126 [ Debug  ][DeploymentComponent::loadComponent] Found factory for Component type Rats::Orocos::MB
0.126 [ Info   ][Thread] Creating Thread for scheduler=ORO_SCHED_OTHER, priority=1, CPU affinity=0, with name='MB'
0.126 [ Info   ][MB] Thread created with scheduler type 'ORO_SCHED_OTHER', priority 0, cpu affinity 15 and period 0 (PID= 9732 ).
0.126 [ Warning][Service::getOperation] No such operation in service 'MB': unintializedEstop
0.127 [ Info   ][DeploymentComponent::loadComponent] Name:MB Server: 0 Naming: 1
0.127 [ Info   ][DeploymentComponent::loadComponent] Adding MB as new peer:  OK.
0.127 [ Debug  ][updateProperty] updateProperties: updating Property PropertyBag MB.
0.127 [ Debug  ][updateProperty] Found Property 'MB': update done.
0.127 [ Info   ][DeploymentComponent::loadComponents] Added component MB to group 0
12.957 [ Info   ][DeploymentComponent::stopComponentsGroup] Stopped MB
12.957 [ Info   ][DeploymentComponent::cleanupComponentsGroup] Cleaned up MB
12.959 [ Debug  ][/home/orocos/rats-dev/build/bin/rats-headless-deployer-corba-gnulinux::main()] Disconnecting MB
12.959 [ Debug  ][/home/orocos/rats-dev/build/bin/rats-headless-deployer-corba-gnulinux::main()] Terminating MB
12.959 [ Debug  ][~Thread] Terminating MB
12.959 [ Info   ][/home/orocos/rats-dev/build/bin/rats-headless-deployer-corba-gnulinux::main()] Disconnected and destroyed MB

What would keep my

On Wed, Feb 6, 2013 at 7:39 PM, <William [dot] L [dot] West [..] ...> wrote:
> Thanks for the response.
>
> Yes, my .cpf files haven't changed since 1.x. Should they? Maybe that's my
> problem?

I don't think so. What you need to do to test this is to start the
deployer without arguments, then enter the command:
kickStart("yourfile.xml") and watch the return value. If it's false,
it means something went wrong during the loading of your components,
and the kickstart aborted (it won't configure/start components if
someting in an earlier phase failed).
If it returns true, it will have configured and started all components
with the AutoStart and AutoConf property set to 1 in your XML file.

>
> I ran the deployer with -ldebug, and the results are below. I grep'ed them
> for MB (the name of one of my components), but if you need full 400+ lines, I
> can post that as well.

It'd be more interesting for us to grep for 'Warning' or 'Error' :-)

Peter

What would keep my

Thanks Peter,

I'll try the kickstart next.

Amazingly, stupidly, I didn't save off the 400 lines of output to re-grep for Warning or Error. And, now I can't repeat the problem, 'cause I got clever and decided to add a log message in toolchain/rtt/rtt/base/TaskCore.cpp to try and trace what was happening when ConfigureHook should be called, but isn't. Then I cd'ed to ../../build and did make install. Big mistake. I guess you can't do that. Now, instead of 400 lines of useful output, I get

orocos@orocos-two:~/rats-dev/build$ 0.016 [ ERROR ][Logger] could not load library '/home/orocos/rats-dev/toolchain/install/lib/orocos/gnulinux/./types/librtt-transport-mqueue-gnulinux.so': /home/orocos/rats-dev/toolchain/install/lib/orocos/gnulinux/./types/librtt-transport-mqueue-gnulinux.so: undefined symbol: _ZN5boost7archive17archive_exceptionC1ENS1_14exception_codeEPKcS4_ 0.019 [ Warning][Logger] Some found plugins could not be loaded ! 0.019 [ Warning][Logger] Corrupted files found in '/home/orocos/rats-dev/toolchain:/home/orocos/rats-dev/toolchain/install/lib/orocos'. Fix or remove these plugins.

Rebuilding Toolchain now, and will try kickstart and repost the 400 lines when that's done.

So, for my information, how should I have rebuilt toolchain? make install clearly isn't it. :)

Thanks,

Bill.

What would keep my

Hi,

Well, whatever I did, it seems permanent. I built a new toolchain, rebuilt my application, and I'm still getting the

undefined symbol: _ZN5boost7archive17archive_exceptionC1ENS1_14exception_codeEPKcS4_ 0.019 [ Warning][Logger] Some found plugins could not be loaded !

error described above.

One thing I noticed during the process of rebuilding Orocos (and I wonder if this relates to my original problem of ConfigureHook never getting called), is when I was doing the "autoproj update" step, I found I am still getting this error:

      'XDG_SESSION_COOKIE'='d4f31fc0f3ea4d48f4bee6b54df952f8-1360087819.148693-606752627'
      '_'='/home/orocos/rats-dev/toolchain/.gems/bin/autoproj'
 
    Wed Feb 06 17:07:41 -0800 2013: running
        /bin/bash /tmp/osdeps_sh20130206-19566-ydi3i1-0
    in directory /home/orocos/rats-dev/toolchain
    Reading package lists...
    Building dependency tree...
    Reading state information...
    E: Couldn't find package ruby-nokogiri

...even though I installed ruby-nokogiri successfully several different ways (synaptic package manager, "gem install nokogiri" that you recommended, and the instructions from nokogiri's website), I still get that error.

Looking back, I imagine I always was, and I just didn't happen to notice it, because despite that, "autoproj fast-build" still succeeds! So, since nokogiri is used to read XML files, could that relate to my problem of my Hooks not getting called? (I know, grasping at straws at this point).

Something else appears to be wrong with my toolchain installation (and my old one too, which I saved off), because I have no utility called kickStart. So, I couldn't try that.

Thanks in advance for any ideas. We may just have to stick with Orocos 1.0, but I'm hoping there's something I just missed.

Bill.

What would keep my

P.S. I realized that "kickStart" is something I should run from within the deployer, but still can't get that far because of the same "Corrupted files" error.

What would keep my

On Thu, Feb 7, 2013 at 2:52 AM, <William [dot] L [dot] West [..] ...> wrote:
> Hi,
>
> Well, whatever I did, it seems permanent. I built a new toolchain, rebuilt
> my application, and I'm still getting the
>
>
> undefined symbol:
> _ZN5boost7archive17archive_exceptionC1ENS1_14exception_codeEPKcS4_ 0.019 [
> Warning][Logger] Some found plugins could not be loaded !

Which boost version, which ubuntu/debian version ?

You can safely remove the file
/home/orocos/rats-dev/toolchain/install/lib/orocos/gnulinux/./types/librtt-transport-mqueue-gnulinux.so

to overcome this temporarily. Alterntively, you can also disable
mqueue in RTT using cmake but it's less trivial since autoproj will
overwrite your cmake config,
so you'll need to disable this option in the autoproj/overrides.rb
file by adding the line:

Autobuild::Package['rtt'].define "ENABLE_MQ", "OFF"

>
>
> error described above.
>
> One thing I noticed during the process of rebuilding Orocos (and I wonder if
> this relates to my original problem of ConfigureHook never getting called),
> is when I was doing the "autoproj update" step, I found I am still getting
> this error:
>
>
>
> 'XDG_SESSION_COOKIE'='d4f31fc0f3ea4d48f4bee6b54df952f8-1360087819.148693-606752627'
> '_'='/home/orocos/rats-dev/toolchain/.gems/bin/autoproj'
>
> Wed Feb 06 17:07:41 -0800 2013: running
> /bin/bash /tmp/osdeps_sh20130206-19566-ydi3i1-0
> in directory /home/orocos/rats-dev/toolchain
> Reading package lists...
> Building dependency tree...
> Reading state information...
> E: Couldn't find package ruby-nokogiri
>
>
> ...even though I installed ruby-nokogiri successfully several different ways
> (synaptic package manager, "gem install nokogiri" that you recommended, and
> the instructions from nokogiri's website), I still get that error.

Hmm. you can ignore it though. It's orogen related and it can live without it.

>
> Looking back, I imagine I always was, and I just didn't happen to notice it,
> because despite that, "autoproj fast-build" still succeeds! So, since
> nokogiri is used to read XML files, could that relate to my problem of my
> Hooks not getting called? (I know, grasping at straws at this point).
>
> Something else appears to be wrong with my toolchain installation (and my old
> one too, which I saved off), because I have no utility called kickStart. So,
> I couldn't try that.
>
> Thanks in advance for any ideas. We may just have to stick with Orocos 1.0,
> but I'm hoping there's something I just missed.
>
> Bill.

Peter

What would keep my

Thanks Peter,

Removing that .so file did the trick!

In answer to your question, we're on Ubuntu 9.10, with boost 1.38. We plan to upgrade to something more modern soon, which is why we wanted to upgrade to Orocos 2.x as well.

Grasping at a straw, do you think my configureHook-not-getting-called problem might disappear if we weren't using an ancient OS and boost? I know, probably not a factor, but had to ask.

Also have to ask, are RTT 1.1 and OCL 1.1 (the versions we're currently using) considered no longer supported? (in case my team gets tired of waiting for me to complete this upgrade).

Thanks,

Bill.

What would keep my

On Thu, Feb 7, 2013 at 12:21 AM, <William [dot] L [dot] West [..] ...> wrote:
> Thanks Peter,
>
> I'll try the kickstart next.
>
> Amazingly, stupidly, I didn't save off the 400 lines of output to re-grep for
> Warning or Error. And, now I can't repeat the problem, 'cause I got clever
> and decided to add a log message in toolchain/rtt/rtt/base/TaskCore.cpp to
> try and trace what was happening when ConfigureHook should be called, but
> isn't. Then I cd'ed to ../../build and did make install. Big mistake.

Make install is a standard installation step of the Orocos Toolchain which won't
mess up your system, so it can't be related to that.

> I
> guess you can't do that. Now, instead of 400 lines of useful output, I get
>
> orocos@orocos-two:~/rats-dev/build$ 0.016 [ ERROR ][Logger] could not load
> library
> '/home/orocos/rats-dev/toolchain/install/lib/orocos/gnulinux/./types/librtt-transport-mqueue-gnulinux.so':
> /home/orocos/rats-dev/toolchain/install/lib/orocos/gnulinux/./types/librtt-transport-mqueue-gnulinux.so:
> undefined symbol:
> _ZN5boost7archive17archive_exceptionC1ENS1_14exception_codeEPKcS4_
> 0.019 [ Warning][Logger] Some found plugins could not be loaded !
> 0.019 [ Warning][Logger] Corrupted files found in
> '/home/orocos/rats-dev/toolchain:/home/orocos/rats-dev/toolchain/install/lib/orocos'.
> Fix or remove these plugins.
>
> Rebuilding Toolchain now, and will try kickstart and repost the 400 lines
> when that's done.
>
> So, for my information, how should I have rebuilt toolchain? make install
> clearly isn't it. :)

It's actually a necessary step in order to use it from another system.
How else did your
application build & link against it ?

Peter