To help you we would need info about what errors you see in the log
files.
You use JTDS JDBC URIs in the XML config files, so you have to install
that JDBC driver, not Microsoft's (which isn't supported).
Florent
On 9 Jun 2009, at 13:46, Ramon De Abreu wrote:
Hi!
In my work environment i am supposed to set up Nuxeo DM 5.2 with
Microsoft SQL Server.
I have been able to successfully change the default Derby database
to MySQL and also to Postgres but i am having problems with MS SQL
Server.
I supposed that the PostGres setup is basically similar to the MS
SQL server setup so i proceeded to do the same:
Current setup:
Platform: Windows XP
Nuxeo 5.2
MS SQL Server 2005
Jboss 4.2.3.GA
JDK 5.0
I have followed the following FAQ used to setup Postgres and applied
it to MS SQL Server:
http://doc.nuxeo.org/xwiki/bin/view/FAQ/Nuxeo52VcsPostgreSQL
Also, i have used the nuxeo-book-administration.pdf
I have tried installing MS SQL Server 2005 on the current machine
that i have Nuxeo and also on an another pc in the network.
I will comment first my experience with the other pc in the network.
I have downloaded the Microsoft SQL Server JDBC drivers
(sqljdbc_1.0.809.102_enu) and put it in the following directory:
$JBOSS_HOME\server\default\lib
I created a new database called nuxeo on the network pc.
I proceeded to use the Visible Content Store Configuration (i have
not tried the jackrabbit option).
I have modified the following files with what i think is the correct
configuration for MS SQL Server.
1) El contenido de default-repository-config.xml:
$JBOSS_HOME\server\default\deploy\nuxeo.ear\config
<?xml version="1.0"?>
<component name="org.nuxeo.ecm.core.storage.sql.config">
<extension target="org.nuxeo.ecm.core.repository.RepositoryService"
point="repository">
<repository name="default"
factory
="org.nuxeo.ecm.core.storage.sql.coremodel.SQLRepositoryFactory">
<repository name="default">
<indexing>
<!-- configuration MS SQL SERVERS -->
<fulltext catalog="nuxeo" analyzer="english"/>
</indexing>
</repository>
</repository>
</extension>
</component>
2) El contenido del default-repository-ds.xml
C:\opt\jboss\server\default\deploy\nuxeo.ear\datasources
<?xml version="1.0"?>
<!-- MICROSOFT SQL SERVER -->
<connection-factories>
<tx-connection-factory>
<jndi-name>NXRepository/default</jndi-name>
<xa-transaction/>
<track-connection-by-tx/>
<adapter-display-name>Nuxeo SQL Repository DataSource</adapter-
display-name>
<rar-name>nuxeo.ear#nuxeo-core-storage-sql-ra-1.5.1-
SNAPSHOT.rar</rar-name>
<connection-
definition>org.nuxeo.ecm.core.storage.sql.Repository</connection-
definition>
<config-property name="name">default</config-property>
<!-- <config-property name="xaDataSource"
type
=
"java
.lang.String">com.microsoft.sqlserver.jdbc.SQLServerXADataSource</
config-property> -->
<config-property name="xaDataSource"
type="java.lang.String">net.sourceforge.jtds.jdbcx.JtdsDataSource</
config-property>
<config-property name="property"
type="java.lang.String">ServerName=192.168.0.2</config-property>
<config-property name="property"
type="java.lang.String">PortNumber=1433</config-property>
<config-property name="property"
type="java.lang.String">DatabaseName=nuxeo</config-property>
<config-property name="property"
type="java.lang.String">User=ramon</config-property>
<config-property name="property"
type="java.lang.String">Password=admin</config-property>
<max-pool-size>20</max-pool-size>
</tx-connection-factory>
</connection-factories>
I have read somewhere in earlier posts that there has been problems
with the Microsoft JDBC drivers and that one should download the
ones from sourceforge (downloaded and installed .jar in same directory
as the microsoft JDBC one).
You can see that in the above file i have commented the version that
uses the Microsoft drivers in favour of the source forge.
And the same goes for the following files.
Of course, i have tried both cases and none of them work.
3) El contenido del fichero: unified-nuxeo-ds.xml
$JBOSS_HOME\server\default\deploy\nuxeo.ear\datasources
<?xml version="1.0" encoding="UTF-8"?>
<datasources>
<!-- DEFAULT UNIFIED DATASOURCE CONFIGURATION -->
<!--
This is the default unified datasource configuration. All
datasources from nuxeo
points to this datasource so it will use only 1 database.
To use another database than Derby, comment out the following
section and uncomment
your database configuration or add it if not present.
If you wish to use a different database for a service, comment
out the link in the relevant
xxx-ds.xml file and add a datasource configuration.
-->
<!-- Configuration for MS SQL SERVER -->
<local-tx-datasource>
<jndi-name>NuxeoDS</jndi-name>
<connection-url>jdbc:jtds:sqlserver://192.168.0.2:1433/
nuxeo;user=ramon;password=admin;</connection-url>
<driver-class>net.sourceforge.jtds.jdbc.Driver</driver-class>
<!--
<connection-url>jdbc:microsoft:sqlserver://
192.168.0.2:1433;databaseName=nuxeo</connection-url>
<driver-class>com.microsoft.jdbc.sqlserver.SQLServerDriver</
driver-class>
-->
<user-name>ramon</user-name>
<password>admin</password>
<check-valid-connection-sql>;</check-valid-connection-sql>
</local-tx-datasource>
</datasources>
4)El fichero: sql.properties
$JBOSS_HOME\server\default\deploy\nuxeo.ear\config
# Jena database type and transaction mode
org.nuxeo.ecm.sql.jena.databaseType=MsSQL
org.nuxeo.ecm.sql.jena.databaseTransactionEnabled=false
Finally, i execute the run.bat from my JBOSS_HOME\bin
And open firefox:
192.168.0.2:8080/nuxeo
And no connection occurs.
Thanks in advance
Ramon De Abreu
--
Florent Guillaume, Head of R&D, Nuxeo
Open Source, Java EE based, Enterprise Content Management (ECM)
http://www.nuxeo.com http://www.nuxeo.org +33 1 40 33 79 87
_______________________________________________
ECM mailing list
[email protected]
http://lists.nuxeo.com/mailman/listinfo/ecm
To unsubscribe, go to http://lists.nuxeo.com/mailman/options/ecm