Can the host of the target-database in the DM tool be configured as the address of the SLB?

Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.

Original topic: DM工具的target-database其host是否可以配置成SLB的地址

| username: 特雷西-迈克-格雷迪

[TiDB Usage Environment] Production Environment
[TiDB Version] v6.1.2
[Reproduction Path] What operations were performed when the issue occurred
[Encountered Issue: Issue Phenomenon and Impact]
Can the host of the target-database in the DM tool be configured as the address of the SLB?
[Resource Configuration]

[Attachment: Screenshot/Log/Monitoring]

| username: 特雷西-迈克-格雷迪 | Original post link

Are there any pitfalls when using SLB? (Just to be cautious)

| username: 特雷西-迈克-格雷迪 | Original post link

I only have one downstream instance. How is your production configured?

| username: 特雷西-迈克-格雷迪 | Original post link

There are multiple TiDB servers, do you understand?

| username: 超7成网友 | Original post link

:rofl: I misread the configuration item…

| username: 超7成网友 | Original post link

Here we use HAProxy, just write the proxy directly.

| username: wakaka | Original post link

T-Mac, feel free to use it. You can use SLB and domain names, and ultimately it will all fall onto one of the TiDB nodes.

| username: 特雷西-迈克-格雷迪 | Original post link

Has it been production-verified? Dear Dawa-wakaka!

| username: wakaka | Original post link

This is how everyone uses it. NBA fans don’t deceive NBA fans.

| username: 特雷西-迈克-格雷迪 | Original post link

I did the test, and it is not possible.

| username: 特雷西-迈克-格雷迪 | Original post link

A bit awkward.

| username: db_user | Original post link

There is absolutely no problem with the HAProxy address configuration on my end. You can try connecting to that address manually. It might be an issue with the security group not being open or some other problem.

| username: 裤衩儿飞上天 | Original post link

Can you connect manually?

| username: CuteRay | Original post link

Whether or not to use the SLB address is not important. The key point is that you need to ensure that the MySQL client can connect when using this address. In simple terms, whether it is the SLB or the TiDB instance address, both are used for external connections to the TiDB cluster. You just need to ensure that the machine where the DM cluster is located can use this host to connect to the TiDB cluster. It doesn’t matter whether this host is an SLB or a TiDB-server instance.

| username: Hacker007 | Original post link

Can you connect using this IP with the MySQL client on the server?

| username: buchuitoudegou | Original post link

As long as the MySQL client can connect using this address, it will work.

| username: 特雷西-迈克-格雷迪 | Original post link

It can be connected using the MySQL client, but not with DM. I asked the teacher, and it seems to be a connection protocol issue. Can anyone explain this?

| username: 裤衩儿飞上天 | Original post link

If the MySQL client can connect, there should be no issue with the connection protocol.
Did you execute the MySQL client connection to SLB on the DM machine? Try using MySQL to connect on the DM machine.