org.quartz.impl.jdbcjobstore.LockException
说明:在使用Tomcat6.0.32+Spring3.05+Quartz1.8.6+Mysql5.5.9 此项目在我本机上没有问题,当我把mysql 脚本导入到服务器上,将数据源配置修改为服务器对应的mysql时,再次运行程序出现以下问题,
错误信息如下:
严重: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'scheduler' defined in ServletContext resource [/WEB-INF/spring-conf.xml]: Invocation of init method failed; nested exception is org.quartz.SchedulerConfigException: Failure occured during job recovery. [See nested exception: org.quartz.impl.jdbcjobstore.LockException: Failure obtaining db row lock: Table 'wzhpush2.qrtz_LOCKS' doesn't exist [See nested exception: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table 'wzhpush2.qrtz_LOCKS' doesn't exist]]
明明我的表都是存在的,却提示:Table 'wzhpush2.qrtz_LOCKS' doesn't exist。
最后找到原因是:我本地是Window平台,此平台下面Mysql默认是不区分下小写的,而服务器时Linux平台,在linux平台下面Mysql默认是严格区分大小写的。此时,修改Mysql配置文件让其不区分大小写,问题解决。。
>sudo vim /etc/mysql/my.cnf
在[mysqld]下面添加:
lower_case_table_names = 1
然后保存退出,重启Mysql
>sudo restart mysql
org.quartz.impl.jdbcjobstore.LockException的更多相关文章
- 关于Failed to convert property value of type [org.quartz.impl.StdScheduler] to required type [org.springframework.scheduling.quartz.SchedulerFactoryBean
在一个业务类有下列属性 private SchedulerFactoryBeanscheduler; public SchedulerFactory BeangetScheduler() { retu ...
- quartz报错 org.quartz.impl.StdSchedulerFactory.
quartz任务执行报错 Exception in thread "main" java.lang.NoClassDefFoundError: org/slf4j/LoggerFa ...
- Spring+quartz 实现定时任务job集群配置
为什么要有集群定时任务? 因为如果多server都触发相同任务,又同时执行,那在99%的场景都是不适合的.比如银行每晚24:00都要汇总营业额.像下面3台server同时进行汇总,最终计算结果可能是真 ...
- Spring+quartz 实现定时任务job集群配置【原】
为什么要有集群定时任务? 因为如果多server都触发相同任务,又同时执行,那在99%的场景都是不适合的.比如银行每晚24:00都要汇总营业额.像下面3台server同时进行汇总,最终计算结果可能是真 ...
- Spring Quartz *.QRTZ_LOCKS' doesn't exist
ERROR [org.springframework.web.context.ContextLoader] - Context initialization failedorg.springframe ...
- 警惕挂着开源的招牌到处坑蒙拐骗的垃圾项目,比如iBase4J
开源界,本是技术爱好者百花齐放.各显其能的地方.但是,不管什么好东西,到了这块奇葩的土地都能变了味.现在的开源界,真的是鱼龙混杂,有些开源软件,不知道是噱头喊得高,还是star刷得好,竟能凭借一身垃圾 ...
- Quartz集群
为什么选择Quartz: 1)资历够老,创立于1998年,比struts1还早,但是一直在更新(27 April 2012: Quartz 2.1.5 Released),文档齐全. 2)完全由Jav ...
- 项目中使用Quartz集群分享--转载
项目中使用Quartz集群分享--转载 在公司分享了Quartz,发布出来,希望大家讨论补充. CRM使用Quartz集群分享 一:CRM对定时任务的依赖与问题 二:什么是quartz,如何使用, ...
- 【Quartz】配置最简单的集群
在许多情况,我们希望我们的定时任务是可靠的,不会因系统故障.机器宕机而导致某一笔定时任务不能按时运行.这种情况下,我们就需要为Quartz做个集群. 最简单的情况,有两台机器或两个应用,同时维护一批定 ...
随机推荐
- 行为级和RTL级的区别(转)
转自:http://hi.baidu.com/renmeman/item/5bd83496e3fc816bf14215db RTL级,registertransferlevel,指的是用寄存器这一级别 ...
- bzoj 1912 巡逻(树直径)
Description Input 第一行包含两个整数 n, K(1 ≤ K ≤ 2).接下来 n – 1行,每行两个整数 a, b, 表示村庄a与b之间有一条道路(1 ≤ a, b ≤ n). Ou ...
- 关于google的C++ coding style
大家都知道google的开源项目有很多,不过我观察过一些开源项目,觉得代码质量就是这家最好了.这些“教条”式规定的背后是是来自于常年工程经验积累上的理性思考. 为什么好?主要有以下几点: 1.规范,就 ...
- Android添加横线和竖线分割界面
竖线 <View android:layout_width="1dip" android:layout_height="match_parent ...
- Linux中使用mysqldump对MySQL数据库进行定时备份
#!/bin/bash PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin export PATH expo ...
- UESTC_Just a Maze CDOJ 1162
Just a Maze Time Limit: 3000/1000MS (Java/Others) Memory Limit: 262144/262144KB (Java/Others) Su ...
- Inorder Successor in BST 解答
Question Given a binary search tree and a node in it, find the in-order successor of that node in th ...
- <转载>模板声明中template <typename T>和template <class T>
原文地址http://blog.csdn.net/bug07250432/article/details/10150625 在c++Template中很多地方都用到了typename与class这两个 ...
- 打造自己个性的notepad ++
对coder来说,notepad ++ 是一个很不错的文本编辑器.平时用来看看代码.xml文件,都比系统自带的记事本舒服得多.不过,对于像我这种每天用notepad ++写代码的人,一个原装的note ...
- WPF可视化控件打印
Introduction While coding an application that displays a detailed report in a ScrollViewer, it was d ...