With port=3307 option only it will not pick the right instance:
[root@multi ~]# bash -x pt-stalk --no-stalk --iterations=2 --sleep=30 --user=root --password=p3rc0na --port=3307 > stalk.out 2>&1
[root@multi ~]# grep ^port /var/lib/pt-stalk/*-variables
/var/lib/pt-stalk/2016_11_25_04_49_31-variables:port 3306
/var/lib/pt-stalk/2016_11_25_04_50_01-variables:port 3306
Using the socket will pick the right instance:
[root@multi ~]# bash -x pt-stalk --no-stalk --iterations=2 --sleep=30 --user=root --password=p3rc0na --socket=/tmp/mysql1.sock > stalk1.out 2>&1
[root@multi ~]# grep ^port /var/lib/pt-stalk/*-variables
/var/lib/pt-stalk/2016_11_25_04_49_31-variables:port 3306
/var/lib/pt-stalk/2016_11_25_04_50_01-variables:port 3306
/var/lib/pt-stalk/2016_11_25_04_57_36-variables:port 3307
/var/lib/pt-stalk/2016_11_25_04_58_06-variables:port 3307
attaching stalk.out file using the port=3307 option only
With port=3307 option only it will not pick the right instance: pt-stalk/ *-variables pt-stalk/ 2016_11_ 25_04_49_ 31-variables: port 3306 pt-stalk/ 2016_11_ 25_04_50_ 01-variables: port 3306
[root@multi ~]# bash -x pt-stalk --no-stalk --iterations=2 --sleep=30 --user=root --password=p3rc0na --port=3307 > stalk.out 2>&1
[root@multi ~]# grep ^port /var/lib/
/var/lib/
/var/lib/
Using the socket will pick the right instance: /tmp/mysql1. sock > stalk1.out 2>&1 pt-stalk/ *-variables pt-stalk/ 2016_11_ 25_04_49_ 31-variables: port 3306 pt-stalk/ 2016_11_ 25_04_50_ 01-variables: port 3306 pt-stalk/ 2016_11_ 25_04_57_ 36-variables: port 3307 pt-stalk/ 2016_11_ 25_04_58_ 06-variables: port 3307
[root@multi ~]# bash -x pt-stalk --no-stalk --iterations=2 --sleep=30 --user=root --password=p3rc0na --socket=
[root@multi ~]# grep ^port /var/lib/
/var/lib/
/var/lib/
/var/lib/
/var/lib/
attaching stalk.out file using the port=3307 option only