Running in container

12 views
Skip to first unread message

Joseph McGrath

unread,
Jun 26, 2020, 8:26:38 AM6/26/20
to beat-devel
When running a .so library in a container, does it load the dependencies from the container itself? I'm having trouble getting the linking with OpenCV to work, despite the environments being consistent between cxxdev and cxx. 

I've included the log of what happens below:

[23/Jun/2020 21:11:08 - beat.core.dock] DEBUG: Creation and start of a container: image=beatenv/beat.env.cxx:2.0.0r3, command="execute --debug --cache=/beat/cache tcp://192.168.0.169:53664 /beat/prefix tcp://172.17.0.4:52339"

[23/Jun/2020 21:11:08 - beat.core.dock] DEBUG: Docker command: docker run --tty --interactive --detach --read-only --network=bridge --user=501:501 --volume=/tmp/beat_otl8qcez:/beat/prefix:ro --volume=/Users/josephmcgrath/Desktop/beat_prefix/cache/d8/39/88/db45d361f82267ef01dd92844dfedb09a802f367bf08b3b279a1dcea1c.db:/beat/cache/d8/39/88/db45d361f82267ef01dd92844dfedb09a802f367bf08b3b279a1dcea1c.db:ro --volume=/Users/josephmcgrath/Desktop/beat_prefix/cache/f3/43/b8:/beat/cache/f3/43/b8:rw beatenv/beat.env.cxx:2.0.0r3 execute --debug --cache=/beat/cache tcp://192.168.0.169:53664 /beat/prefix tcp://172.17.0.4:52339

[23/Jun/2020 21:11:08 - beat.core.dock] DEBUG: Container ID: '533f9865f80bea4e0e4a1a4bae21ddeb1ca1a5ab80c02a79556fd60d179dc0b7'

[23/Jun/2020 21:11:08 - beat.backend.python.execution.messagehandlers] DEBUG: 0MQ server thread started

[23/Jun/2020 21:11:09 - beat.core.dock] DEBUG: Inspect container 87557ea264fbeaa345bc73d03e7676d8368f03af8acfd6116f08ea121415eb75

[23/Jun/2020 21:11:09 - beat.backend.python.execution.messagehandlers] DEBUG: 0MQ server thread stopped

[23/Jun/2020 21:11:10 - beat.core.execution.docker] DEBUG: Log of the container: [2020-06-24 02:11:08.943186] [0x00007f3d83801040] [debug]   0MQ client connected to 'tcp://192.168.0.169:53664'

[2020-06-24 02:11:08.945627] [0x00007f3d83801040] [debug]   0MQ client connected to 'tcp://172.17.0.4:52339'

[2020-06-24 02:11:08.961522] [0x00007f3d83801040] [debug]   0MQ client finished

[sys] Failed to load the algorithm library '/beat/prefix/prefix/algorithms/jmcgrat3/BSIF-Feature-Extraction/1.so', reason: libopencv_stitching.so.3.4: cannot open shared object file: No such file or directory

SG

unread,
Jun 29, 2020, 5:50:10 AM6/29/20
to beat-devel
Hi,

Yes, everything happens in the context of the container. Therefore all the dependencies required for your algorithm should either be included in the image or you should link them statically to your algorithm.

OpenCV is not part of the CXX images, thus you'll have to link it statically to your algorithm.

Best regards,

SG
Reply all
Reply to author
Forward
0 new messages