1、配置连接池通过IP/console进入管理控制台(如果不知道用户名和密码可以通过以下方式进入:右击StartWebLogic.sh快捷方式,选择“编辑”,在文本中可以找到用户名和密码)
在左侧菜单中依次进入mydomain(自定义的域名称)-服务-JDBC-连接缓冲池
点击“配置新的JDBC Connection Pool... ”
数据类型选择:Oracle
数据库驱动程序选择:Oracle's Driver (Thin) Version:9.0.1,0.2.0,10
点击右下角的“继续”
在名称中写入想要设置的连接池名称如myConnection
数据库名称:要访问的数据库名称
主机名:写入数据库服务器的主机名称或IP地址
端口号默认为:1521
数据库用户名称、密码
点击“继续”
在下一页中点击“测试驱动程序配置”显示“连接成功”
点击“创建和部署”
在新页面的列表中出现mpConnection的配置项
连接池配置完毕
2、配置JDBC数据源
在管理控制台左侧菜单中依次进入mydomain(自定义的域名称)-服务-JDBC-数据源
点击“配置新的JDBC Data Source”
在名称中写入要配置的数据源名称myConnection
在JNDI名称中写入访问的名字pc/ora9)
点击“继续”
在缓冲池名称中选择myConnection
点击“继续”、“创建”
在列表中出现myConnection配置项
数据源配置完毕
异常解决:
<Error><JDBC><001059><Error during Data Source creatrion:mon. ResourceException:DataSource(MeetingDataSource) be created with non-exitstent Pool(connection or multi)(japool)
<Error><EJB><010070><Error activating Platform_AppMng.jar
Exception is:
Unable to deploy EJB:AppInfoEntity from Platform_AppMng.jar:
Weblogic.ejb20.WLDeploymentException:The DataSource with the JNDI name:DataSource Could not be located.Please ensure that the DataSourece has been deployede successfully and that the JNDI Name in your EJB Deployment descriptor is correct.
<Error><Deployer><149231><The slave deployer was unable to set the activation state to true for The application_appsdir_platfor_AppMng.jar
Weblogic.management.ApplicationException:activate failed forPlatform_AppMng.jar
Module Name:Platform_AppMng.jar,Error:Exception activating module:EJBModule(
Platform_AppMng.jar,status=PREPARED)
Unable to deploy EJB:AppInfoEntity from Platform_AppMng.jar
Weblogic.ejb20.WLDeploymentException:The DataSource with the JNDI name:DataSource Could not be located.Please ensure that the DataSourece has been deployede successfully and that the JNDI Name in your EJB Deployment descriptor is correct.
<Alert><WebLogicServer><000297><Inconsistent security configuration,ng.Exception: Certificate expired or not yet valid:
<Emergency><Security><090034><Not listening for SSL,java.io.IOException:Inconsistent Security configuration,Certificate expired or not yet valid:
打开浏览器后页面报错:
Error 500—Internal Server Error
10.5.1 500—Internal Server Error
后台报错:
-log- Config:Failed get Property cop.databaseConnectionUser
-log- Config:Failed get Property cop. databaseConnectionPassword
-log- Config:Failed get Property cop.webappserver Initial Context Factory
-log- Config:Failed get Property cop.webappserver ProviderUrl
-exp- NotFoundException:unable to resolve ‘wegovDataSourece’
-exp- getConnection is failed
-exp- ng.NullPointerException
-exp- process funtion is failed
-exp- wad2.helper.WADHelperException
-exp- WAD-Helper-connection is null
<Error><HTTP><101017><[ServletContext(...)]Root Cause of ServletException
ng.NullPointer Exception
这个异常时JDBC连接池的错误,是用户操作过程中改了数据库用户的密码造成的,解决方法:在JDBC数据库连接池中将密码改掉,然后“apply”,然后重启webLogic问题得到解决。