日韩久久久精品,亚洲精品久久久久久久久久久,亚洲欧美一区二区三区国产精品 ,一区二区福利

關(guān)于Mongodb的“無法從傳輸連接中讀取數(shù)據(jù)”

系統(tǒng) 2820 0

1.初步判定是c#官方驅(qū)動(dòng)沒能及時(shí)釋放連接: http://stackoverflow.com/questions/7446528/mongodb-c-sharp-driver-doesnt-release-connections-then-errors

How many connections does each mongos need?
In a sharded configuration will have 1 incoming connection from the client but may need 1 outgoing connection to each shard (possibly mongos?times the number of nodes if the shard is backed by a replicaset).
This means that the possible number of open connections that a server requires could be ?(1 + (N*M) * C)where N = number of mongos?shards, M = number of replicaset nodes, and C = number of client connections.

Why does ? mongos? never seem to give up connections??
mongos uses a set of connection pools to communicate to each shard (or shard replicaset node). These pools of connections do not currently
constrict when the number of clients decreases. This will lead to a possibly large number of connections being kept if you have even used the mongos
instance before, even if it is currently not being used.?

How can I see the connections used by mongos? ??
Run this command on each instance: mongos
db._adminCommand("connPoolStats" );?

https://jira.mongodb.org/browse/CSHARP-331

2.設(shè)置了sockettimeout=300000沒能生效: http://www.mongodb.org/display/DOCS/Connections ,單位應(yīng)該是ms,不行的話換sockettimeoutms試試~~

應(yīng)該就是這個(gè)原因了,是sockettimeout的單位是tick,不是毫秒。

?

?

?

3.剛開始全部啟動(dòng)測試時(shí),很有可能崩掉一大片

?

4. ? ?社區(qū)給我的答案,沒試過

? http://www.mongodb.org/display/DOCS/Troubleshooting#Troubleshooting-Socketerrorsinshardedclustersandreplicasets

?

5.2012-04-11補(bǔ)充,對mongo重新做了些測試,發(fā)現(xiàn)有兩種情況會導(dǎo)致,一個(gè)連接超時(shí),默認(rèn)是30s,另外一個(gè)是連接的關(guān)閉,不要輕易調(diào)用connect.close

關(guān)于Mongodb的“無法從傳輸連接中讀取數(shù)據(jù)”


更多文章、技術(shù)交流、商務(wù)合作、聯(lián)系博主

微信掃碼或搜索:z360901061

微信掃一掃加我為好友

QQ號聯(lián)系: 360901061

您的支持是博主寫作最大的動(dòng)力,如果您喜歡我的文章,感覺我的文章對您有幫助,請用微信掃描下面二維碼支持博主2元、5元、10元、20元等您想捐的金額吧,狠狠點(diǎn)擊下面給點(diǎn)支持吧,站長非常感激您!手機(jī)微信長按不能支付解決辦法:請將微信支付二維碼保存到相冊,切換到微信,然后點(diǎn)擊微信右上角掃一掃功能,選擇支付二維碼完成支付。

【本文對您有幫助就好】

您的支持是博主寫作最大的動(dòng)力,如果您喜歡我的文章,感覺我的文章對您有幫助,請用微信掃描上面二維碼支持博主2元、5元、10元、自定義金額等您想捐的金額吧,站長會非常 感謝您的哦!!!

主站蜘蛛池模板: 齐齐哈尔市| 申扎县| 四平市| 永善县| 嵩明县| 乌兰察布市| 红河县| 蓬安县| 堆龙德庆县| 靖州| 轮台县| 霸州市| 梨树县| 个旧市| 桃江县| 溧水县| 东至县| 桃园县| 甘肃省| 陆丰市| 弋阳县| 霍州市| 通江县| 交城县| 衡阳县| 武清区| 紫阳县| 晋江市| 金秀| 建阳市| 台江县| 顺义区| 望奎县| 焦作市| 松潘县| 南漳县| 丹江口市| 万盛区| 佛山市| 中牟县| 高青县|