ITeye博客

EMS6.0配置存储到数据库过程中遇到的问题

zhb8015 · 2011-11-09 11:12 · Markdown

配置过程:

1Enable the database store feature in the tibemsd.conf by setting the parameters

2Setup and configure stores in the stores.conf file

3

Associate destinations with the configured stores.

4Export database tables

(具体过程参见user guide和sample--config--tibemsd-db.conf)

具体文件:

tibemsd.conf:

dbstore_classpath=c:\lib\antlr-2.7.6.jar;c:\lib\c3p0-0.9.1.jar;c:\lib\commons-collections-3.1.jar;c:\lib\commons-logging.jar;c:\lib\dom4j-1.6.1.jar;c:\lib\hibernate3.jar;c:\lib\hibernate-cglib-repack-2.1_3.jar;c:\lib\javassist-3.4.GA.jar;c:\lib\jta-1.1.jar;c:\lib\oscache-2.1.jar;c:\lib\ojdbc6.jar;c:\lib\ojdbc14.jar;c:\lib\slf4j-api-1.5.6.jar;slf4j-log4j12-1.5.6.jar;c:\lib\slf4j-nop-1.5.6.jar
dbstore_driver_name = oracle.jdbc.driver.OracleDriver
dbstore_driver_dialect = org.hibernate.dialect.Oracle10gDialect
jre_library="C:\Program Files\Java\jdk1.6.0_27\jre\bin\server\jvm.dll"

stores.conf:

[$sys.meta]
type=dbstore
dbstore_driver_url=jdbc:oracle:thin:@10.60.109.12:1521:tibcodev
dbstore_driver_username=test
dbstore_driver_password=1234

[$sys.failsafe]
type=dbstore
dbstore_driver_url=jdbc:oracle:thin:@10.60.109.12:1521:tibcodev
dbstore_driver_username=test
dbstore_driver_password=1234

配置过程中的问题:

1 报错:Exception in thread "main" java.lang.NoClassDefFoundError: org/hibernate/HibernateException

对比以上的包,如不缺少包,检查一下分隔符,window---";" linux---":",我就忘记了。

2 报错:Exception in thread "main" java.lang.IllegalAccessError: tried to access field org.slf4j.impl.StaticLoggerBinder.SINGLETON from class org.slf4j.LoggerFactory

参考文章:

http://hi.baidu.com/fif%B7%E7%D4%C6/blog/item/840b12ef234504272df534ad.html

http://www.blogjava.net/zeroline/archive/2010/11/21/338622.html

在类路径先将slf4j-api.jar删除,再导入同版本的slf4j-api-1.5.6.jar和slf4j-log4j12-1.5.6.jar,问题可解决

心得 :多多查看文档和资料,和相关的人士请教经验,以免走弯路。

评论(0)

暂无评论。

评论功能维护中,当前仅展示历史评论。