On Feb 6, 2008 1:14 PM, Timothy Mizas <[EMAIL PROTECTED]> wrote:
> Hi,
> I've been trying to set up roller to connect to an oracle db and have been 
> having some issues. I've changed the roller-custom.properties to:
>
> installation.type=auto
> database.configurationType=jdbc
> database.jdbc.driverClass=oracle.jdbc.pool.OracleDataSource
> database.jdbc.connectionURL=jdbc:oracle:thin:@url:1521:wdb1/dbname
> database.jdbc.username=user
> database.jdbc.password=pass
> hibernate.dialect=org.hibernate.dialect.Oracle9Dialect

Assuming your connectionURL, username and passwords are correct that looks good.

You don't need the hibernate.dialect property.


> and the roller xml to:
> <Context path="/roller"
>   docBase="/roller" debug="0">
>   <Resource name="jdbc/dbname" auth="Container"
>       type="javax.sql.DataSource"
>     driverClassName="oracle.jdbc.OracleDriver"
>     url="jdbc:oracle:thin:@url:1521:wdb1/dbname"
>     username="user"
>     password="pass"
>     maxActive="20"
>     maxIdle="3"
>     removeAbandoned="true"
>     maxWait="3000" />
> </Context>
>
> and in the web.xml inside roller/WEB-INF I change the resource to:
>
> <resource-ref>
>             <res-ref-name>jdbc/dbname</res-ref-name>
>             <res-type>javax.sql.DataSource</res-type>
>             <res-auth>Container</res-auth>
>     </resource-ref>

Since you are using installation.type=jdbc instead of JNDI you don't
need to have that <Resource> definition in your roller.xml file, nor
do you need that resource ref. For type=jdbc, all you need are those
properties you set in roller-custom.properties.


> I'm using a different dbname other than "rollerdb". I'm not sure if roller 
> supports this, so that could be my issue and I'm also not sure if I've set 
> everything up correctly to work for oracle. For a while I was getting an 
> error saying "ORA-12505, TNS:listener does not currently know of SID given in 
> connect descriptor" and then I realized that I still had settings pointing to 
> rollerdb instead of the custom dbname. So I changed that and now I get 
> "javax.naming.NameNotFoundException: Name rollerdb is not bound in this 
> Context".
>
> Has anyone set up roller to connect to Oracle or a different db name that 
> could give me some info on how to do this?

Sounds like Roller is not able to find your roller-custom.properties
file. Check your logs, do they say anything about
roller-custom.properties?

Where did you put roller-custom.properties? The right location is
tomcat/common/classes (TC5x) or tomcat/lib (for TC6).

- Dave

Reply via email to