首页 文章 精选 留言 我的

精选列表

搜索[connection],共4506篇文章
优秀的个人博客,低调大师

Dr.Elephant mysql connection error

This is the first time I try to use english to write my blog, so don't jeer at the mistake of my grammar and spelling. Because of multi threaded drelephant will cause JobHistoryServer’s Loads very high, so I stopped it for a strench of time. Until last week, a period pull from JHS patch merge request from github was released. I re-compiled dr. elephant and deploy the new dr. elephant onthe cluster. It seems stable, but on this Monday morning, my leader told me that there were no more counters and any information about cluster jobs in dr. elephant. So I logged in to the server, and check log, then I found this message below. [error]c.j.b.ConnectionHandle-Databaseaccessproblem.Killingoffthisconnectionandallremainingconnectionsintheconnectionpool.SQLState=HY000 And then, I found two things will cause this issue, one of them is selinux config is set to enforcing, change this config value to disabled and reboot the server, it seem good, but still got same error, only not too many. Then I review the code of dr. elephant, I find out that in mysql create table in mysql initializing script of play framework has an issue. the index is too long, I change the index to 250 previously, but if an url is longer then 250, it gone wrong. createindexyarn_app_result_i4onyarn_app_result(flow_exec_id(250)); createindexyarn_app_result_i5onyarn_app_result(job_def_id(250)); createindexyarn_app_result_i6onyarn_app_result(flow_def_id(250)); So I delete this index limitation, and rewrite the sql like this, add a innodb_large_prefix and row_format=dynamic to the table creation script, and finally, no more error log appears… SETGLOBALinnodb_file_format=Barracuda; SETGLOBALinnodb_large_prefix=ON; CREATETABLEyarn_app_result( idVARCHAR(50)NOTNULLCOMMENT'Theapplicationid,e.g.,application_1236543456321_1234567', nameVARCHAR(100)NOTNULLCOMMENT'Theapplicationname', usernameVARCHAR(50)NOTNULLCOMMENT'Theuserwhostartedtheapplication', queue_nameVARCHAR(50)DEFAULTNULLCOMMENT'Thequeuetheapplicationwassubmittedto', start_timeBIGINTUNSIGNEDNOTNULLCOMMENT'Thetimeinwhichapplicationstarted', finish_timeBIGINTUNSIGNEDNOTNULLCOMMENT'Thetimeinwhichapplicationfinished', tracking_urlVARCHAR(255)NOTNULLCOMMENT'ThewebURLthatcanbeusedtotracktheapplication', job_typeVARCHAR(20)NOTNULLCOMMENT'TheJobTypee.g,Pig,Hive,Spark,HadoopJava', severityTINYINT(2)UNSIGNEDNOTNULLCOMMENT'Aggregateseverityofalltheheuristics.Rangesfrom0(LOW)to4(CRITICAL)', scoreMEDIUMINT(9)UNSIGNEDDEFAULT0COMMENT'Theapplicationscorewhichisthesumofheuristicscores', workflow_depthTINYINT(2)UNSIGNEDDEFAULT0COMMENT'Theapplicationdepthinthescheduledflow.Depthstartsfrom0', schedulerVARCHAR(20)DEFAULTNULLCOMMENT'Theschedulerwhichtriggeredtheapplication', job_nameVARCHAR(255)NOTNULLDEFAULT''COMMENT'Thenameofthejobintheflowtowhichthisappbelongs', job_exec_idVARCHAR(800)NOTNULLDEFAULT''COMMENT'Auniquereferencetoaspecificexecutionofthejob/action(jobintheworkflow).Thisshouldfilterallapplications(mapreduce/spark)triggeredbythejobfora particularexecution.', flow_exec_idVARCHAR(255)NOTNULLDEFAULT''COMMENT'Auniquereferencetoaspecificflowexecution.Thisshouldfilterallapplicationsfiredbyaparticularflowexecution.Notethatiftheschedulersupportssub- workflows,thenthisIDshouldbethesuperparentflowexecutionidthattriggeredthetheapplicationsandsub-workflows.', job_def_idVARCHAR(800)NOTNULLDEFAULT''COMMENT'Auniquereferencetothejobintheentireflowindependentoftheexecution.Thisshouldfilteralltheapplications(mapreduce/spark)triggeredbythejobforal lthehistoricexecutionsofthatjob.', flow_def_idVARCHAR(800)NOTNULLDEFAULT''COMMENT'Auniquereferencetotheentireflowindependentofanyexecution.Thisshouldfilterallthehistoricmrjobsbelongingtotheflow.Notethatifyourscheduler supportssub-workflows,thenthisIDshouldreferencethesuperparentflowthattriggeredtheallthejobsandsub-workflows.', job_exec_urlVARCHAR(800)NOTNULLDEFAULT''COMMENT'Aurltothejobexecutiononthescheduler', flow_exec_urlVARCHAR(800)NOTNULLDEFAULT''COMMENT'Aurltotheflowexecutiononthescheduler', job_def_urlVARCHAR(800)NOTNULLDEFAULT''COMMENT'Aurltothejobdefinitiononthescheduler', flow_def_urlVARCHAR(800)NOTNULLDEFAULT''COMMENT'Aurltotheflowdefinitiononthescheduler', PRIMARYKEY(id) )ENGINE=InnoDBDEFAULTCHARSET=utf8ROW_FORMAT=DYNAMIC; createindexyarn_app_result_i1onyarn_app_result(finish_time); createindexyarn_app_result_i2onyarn_app_result(username,finish_time); createindexyarn_app_result_i3onyarn_app_result(job_type,username,finish_time); createindexyarn_app_result_i4onyarn_app_result(flow_exec_id); createindexyarn_app_result_i5onyarn_app_result(job_def_id); createindexyarn_app_result_i6onyarn_app_result(flow_def_id); createindexyarn_app_result_i7onyarn_app_result(start_time); CREATETABLEyarn_app_heuristic_result( idINT(11)NOTNULLAUTO_INCREMENTCOMMENT'Theapplicationheuristicresultid', yarn_app_result_idVARCHAR(50)NOTNULLCOMMENT'Theapplicationid', heuristic_classVARCHAR(255)NOTNULLCOMMENT'NameoftheJVMclassthatimplementsthisheuristic', heuristic_nameVARCHAR(128)NOTNULLCOMMENT'Theheuristicname', severityTINYINT(2)UNSIGNEDNOTNULLCOMMENT'Theheuristicseverityrangingfrom0(LOW)to4(CRITICAL)', scoreMEDIUMINT(9)UNSIGNEDDEFAULT0COMMENT'Theheuristicscorefortheapplication.score=severity*number_of_tasks(map/reduce)whereseveritynotin[0,1],otherwisescore=0', PRIMARYKEY(id), CONSTRAINTyarn_app_heuristic_result_f1FOREIGNKEY(yarn_app_result_id)REFERENCESyarn_app_result(id) ); createindexyarn_app_heuristic_result_i1onyarn_app_heuristic_result(yarn_app_result_id); createindexyarn_app_heuristic_result_i2onyarn_app_heuristic_result(heuristic_name,severity); CREATETABLEyarn_app_heuristic_result_details( yarn_app_heuristic_result_idINT(11)NOTNULLCOMMENT'Theapplicationheuristicresultid', nameVARCHAR(128)NOTNULLDEFAULT''COMMENT'Theanalysisdetailentryname/key', valueVARCHAR(255)NOTNULLDEFAULT''COMMENT'Theanalysisdetailvaluecorrespondingtothename', detailsTEXTCOMMENT'Moreinformationonanalysisdetails.e.g,stacktrace', PRIMARYKEY(yarn_app_heuristic_result_id,name), CONSTRAINTyarn_app_heuristic_result_details_f1FOREIGNKEY(yarn_app_heuristic_result_id)REFERENCESyarn_app_heuristic_result(id) ); createindexyarn_app_heuristic_result_details_i1onyarn_app_heuristic_result_details(name); At last I send a pull request to linkedin on github.com…

