Page MenuHomePhabricator

Request for access to the beta cluster
Closed, ResolvedPublic

Description

@mpopov and I (@chelsyx) want to be able to test the eventlogging implementation on the beta cluster for Android and iOS app, following this instruction: https://wikitech.wikimedia.org/wiki/Analytics/Systems/EventLogging/TestingOnBetaCluster#How_to_verify_events

However, we cannot get access to the beta cluster:

  • For @chelsyx, it says Authentication failed
  • For @mpopov, connection closed by UNKNOWN port 65535

Sorry if we use the wrong tag for this ticket!

Event Timeline

I added users chelsyx and bearloga to the deployment-prep project. ssh to deployment-prep/beta should authenticate you now.

The connection closed by 65535 may be another issue. The Help:Access page on wikitech may be helpful in troubleshooting that: https://wikitech.wikimedia.org/wiki/Help:Access#Accessing_instances_with_ProxyCommand_ssh_option_(recommended)

Do you still have trouble logging into these instances or can this task be closed?

Yes I can log in to these instances now. Thanks!
@mpopov can you confirm?

I am able to connect to the beta cluster, thanks! But when I try to connect to the mysql database (mysql -h 127.0.0.1 --user=eventlogging --password=68QrOq220717816UycU1 --skip-ssl) it fails:

ERROR 1130 (HY000): Host '127.0.0.1' is not allowed to connect to this MariaDB server

If I remove the hostname from the command (or replace it with -h localhost) and just use mysql --user=eventlogging --password=68QrOq220717816UycU1 --skip-ssl it works, although select @@hostname; yields the following:

+-----------------------+
| @@hostname            |
+-----------------------+
| deployment-eventlog05 |
+-----------------------+

yet when I use that hostname in the command on the beta cluster or locally in Sequel Pro (which is how I prefer to navigate production event logging db), I get:

ERROR 1130 (HY000): Host '10.68.18.180' is not allowed to connect to this MariaDB server

Screen Shot 2018-04-17 at 11.48.57 AM.png (643×654 px, 95 KB)

P.S. I cannot use 'localhost' as the hostname in Sequel Pro without switching from an SSH connection to a Socket one.

According to the manual, specifying nothing is equivalent to specifying localhost, and both use the socket file rather than the network:

A Unix socket file is used if you do not specify a host name or if you specify the special host name localhost.

Using 127.0.0.1 forces mysql to use a TCP/IP connection over the loopback interface. The hostname deployment-eventlog05 is resolved into it's ip address and forces an TCP/IP connection towards that ip address. There doesn't seem to be a user account for either of those, hence both failed for you:

MariaDB [(none)]> select user,host from mysql.user;
+-----------------+-----------+
| user            | host      |
+-----------------+-----------+
| eventlogcleaner | localhost |
| eventlogging    | localhost |
| root            | localhost |
+-----------------+-----------+
3 rows in set (0.00 sec)

I'm far from being an expert on this, but my guess would be that this means that you can only connect via the socket file.

P.S. I cannot use 'localhost' as the hostname in Sequel Pro without switching from an SSH connection to a Socket one.

Why not use the socket then? mysql --socket=/var/run/mysqld/mysqld.sock --user=eventlogging --password=68QrOq220717816UycU1 --skip-ssl works for me, and I'd expect Sequel to work fine as well if you feed it with the correct socket file path. Meh, I misread that as 'switching from an network connection to a socket one'. If Sequel stops you from using the ssh connection it'll indeed not work. In that case I'd probably just try to set up grants for a eventlogging@127.0.0.1 user, but I have no clue whether that'd be the preferred approach.

mpopov claimed this task.

Thanks for the recommendation! I've added eventlogging@127.0.0.1 as a user with the same password.