日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當(dāng)前位置: 首頁 > 运维知识 > 数据库 >内容正文

数据库

mysql远程访问时间长无反应_远程MySQL访问需要很长时间

發(fā)布時(shí)間:2023/12/2 数据库 38 豆豆
生活随笔 收集整理的這篇文章主要介紹了 mysql远程访问时间长无反应_远程MySQL访问需要很长时间 小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.

Running a MySQL query on a local database takes only about 20-30ms but running the same query through a remote connection(internet) takes 500ms. Is this normal? If not what could be the possible reason for such delay?

This is a wireshark time extract for a particular Query run remotely.

Time -195.768993000 --- Request Ping

Time -195.909453000 --- Response OK

Time -195.909729000 --- Request Use Database

Time -196.049567000 --- Response OK

Time -196.049918000 --- Request Query

Time -196.219660000 --- Response

NOTE: I tried running the same query remotely through workbench and the duration of execution was 200ms.This I think matches time taken from 'Request Query' to 'Response' in C# as shown in the wireshark data above.

Talk1:

how many rows it will return ?

Talk2:

May be 100. But that doesn't matter as "Request Ping to Request Query" only takes about 300ms.

Talk3:

can't you check the query by running directly on server with ssh

Talk4:

If I am right SSH only encrypts your connection it will not increase the throughput.

Talk5:

yes but it not needs to download the data to your local server, it will show you correct time of execution

Solutions1

It could be because of a DNS problem. You can disable DNS host name lookups by starting mysqld with the --skip-name-resolve option in the configuration file.

Talk1:

You checked again after restarting the server, right?

Talk2:

Ya, it seems that a remote connection would always have that time difference.

總結(jié)

以上是生活随笔為你收集整理的mysql远程访问时间长无反应_远程MySQL访问需要很长时间的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯(cuò),歡迎將生活随笔推薦給好友。