优秀的个人博客,低调大师

Failed to get D-Bus connection: Operation not permitted —解决Docker中Cent...

1.解决Docker中CentOS镜像无法使用systemd的问题 如果这让你觉得麻烦,那么你可以直接跳到本文第二部分开始阅读 创建DockerFile mkdir /root/centos-systemd cd /root/centos-systemd vim DockerFile FROM centos:7 ENV container docker RUN (cd /lib/systemd/system/sysinit.target.wants/; for i in *; do [ $i == systemd-tmpfiles-setup.service ] || rm -f $i; done); \ rm -f /lib/systemd/system/multi-user.target.wants/*;\ rm -f /etc/systemd/system/*.wants/*;\ rm -f /lib/systemd/system/local-fs.target.wants/*; \ rm -f /lib/systemd/system/sockets.target.wants/*udev*; \ rm -f /lib/systemd/system/sockets.target.wants/*initctl*; \ rm -f /lib/systemd/system/basic.target.wants/*;\ rm -f /lib/systemd/system/anaconda.target.wants/*; VOLUME [ "/sys/fs/cgroup" ] CMD ["/usr/sbin/init"] ESC :wq 下载镜像并命名为centos-systemd:7 cd /root/centos-systemd docker build --rm -t centos-systemd:7 . 通过centos-systemd:7镜像生成一个名为centos-systemd的容器 docker run -d -i -t --privileged=true --name centos-systemd -v /sys/fs/cgroup:/sys/fs/cgroup:ro centos-systemd:7 连接到名为centos-systemd的容器 docker exec -i -t centos-systemd /bin/bash 测试systemd启动是否成功 systemctl --help 2.使用已经创建好的镜像(本文第二部分) 也可以下载我已经做好的一个支持systemd的镜像 # 下载镜像 docker pull 2233466866/centos-systemd # 通过镜像运行一个名为test的容器 docker run -dit -v /sys/fs/cgroup:/sys/fs/cgroup:ro --name=test --privileged=true 2233466866/centos-systemd

资源下载

更多资源
Mario

Mario

马里奥是站在游戏界顶峰的超人气多面角色。马里奥靠吃蘑菇成长,特征是大鼻子、头戴帽子、身穿背带裤,还留着胡子。与他的双胞胎兄弟路易基一起,长年担任任天堂的招牌角色。

Spring

Spring

Spring框架(Spring Framework)是由Rod Johnson于2002年提出的开源Java企业级应用框架,旨在通过使用JavaBean替代传统EJB实现方式降低企业级编程开发的复杂性。该框架基于简单性、可测试性和松耦合性设计理念,提供核心容器、应用上下文、数据访问集成等模块,支持整合Hibernate、Struts等第三方框架,其适用范围不仅限于服务器端开发,绝大多数Java应用均可从中受益。

Sublime Text

Sublime Text

Sublime Text具有漂亮的用户界面和强大的功能,例如代码缩略图,Python的插件,代码段等。还可自定义键绑定,菜单和工具栏。Sublime Text 的主要功能包括:拼写检查,书签,完整的 Python API , Goto 功能,即时项目切换,多选择,多窗口等等。Sublime Text 是一个跨平台的编辑器,同时支持Windows、Linux、Mac OS X等操作系统。

WebStorm

WebStorm

WebStorm 是jetbrains公司旗下一款JavaScript 开发工具。目前已经被广大中国JS开发者誉为“Web前端开发神器”、“最强大的HTML5编辑器”、“最智能的JavaScript IDE”等。与IntelliJ IDEA同源,继承了IntelliJ IDEA强大的JS部分的功能。

用户登录
用户注册