Cm command though httpServer


#1

Hello,

I have installed with succes the httpServer demo apps on FX30 (WP85).
I tried to run “cm” comand though a python (.py) or shell (.sh) but I did not succeed…
Everytime I get this error :
/legato/systems/current/bin/cm: error while loading shared libraries: libComponent_cm.so: cannot open shared object file: No such file or directory
My httpServer is sandboxed, I added the path to libComponent_cm.so to LD_LIBRARY_PATH then run “cm info” but it remains blocked after sending (get using strace) :

(...)
connect(5, {sa_family=AF_LOCAL, sun_path="/tmp/legato/serviceDirectoryClient"}, 110) = 0
sendmsg(5, {msg_name(0)=NULL, msg_iov(1)=[{"D\6\0\0008a26e6c5c2c76df02e412df515bd"..., 264}], msg_controllen=0, msg_flags=0}, 0) = 264
(...)

Finally, I tried to install httpServer unsandboxed but I could not start the application :

root@swi-mdm9x15:~# app start httpServer
Application 'httpServer' is not installed.

Even if httpServer appears when I run “app status”:

[running] atClient
[running] atServer
[running] audioService
[running] avcService
[running] cellNetService
[running] dataConnectionService
[running] fwupdateService
[running] gpioService
[running] modemService
[running] positioningService
[running] powerMgr
[running] secStore
[stopped] smsInboxService
[stopped] tools
[stopped] voiceCallService
[stopped] wifi
[stopped] wifiApTest
[stopped] wifiClientTest
[running] wifiService
[stopped] wifiWebAp
[stopped] httpServer

Is there a method to access cm command though a web server ?

Thanks,

Yohan


#2

Hi, Yohan,

First, we’ve recently discovered a problem in “app start”, where it reports that the app is not installed when actually it just had a problem starting it. Check the logs using logread to see if there’s more information available.

Re. the sandboxed version, I suspect that your app’s sandbox doesn’t have the .so file bind-mounted into it (which you configure using the requires: { file: {} } stuff in the .cdef or .adef files.

Btw, that strace output looks like it’s unrelated to the problem. It shows a successful connection and transmission the Service Directory.

Cheers,

–Jen


#3

@yoh

hi, have you solved your problem?