[opencms-dev] OpenCMS and MS SQL jdbc drivers
Shawn L Johnston
sjohnston at satshot.com
Thu Jan 30 23:40:57 CET 2003
Hi,
I've read through the list archives on how to use the Microsoft jdbc drivers
instead of the Merant drivers to connect to a MS SQL database, but have
experienced some problems.
My setup is using:
SCO Linux 4.0
jakarta-tomcat 4.0.4-81
Sun JVM 1.4.0_02
MS SQL 2000 SP3
MS JDBC Driver for SQL Version 2.2.0022
OpenCMS 5.0_rc_1
I created a directory in TOMCAT_HOME/webapps directory called opencms and I
unzipped the opencms.war file there.
I then copied the Microsoft jars to ~/opencms/WEB-INF/lib
I edited ~/opencms/WEB_INF/config/opencms.properties in the MS SQL section to
look like
##
# MS SQL
##
# Parameters for the mssql resource-broker
resourcebroker.mssql.class = com.opencms.file.mssql.CmsResourceBroker
resourcebroker.mssql.pool = jdbc:opencmspool:mssql
resourcebroker.mssql.online.pool = jdbc:opencmspool:mssqlonline
resourcebroker.mssql.backup.pool = jdbc:opencmspool:mssqlbackup
resourcebroker.mssql.digest = MD5
resourcebroker.mssql.digest.fileencoding = UTF-8
# Parameters for the mssql connection-pool
pool.mssql.driver = com.microsoft.jdbc.sqlserver.SQLServerDriver
pool.mssql.url =
jdbc:microsoft:sqlserver://server_name:1433;DatabaseName=betaCMS
pool.mssql.user = opencms
pool.mssql.password =
pool.mssql.minConn = 10
pool.mssql.maxConn = 20
pool.mssql.increaseRate = 5
pool.mssql.timeout = 120
pool.mssql.maxage = 360
# Parameters for the online connection-pool
pool.mssql.driver = com.microsoft.jdbc.sqlserver.SQLServerDriver
pool.mssql.url =
jdbc:microsoft:sqlserver://server_name:1433;DatabaseName=betaCMS
pool.mssqlonline.user = opencms
pool.mssqlonline.password =
pool.mssqlonline.minConn = 5
pool.mssqlonline.maxConn = 10
pool.mssqlonline.increaseRate = 5
pool.mssqlonline.timeout = 120
pool.mssqlonline.maxage = 360
I then stopped and restarted tomcat. Then I tried to go through the OpenCMS
setup wizard, but ended up with the following error messages:
Creating database.. Failed
Error while loading driver: [com.microsoft.jdbc.sqlserver.SQLServerDriver,
com.microsoft.jdbc.sqlserver.SQLServerDriver]
java.lang.ClassNotFoundException:
[com/microsoft/jdbc/sqlserver/SQLServerDriver,
com/microsoft/jdbc/sqlserver/SQLServerDriver]
-------------------------------------------
java.lang.NullPointerException
-------------------------------------------
java.lang.NullPointerException... etc
Creating tables... Failed
Error while loading driver: [com.microsoft.jdbc.sqlserver.SQLServerDriver,
com.microsoft.jdbc.sqlserver.SQLServerDriver]
java.lang.ClassNotFoundException:
[com/microsoft/jdbc/sqlserver/SQLServerDriver,
com/microsoft/jdbc/sqlserver/SQLServerDriver]
-------------------------------------------
java.lang.NullPointerException
-------------------------------------------
java.lang.NullPointerException... etc
I'm guessing that it can't find the driver? Any suggestions?
In the opencms.properties file do I need to specify the name of the database
server, or will the setup wizard configure that?
On a related installation question. When you specify the Database Server
connection user you must use the database SA account?
Is the OpenCMS connection user supposed to mean the user that OpenCMS will
connect to the database server as?
Many thanks,
Shawn
More information about the opencms-dev
mailing list