emysql add_poop() 超时出错
来源:互联网 发布:unity3d 第一人称漫游 编辑:程序博客网 时间:2024/06/14 03:03
emysql add_poop() 超时出错
(金庆的专栏)
sample/a_hello.erl 连接本机更改为连接局域网内的MySql服务器:
emysql:add_pool(hello_pool, [{size,1},
{host, "192.168.1.2"},
...
编译运行时会出现超时退出:
D:\...\deps\emysql\samples>erl -pa ../ebin -s a_hello run -s init stop -noshell
add_pool...{"init terminating in do_boot",{{nocatch,{failed_to_recv_packet_header,timeout}},[{init,start_it,1,[{file,"init.erl"},{line,1062}]},{init,start_em,1,[{file,"init.erl"},{line,1034}]}]}}
Crash dump is being written to: erl_crash.dump...done
init terminating in do_boot ()
设置 default_timeout 参数为 10s 就可以成功:
D:\...\deps\emysql\samples>erl -pa ../ebin -s a_hello run -s init
stop -noshell -emysql default_timeout 10000
查看代码,缺省的 default_timeout 为8s。
当MySql没有skip-name-resolve时,连接MySql需要近10秒才能连上,
所以很容易出现超时错误。
已提交问题:
https://github.com/Eonblast/Emysql/issues/174
(金庆的专栏)
sample/a_hello.erl 连接本机更改为连接局域网内的MySql服务器:
emysql:add_pool(hello_pool, [{size,1},
{host, "192.168.1.2"},
...
编译运行时会出现超时退出:
D:\...\deps\emysql\samples>erl -pa ../ebin -s a_hello run -s init stop -noshell
add_pool...{"init terminating in do_boot",{{nocatch,{failed_to_recv_packet_header,timeout}},[{init,start_it,1,[{file,"init.erl"},{line,1062}]},{init,start_em,1,[{file,"init.erl"},{line,1034}]}]}}
Crash dump is being written to: erl_crash.dump...done
init terminating in do_boot ()
设置 default_timeout 参数为 10s 就可以成功:
D:\...\deps\emysql\samples>erl -pa ../ebin -s a_hello run -s init
stop -noshell -emysql default_timeout 10000
查看代码,缺省的 default_timeout 为8s。
当MySql没有skip-name-resolve时,连接MySql需要近10秒才能连上,
所以很容易出现超时错误。
已提交问题:
https://github.com/Eonblast/Emysql/issues/174
0 0
- emysql add_poop() 超时出错
- erlang emysql
- php nginx超时出错
- Erlang学习:MochiWeb + EMySQL
- emysql 源码阅读
- 备份大数据库时出错“由于超时而终止备份”
- 超时
- 超时
- 客户端连接服务器,配置出错“连接超时”或者“无监听程序”解决方法
- 微信支付中容易出错的问题 统一下单超时,速度慢
- 出错
- 出错
- 出错
- 出错
- WCF 由于处理消息时出错或远程主机超过接收超时或者潜在的网络资源问题导致的
- erlang emysql 驱动 提取数据库 中文 出现 无法辨别的情况解决办法
- 套接字连接已中止。这可能是由于处理消息时出错或远程主机超过接收超时或者潜在的网络资源问题导致的。本地套接字超时是“00:01:00”
- sharepoint 2013 打开rdl报表,报表服务器数据库内出错。此错误可能是因连接失败、超时或数据库中磁盘空间不足而导致的
- PHP学习-输出、打印
- 程序员的年龄天花板
- 产品经理专业技能之BRD/MRD/PRD文档撰写
- 浅谈微信卡券功能开发(3)
- C++ 学习笔记
- emysql add_poop() 超时出错
- HTTP协议详解
- 用VBS创建Excel后,打开时却提示“您尝试打开的文件 的格式与文件扩展名指定的格式不一致”
- Android高效加载大图、多图解决方案,有效避免程序OOM
- Android Activity生命周期演示程序的例子
- win32(十)
- 如何将360 F12改成中文
- yum-Couldn't resolve host 'mirrorlist.centos.org'
- 【LeetCode】(204)Count Primes(Easy)