TECHZEN Zenoss User Community ARCHIVE  

Zenoss Core 5 - Use serviced to mount an external directory inside a container t ...

Subject: Zenoss Core 5 - Use serviced to mount an external directory inside a container to run scripts
Author: Ken Jenkins
Posted: 2015-03-30 21:20

I would like to mount a Zenoss Master host directory into the Zenoss Core docker container. The directory would contain python scripts that I would like to run using zendmd.

I have another forum post asking how cron should be managed to schedule tasks in Zenoss Core 5 but nobody responded. http://www.zenoss.org/forum/4686

My plan was to mount the directory in a container (say /mnt) and set up cron on the Zenoss Master host to run commands in Zenoss containers using serviced to trigger discovery and device property enrichment tasks.

Can some provide me with the serviced mount command to do this with There are docker commands to do this with but I am not sure if using docker is appropriate.

I could also use some serviced examples as to how to kick off a command in a docker container and have results output to a file on the host server.

I am still trying to figure out how to navigate the containers using serviced. I tried this command and it does not seem to work.

serviced service shell Zenoss.Core su - zenoss -c " ZENHOME=/opt/zenoss source /home/zenoss/.bashrc & /opt/zenoss/bin/zenstatus status"
I0331 02:16:40.658509 17149 server.go:341] Connected to the control center at port ##.##.##.##:4979
I0331 02:16:40.802165 17149 server.go:435] Acquiring image from the dfs...
I0331 02:16:40.804575 17149 server.go:437] Acquired! Starting shell
not running
exit status 3

If I am on the wrong track with how this should be done, please let me know.

Help is appreciated.

Thanks,
Ken



Subject: please consult this thread (I
Author: Andrew Kirch
Posted: 2015-03-31 16:01

please consult this thread (I think it's also your thread) for an answer regarding ZenDMD and Zenoss 5. http://www.zenoss.org/forum/4686

Andrew Kirch

akirch@gvit.com

Need Zenoss support, consulting or custom development Look no further. Email or PM me!

Ready for Distributed Topology (collectors) for Zenoss 5 Coming May 1st from GoVanguard



Subject: Hi There,
Author: [Not Specified]
Posted: 2015-10-06 11:46

Hi There,

I was interested in getting a mount command where i can attach to the master host in order to run a few customized commands to monitor a few devices

Moreover is there any way through which I can inject those scripts inside of the docker container

Cheers



Subject: Isn't there any way through
Author: [Not Specified]
Posted: 2015-10-06 14:09

Isn't there any way through which we can mount the directory from the master host inside the container

Can we not use the serviced --mount for this purpose



Subject: Is there any new idea to mount new volume?
Author: [Not Specified]
Posted: 2016-06-11 00:33

Hello,

I tested that Zenoss use nfs server to export opt/serviced/var/volumes, Is there any way to write here via ntfs protocol

Another optionI think if I change zenoss json template I could add a new volume a container (zope i.e) ,

a host server directory like "opt/serviced/var/volumes" .



< Previous
Is there a supported method for deploying services to new resource hosts documen ...
  Next
Zenoss Core 5 - What is the best practice to manage / run custom scripts in Core ...
>