Bringing together the Apache Cassandra experts from the community and DataStax.

Want to learn? Have a question? Want to share your expertise? You are in the right place!

Not sure where to begin? Getting Started

 

question

dickescheid avatar image
dickescheid asked Erick Ramirez edited

What is the location of the LCM database in the OpsCenter Docker image?

Hi DataStax Community,

I am running Opscenter in a docker container and have set up and managed a dse development cluster with it. I have mounted the volume:

/opt/opscenter/conf:/opt/opscenter/conf

in the hopes it would persist my configurations.

I have now updated the docker image to a newer version, and found out that the LCM configurations did not persist. I re-added the cluster to the Lifecycle Manager, sadly the config-profile was not taken over (which is stated in the documentation as I found out later).

Is there a way to export the config-profile from the old image (I took a backup of the old image just in case), and import it into the new docker image?

I was not able to find the path where the config-profiles are stored.

The only volume created by docker under `/var/lib/docker/volumes/` is `/var/lib/opscenter` and it only contains the directory `ssl` (both in the new and in the old containers).

opscenterdockerlifecycle manager
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

1 Answer

dickescheid avatar image
dickescheid answered dickescheid edited

I found it!

it is stored in: `/opt/opscenter/lcm.db`

In case someone needs it, I copied out the file with:

docker cp containername:/opt/opscenter/lcm.db /local/location/lcm.db

and mount it into the docker container. Example docker-compose.yaml:

version: '3'
services:
  opscenter:
    image: "datastax/dse-opscenter:6.8.18"
    expose:
      - 8888
    ports:
      - 8443:8443
      - 50031:50031
      - 61620:61620
    environment:
      - DS_LICENSE=accept
    restart: always
    volumes:
        - /opt/opscenter/conf:/opt/opscenter/conf
        - /opt/opscenter/lcm.db:/opt/opscenter/lcm.db
        - /opt/opscenter/passwd.db:/opt/opscenter/passwd.db
        - /opt/ssl/certificate/location:/var/lib/opscenter/ssl/


and make sure the file access rights are set so that the docker user can read and write.

  • User: Opscenter
  • UID: 998
  • GID: 998
Share
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.