PDA

View Full Version : Linux service



rgouyet
May 18th, 2015, 04:24 PM
When i launch the Girder linux service, with this command :


root@ffdefd5a2b8e:/# /opt/girder/Girder6Service




i get this :


Girder License Path "/opt/girder/qt/etc/xdg/Promixis/"
root@ffdefd5a2b8e:/# Girder License Path "/opt/girder/qt/etc/xdg/Promixis/"
Settings::loadFromDisk / could not read settings file: "/root/.local/share/Promixis/Girder 6/settings.json"
GirderDetection::GirderDetection / SERVER
ProxyHandler::updateProcessProxy
ProxyHandler::updateProcessProxy
GirderComServer::start / listening on port 20000
LuaManager::releaseState / LuaTop: 26
loadPlugins / QDir( "/opt/girder/plugins" , nameFilters = { * }, QDir::SortFlags( Name | IgnoreCase ) , QDir::Filters( Dirs|Files|Drives|AllEntries ) ) ("*")
"lib1wire.so"
"lib1wire.so.1"
"lib1wire.so.1.0"
"lib1wire.so.1.0.0"
PluginManager::loadPlugins / loading "lib1wire.so.1.0.0"
"libcm11a.so"
"libcm11a.so.1"
"libcm11a.so.1.0"
"libcm11a.so.1.0.0"
PluginManager::loadPlugins / loading "libcm11a.so.1.0.0"
"libgirderactions.so"
"libgirderactions.so.1"
"libgirderactions.so.1.0"
"libgirderactions.so.1.0.0"
PluginManager::loadPlugins / loading "libgirderactions.so.1.0.0"
"libinsteonplm.so"
"libinsteonplm.so.1"
"libinsteonplm.so.1.0"
"libinsteonplm.so.1.0.0"
PluginManager::loadPlugins / loading "libinsteonplm.so.1.0.0"
"libirdevices.so"
"libirdevices.so.1"
"libirdevices.so.1.0"
"libirdevices.so.1.0.0"
PluginManager::loadPlugins / loading "libirdevices.so.1.0.0"
"libmouse.so"
"libmouse.so.1"
"libmouse.so.1.0"
"libmouse.so.1.0.0"
PluginManager::loadPlugins / loading "libmouse.so.1.0.0"
"libnest.so"
"libnest.so.1"
"libnest.so.1.0"
"libnest.so.1.0.0"
PluginManager::loadPlugins / loading "libnest.so.1.0.0"
"libOsActions.so"
"libOsActions.so.1"
"libOsActions.so.1.0"
"libOsActions.so.1.0.0"
PluginManager::loadPlugins / loading "libOsActions.so.1.0.0"
"libosd.so"
"libosd.so.1"
"libosd.so.1.0"
"libosd.so.1.0.0"
PluginManager::loadPlugins / loading "libosd.so.1.0.0"
"libPIR.so"
"libPIR.so.1"
"libPIR.so.1.0"
"libPIR.so.1.0.0"
PluginManager::loadPlugins / loading "libPIR.so.1.0.0"



it seems it stop to launch.
I get no process like "girder" running.

What is wrong or missing ?

Ron
May 18th, 2015, 05:31 PM
It should go a bit further. Can you remove the PIR-1 plugin and try again?

rgouyet
May 19th, 2015, 01:26 AM
OK, I sucessfully ran Girder in my docker container.
But i had to remove libPRB16.so.1.0.0 and libPIR.so.1.0.0 plugins... Do they need special dependencies ?

Is there a way to add an extra path for lua script ?

Ron
May 20th, 2015, 06:41 AM
1. They both use libusb

2. Sure modify the package.path variable to include your desired path.

rgouyet
May 22nd, 2015, 05:30 PM
2. Sure modify the package.path variable to include your desired path.

How to define that before Girder starts ?

For example, I want to made my plugin available to Girder but the folder where my plugin files are is not under the default path for girder's LUA

If I change the package.path within a script task in my GML file, this update arrives to late for my plugion to be loaded at startup or after a script reinit.

rgouyet
May 27th, 2015, 03:10 PM
Following the previous post, is there a way to define an other folder for Lua scripts and plugin. I need it to allow custom lua to be available outside the girder docker image.

Another question 1
How to allow Girder client to see a Running Girder instance on the local network ?

http://www.promixis.com/forums/attachment.php?attachmentid=6895&stc=1
Is there a port to open for Girder6Service ?


Another question 2
On Linux, where is kept the path to the gml filename ?
I share the path where Girder save its settings but when i start a new docker image from scratch and I points to the same folder, settings are kept except the previously loaded gml file...

Thanks

kimagure
April 21st, 2016, 10:29 AM
Hi.

As I'd like to run Girder on my Centos box, I'm also trying to build my own docker image based on the latest jessie-based version.

I have the same issues as @rgouyet :

- I cannot start the Girder Service if I do not remove the PIR and PRB16 plugins. It's not a big issue for me because I'm not using those, and I probably won't, but for a fully working docker image, if this can be fixed, it would be better ;)

- I'd like to combine both the OOB-provided lua files from the girder/lua folder (inside the docker container) and my own lua libraries (on my linux host)
Can an additional lua folder be specified when starting the Service (some of my lua packages are used in plugins, for example for my parsing classes for my simpleTransport components) ?

Does the Girder6Service generate a log file somewhere ? This could also be exported on the host to be monitored easily...

Thanks

K.

Ron
April 21st, 2016, 10:38 AM
First make sure that GirderService isn't already running.

Second make sure that Girder has the permission to load: https://www.promixis.com/forums/showthread.php?21802-PIR-1-on-Raspberry-Pi

If that doesn't solve it can you give me access to the docker image you are using, I can have a look.

kimagure
April 21st, 2016, 10:53 AM
Sorry, it really seems to be a permission issue.

@rgouyet had already given a possible solution on the docker hub page : using the usb libs require the "--privileged" option when starting the image.
With this flag, there no crash anymore at startup, but this is a security issue (not a big one on a personal network, though).

There are additional docker flags to make the host USB ports available to the container, I'll check those to see if I can find a better solution.

Do you have an answer for the second part of my question (adding an additional lua folder at runtime, maybe with a specific command line argument, or an environment variable ?)

Thanks

K.

Ron
April 21st, 2016, 11:09 AM
as far as providing your own OOB lua files that is easy, modify the package.path to suit your needs. You can do this in startup.lua or rootStartup

kimagure
April 21st, 2016, 12:31 PM
Yes, it's working fine.

With the following commands in my Dockerfile :



RUN mkdir /opt/girder/luaext
VOLUME /opt/girder/luaext
RUN echo "package.path = package.path .. ';/opt/girder/luaext/?.lua'" >> /opt/girder/lua/startup.lua


I'm able to mount a local folder in the /opt/girder/luaext directory of the container, and I can use my own classes there !

Another question : when Girder is running in docker, it does not appear in the "local network" tab of the Girder remote program. I have to use the "internet" tab to manually put my connection information.
Another instance running on my Raspberry Pi is displayed correctly, but after several seconds.
The windows instance is found immediately.

It's probably a firewall configuraiton issue. What mechanism (and tcp/udp ports) is used to "discover" the instances on the LAN ?

K.