Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify Docker Setup for PMM Agent/Client #978

Open
Johnson145 opened this issue Feb 3, 2023 · 2 comments · May be fixed by #1299
Open

Clarify Docker Setup for PMM Agent/Client #978

Johnson145 opened this issue Feb 3, 2023 · 2 comments · May be fixed by #1299
Assignees

Comments

@Johnson145
Copy link

Johnson145 commented Feb 3, 2023

I'm trying to setup the PMM client/agent with docker for the first time. Setting up the server with docker was pretty straightforward, but I feel like the client setup documentation is quite confusing.

In the last part of the relevant section the following is given:

Run the container to start PMM Agent in setup mode.
[...]
You can now add services with pmm-admin by prefixing commands with docker exec pmm-client.

Isn't there missing something in between? How do I run the container without the setup mode? If I just restart the container, it complains that the associated node name is already registered. If I remove all environment vars from the call, it fails after complaining that you should run a setup. I tried setting PMM_AGENT_SETUP from 1 to 0, but that didn't help either.


Furthermore, the next section after the Install -> Docker one is once again Register. That doesn't make sense, does it? Shouldn't the latter affect only the non-docker ways of installing?


Maybe I'm just missing something obvious. Support for clarification is appreciated very much!

@Johnson145
Copy link
Author

More or less I got it running by reducing the first command to

docker run \
--rm \
--name pmm-client \
-e PMM_AGENT_CONFIG_FILE=config/pmm-agent.yaml \
--volumes-from pmm-client-data \
percona/pmm-client:2

(having dropped most environment variables)

and then registering independently of the above call

docker exec pmm-admin config --server-insecure-tls --server-url=https://admin:[email protected]:443

Not sure whether that's a suggested combination.

I guess it makes sense to clarify the documentation either or.

@laurent-indermuehle
Copy link

@Johnson145 I'm facing the same issue as you, I agree that the documentation is lacking some steps.

I also noticed that many folder are owned by root, but the container runs as user 1002 pmm-agent. So inside the container I encounter a lot of permission denied.

When we say: PMM_AGENT_CONFIG_FILE=config/pmm-agent.yaml to where this relative path point to? In my logs I saw this:

Loading configuration file /usr/local/percona/pmm2/config/pmm-agent.yaml. component=main

But the file is empty.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants