percona/pmm-doc

PMM2: doc issue on page 'MySQL and variants' (setting-up/client/mysql.html) fix adding a service CLI examples

maxkondr opened this issue · 1 comments

Hi,

There are the following examples at https://www.percona.com/doc/percona-monitoring-and-management/2.x/setting-up/client/mysql.html#add-a-service "On the command line"

sudo pmm-admin add mysql --username=pmm --password=pass

and similar.

But in case the PMM Client is deployed via docker container (https://www.percona.com/doc/percona-monitoring-and-management/2.x/setting-up/client/index.html#docker) or docker-compose (https://www.percona.com/doc/percona-monitoring-and-management/2.x/setting-up/client/index.html#docker-compose) there is no 'sudo' in container:

bash-4.2$ sudo pmm-admin add mysql --username=pmm --password=pas

bash: sudo: command not found

Please adjust the examples accordingly.

Thanks. Whether or not to include sudo is a common debate. On one side readers like they can copy/paste commands without intervention. On the other, yes for docker situations the commands fail. I will remove the sudo and rely on reader's technical skills to know whether or not they need to use sudo. I will do this not only for MySQL page, but everywhere. We all know how and when to use sudo, right?