cancel
Showing results for 
Search instead for 
Did you mean: 

Share starts, Alfresco doesn't

roblegge
Champ in-the-making
Champ in-the-making
Hi Guys, having a problem with an installation of Alfresco 3.01, full edition on 30 test license. OS is Windows Enterprise Server 2003 running as a VM on Sun Virtual Box. There's no firewall set up and the enhanced browser security has been de-installed.  No Updates have been applied either, though it has been activated. There's no IPv6.

The installation appeared to run through OK and on running the alf_start.bat file there's appears to be a few problems. The Share WAR gets deployed OK and runs, but the Alfresco WAR appears to cause problems. So http://localhost:8080/share brings up the login page for Share while http://localhost:8080/alfresco returns a 404. Output from the DOSbox is shown below. There appears to be a number of problems here but any help to get this started would be useful.


(AbstractBeanFactory.java:248)
        at org.springframework.beans.factory.support.AbstractBeanFactory.getBean
(AbstractBeanFactory.java:160)
        at org.springframework.beans.factory.support.DefaultListableBeanFactory.
preInstantiateSingletons(DefaultListableBeanFactory.java:287)
        at org.springframework.context.support.AbstractApplicationContext.refres
h(AbstractApplicationContext.java:352)
        at org.springframework.web.context.ContextLoader.createWebApplicationCon
text(ContextLoader.java:244)
        at org.springframework.web.context.ContextLoader.initWebApplicationConte
xt(ContextLoader.java:187)
        at org.springframework.web.context.ContextLoaderListener.contextInitiali
zed(ContextLoaderListener.java:49)
        at org.apache.catalina.core.StandardContext.listenerStart(StandardContex
t.java:3843)
        at org.apache.catalina.core.StandardContext.start(StandardContext.java:4
342)
        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase
.java:791)
        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:77
1)
        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)

        at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:830)

        at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:719
)
        at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:490
)
        at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1149)
        at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java
:311)
        at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(Lifecycl
eSupport.java:117)
        at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)

        at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
        at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)

        at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443
)
        at org.apache.catalina.core.StandardService.start(StandardService.java:5
16)
        at org.apache.catalina.core.StandardServer.start(StandardServer.java:710
)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Cannot load JDBC driver class 'org.gjt.mm.mysql.Driver'
java.lang.ClassNotFoundException: org.gjt.mm.mysql.Driver
        at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoa
der.java:1387)
        at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoa
der.java:1233)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:169)
        at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSou
rce.java:760)
        at org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource
.java:540)
        at org.springframework.orm.hibernate3.LocalDataSourceConnectionProvider.
getConnection(LocalDataSourceConnectionProvider.java:81)
        at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager
.java:423)
        at org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.
java:144)
        at org.hibernate.jdbc.JDBCContext.connection(JDBCContext.java:119)
        at org.hibernate.transaction.JDBCTransaction.begin(JDBCTransaction.java:
57)
        at org.hibernate.impl.SessionImpl.beginTransaction(SessionImpl.java:1326
)
        at org.springframework.orm.hibernate3.HibernateTransactionManager.doBegi
n(HibernateTransactionManager.java:510)
        at org.springframework.transaction.support.AbstractPlatformTransactionMa
nager.getTransaction(AbstractPlatformTransactionManager.java:350)
        at org.springframework.transaction.interceptor.TransactionAspectSupport.
createTransactionIfNecessary(TransactionAspectSupport.java:262)
        at org.springframework.transaction.interceptor.TransactionAspectSupport.
createTransactionIfNecessary(TransactionAspectSupport.java:219)
        at org.alfresco.util.transaction.SpringAwareUserTransaction.begin(Spring
AwareUserTransaction.java:394)
        at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransacti
on(RetryingTransactionHelper.java:309)
        at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransacti
on(RetryingTransactionHelper.java:227)
        at org.alfresco.repo.search.impl.lucene.AbstractLuceneIndexerAndSearcher
Factory$LuceneIndexBackupComponent.afterPropertiesSet(AbstractLuceneIndexerAndSe
archerFactory.java:1441)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1201)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.initializeBean(AbstractAutowireCapableBeanFactory.java:1171)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.createBean(AbstractAutowireCapableBeanFactory.java:425)
        at org.springframework.beans.factory.support.AbstractBeanFactory$1.getOb
ject(AbstractBeanFactory.java:251)
        at org.springframework.beans.factory.support.DefaultSingletonBeanRegistr
y.getSingleton(DefaultSingletonBeanRegistry.java:156)
        at org.springframework.beans.factory.support.AbstractBeanFactory.getBean
(AbstractBeanFactory.java:248)
        at org.springframework.beans.factory.support.AbstractBeanFactory.getBean
(AbstractBeanFactory.java:160)
        at org.springframework.beans.factory.support.DefaultListableBeanFactory.
preInstantiateSingletons(DefaultListableBeanFactory.java:287)
        at org.springframework.context.support.AbstractApplicationContext.refres
h(AbstractApplicationContext.java:352)
        at org.springframework.web.context.ContextLoader.createWebApplicationCon
text(ContextLoader.java:244)
        at org.springframework.web.context.ContextLoader.initWebApplicationConte
xt(ContextLoader.java:187)
        at org.springframework.web.context.ContextLoaderListener.contextInitiali
zed(ContextLoaderListener.java:49)
        at org.apache.catalina.core.StandardContext.listenerStart(StandardContex
t.java:3843)
        at org.apache.catalina.core.StandardContext.start(StandardContext.java:4
342)
        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase
.java:791)
        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:77
1)
        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)

        at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:830)

        at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:719
)
        at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:490
)
        at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1149)
        at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java
:311)
        at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(Lifecycl
eSupport.java:117)
        at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)

        at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
        at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)

        at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443
)
        at org.apache.catalina.core.StandardService.start(StandardService.java:5
16)
        at org.apache.catalina.core.StandardServer.start(StandardServer.java:710
)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
        at sun.reflect.NativeMethodAcce15:03:53,970  ERROR [web.context.ContextL
oader] Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean wit
h name 'luceneIndexBackupComponent' defined in class path resource [alfresco/cor
e-services-context.xml]: Invocation of init method failed; nested exception is o
rg.springframework.transaction.CannotCreateTransactionException: Could not open
Hibernate Session for transaction; nested exception is org.hibernate.exception.G
enericJDBCException: Cannot open connection
Caused by: org.springframework.transaction.CannotCreateTransactionException: Cou
ld not open Hibernate Session for transaction; nested exception is org.hibernate
.exception.GenericJDBCException: Cannot open connection
Caused by: org.hibernate.exception.GenericJDBCException: Cannot open connection
        at org.hibernate.exception.SQLStateConverter.handledNonSpecificException
(SQLStateConverter.java:103)
        at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.j
ava:91)
        at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelp
er.java:43)
        at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelp
er.java:29)
        at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager
.java:426)
        at org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.
java:144)
        at org.hibernate.jdbc.JDBCContext.connection(JDBCContext.java:119)
        at org.hibernate.transaction.JDBCTransaction.begin(JDBCTransaction.java:
57)
        at org.hibernate.impl.SessionImpl.beginTransaction(SessionImpl.java:1326
)
        at org.springframework.orm.hibernate3.HibernateTransactionManager.doBegi
n(HibernateTransactionManager.java:510)
        at org.springframework.transaction.support.AbstractPlatformTransactionMa
nager.getTransaction(AbstractPlatformTransactionManager.java:350)
        at org.springframework.transaction.interceptor.TransactionAspectSupport.
createTransactionIfNecessary(TransactionAspectSupport.java:262)
        at org.springframework.transaction.interceptor.TransactionAspectSupport.
createTransactionIfNecessary(TransactionAspectSupport.java:219)
        at org.alfresco.util.transaction.SpringAwareUserTransaction.begin(Spring
AwareUserTransaction.java:394)
        at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransacti
on(RetryingTransactionHelper.java:309)
        at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransacti
on(RetryingTransactionHelper.java:227)
        at org.alfresco.repo.search.impl.lucene.AbstractLuceneIndexerAndSearcher
Factory$LuceneIndexBackupComponent.afterPropertiesSet(AbstractLuceneIndexerAndSe
archerFactory.java:1441)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1201)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.initializeBean(AbstractAutowireCapableBeanFactory.java:1171)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.createBean(AbstractAutowireCapableBeanFactory.java:425)
        at org.springframework.beans.factory.support.AbstractBeanFactory$1.getOb
ject(AbstractBeanFactory.java:251)
        at org.springframework.beans.factory.support.DefaultSingletonBeanRegistr
y.getSingleton(DefaultSingletonBeanRegistry.java:156)
        at org.springframework.beans.factory.support.AbstractBeanFactory.getBean
(AbstractBeanFactory.java:248)
        at org.springframework.beans.factory.support.AbstractBeanFactory.getBean
(AbstractBeanFactory.java:160)
        at org.springframework.beans.factory.support.DefaultListableBeanFactory.
preInstantiateSingletons(DefaultListableBeanFactory.java:287)
        at org.springframework.context.support.AbstractApplicationContext.refres
h(AbstractApplicationContext.java:352)
        at org.springframework.web.context.ContextLoader.createWebApplicationCon
text(ContextLoader.java:244)
        at org.springframework.web.context.ContextLoader.initWebApplicationConte
xt(ContextLoader.java:187)
        at org.springframework.web.context.ContextLoaderListener.contextInitiali
zed(ContextLoaderListener.java:49)
        at org.apache.catalina.core.StandardContext.listenerStart(StandardContex
t.java:3843)
        at org.apache.catalina.core.StandardContext.start(StandardContext.java:4
342)
        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase
.java:791)
        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:77
1)
        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)

        at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:830)

        at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:719
)
        at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:490
)
        at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1149)
        at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java
:311)
        at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(Lifecycl
eSupport.java:117)
        at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)

        at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
        at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)

        at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443
)
        at org.apache.catalina.core.StandardService.start(StandardService.java:5
16)
        at org.apache.catalina.core.StandardServer.start(StandardServer.java:710
)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Caused by: org.apache.commons.dbcp.SQLNestedException: Cannot load JDBC driver c
lass 'org.gjt.mm.mysql.Driver'
        at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSou
rce.java:766)
        at org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource
.java:540)
        at org.springframework.orm.hibernate3.LocalDataSourceConnectionProvider.
getConnection(LocalDataSourceConnectionProvider.java:81)
        at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager
.java:423)
        … 48 more
Caused by: java.lang.ClassNotFoundException: org.gjt.mm.mysql.Driver
        at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoa
der.java:1387)
        at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoa
der.java:1233)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:169)
        at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSou
rce.java:760)
        … 51 more
30-Mar-2009 15:03:54 org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
30-Mar-2009 15:03:54 org.apache.catalina.core.StandardContext start
SEVERE: Context [/alfresco] startup failed due to previous errors
log4j:ERROR LogMananger.repositorySelector was null likely due to error in class
reloading, using NOPLoggerRepository.
30-Mar-2009 15:03:57 org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive share.war
15:04:04,944  INFO  [web.site.FrameworkHelper] Successfully Initialized Web Fram
ework
30-Mar-2009 15:04:05 org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-8080
30-Mar-2009 15:04:05 org.apache.catalina.startup.Catalina start
INFO: Server startup in 96724 ms

Many thanks

Rob
9 REPLIES 9

zaizi
Champ in-the-making
Champ in-the-making
Hi Rob,

The root cause is "Caused by: java.lang.ClassNotFoundException: org.gjt.mm.mysql.Driver" from your error logs.

You are missing the MySQL JDBC drivers. How did you install Alfresco?

You need to download JDBC drivers from http://dev.mysql.com/downloads/connector/j/5.1.html and copy it into tomcat/lib.

Hope it helps,
Ainga

roblegge
Champ in-the-making
Champ in-the-making
Thanks Ainga. I rolled the snapshot of the OS back to an earlier version and reinstalled, this time putting the JDBC in place. It might not be a bad idea in future to include copies of the JDBCs for MySQL SQL Server and Oracle in the installation routine, rather than rely on people having to copy their own version. It just makes hte installation smoother 🙂

One other point is that Windows Server 2003 should be activated BEFORE doing the installation. An error message pops up, about halfway through, that you need to run the installer with administrator rights (even if you are) if it's not activated first. Why this should be the case I have no idea (yet).

At the moment everything is running though. I'll be back if I have more problems 🙂

R

zaizi
Champ in-the-making
Champ in-the-making
Glad to hear you got it up and running. MySQL drivers are shipped with the installation. Which bundle did you download and how did you do the installation? It could be related to the issue with activating Windows 2003 that stopped MySQL installation possibly?

I'm afraid you can't distribute MS SQL Server or Oracle drivers with a GPL'd product. Sure there is a licensing restrictions.

Good luck.

janvg
Champ in-the-making
Champ in-the-making
I had the same issue with the 3.1 enterprise

copying the mysql connector solved the problem

vgarmash
Champ in-the-making
Champ in-the-making
Hi Rob,

The root cause is "Caused by: java.lang.ClassNotFoundException: org.gjt.mm.mysql.Driver" from your error logs.

You are missing the MySQL JDBC drivers. How did you install Alfresco?

You need to download JDBC drivers from http://dev.mysql.com/downloads/connector/j/5.1.html and copy it into tomcat/lib.

Hope it helps,
Ainga
Ainga. I have the same issue with deploying just downloaded alfresco.war into brand new Jboss Portal 2.7.2. And this is obvious mistake of Alfresco development team - they provided only this description of deployment procedure for alfresco.war:

Installing the Alfresco WAR on any platform
This section describes how to install the Alfresco Web Archive (WAR) file on any platform. A WAR file is
a JAR file used to distribute a collection of files (JavaServer Pages, servlets, Java classes, XML files, tag
libraries and static Web pages) that together constitute a web application.
Use this method of installing Alfresco if you already have installed a JDK, a supported database, an
application server, and the additional Alfresco components. The WAR zip includes the binaries for
ImageMagick and pdf2swf.
1. Select and download one of the following files:
• alfresco-labs-war-3Stable.zip
• alfresco-labs-war-3Stable-dev.tar.gz
2. Specify a location for the download.
3. Extract the downloaded file.
4. Copy the alfresco.war file and share.war file to the appropriate location for your application
server, for example: <TOMCAT_HOME>/webapps.
Note: If you deployed previous versions of Alfresco, you must remove any temporary files created by
your application server.

I couldn't find a word about MySQL driver in this instruction. Neither I can find some description how to change any property inside alfresco.war file without extracting it. So basically alfresco-labs-war-3Stable.zip is Do-It-Yourself-Kit without any real user manual whic is useless…

mikeh
Star Contributor
Star Contributor
Thanks for pointing out our "obvious mistake"  :roll:

It's assumed that if you've got the knowledge to install your own database and application server, you've gone the extra step and installed a database driver for it too. We can't possibly hand-hold people through the entire application stack configuration for all cases.

The MySQL config is clearly documented on the wiki: http://wiki.alfresco.com/wiki/Setting_up_the_MySQL_database_for_Alfresco

Thanks,
Mike

vgarmash
Champ in-the-making
Champ in-the-making
Thanks for pointing out our "obvious mistake"  :roll:

It's assumed that if you've got the knowledge to install your own database and application server, you've gone the extra step and installed a database driver for it too. We can't possibly hand-hold people through the entire application stack configuration for all cases.

The MySQL config is clearly documented on the wiki: http://wiki.alfresco.com/wiki/Setting_up_the_MySQL_database_for_Alfresco

Thanks,
Mike
Yes, guys. You want to make your life easier - I see it. You don't have time to create good installation guides as IBM, Oracle, Bea and other mature companies do. And it is fine until you really don't want to provide enterprise-ready product. When you change your mind you will do all documentation properly.

But just for now your good product looks like student's project because it doesn't work out of the box. There is always something that should be tweaked before it would be possible to really use your product (especially alfresco.war). I never experienced any problems with server applications from companies I mentioned before - you just downloading package, install it into your server and it works. Yes, for more information I can go to vendor's website and use some Wiki or other structured documentation. I even can't imagine that I need to go to Bea wiki and read some articles to use weblogic server.

Unfortunately you didn't reach this level of consumer friendliness but I hope you will.
If you want to use wiki as source of documentation fine - but why you don't put links to Wiki pages into you PDF installation documentation? Just 2-3 links can save people days! I spent 2 days to resolve all issues with alfresco.war/jboss portal and create my own installation guide which currently consists of 16 steps not 4 as yours section describes how to install the Alfresco Web Archive (WAR) file on any platform. Of course I searched Alfresco wiki and found couple articles about installation into Jboss AS/Portal but they don't cover all problems. I also searched forum and found many duplicated posts about the same problems over and over. So people really got into the same issues just because Alfresco team didn't have time to test their WAR file and provide some troubleshooting guide. Instead of that developers again and again responding to user's posts with links to Wiki - it just doesn't make any sense to me. Just put those links into installation PDF and everybody will be happy.

I wish when you buy your next car you will not able to put the key into ignition and drive to the restaurant. I wish you will sit for 2 days browsing manufacturer website to understand why wheels rolling into opposite direction and windows open when you jump into.

jmcooper
Champ in-the-making
Champ in-the-making
Hi vgarmash - would you be so kind as to share (post here) your 16 steps to getting alfresco war/jboss configuration going? I have also spent a lot of time and searching on the web, One problem is that there is a lot of conflicting information out there. But, the Alfresco pdf install guide does not seem to cover all the basic's for sure …

For anyone else perhaps able to help: I'm stuck getting any of the over-rides to work - like a custom dir directory. The war works expanded "out of the box", but I can't get any customizations to work … the launch blows up … it's not clear where to put what: <jboss>/server/default/conf/alfresco/extension/  …. or …  <jboss>/server/default/deploy/alfresco.war/WEB-INF/classes/alfresco/extension/  

Basic config: Ubuntu 8.04 LTS Server, JBOSS 4.2.3, Alfresco Labs3, Java 1.5, MySQL 5x

I can post further details if this doesn't spark any basic config guidelines …

Thanks, John

vgarmash
Champ in-the-making
Champ in-the-making
Hi vgarmash - would you be so kind as to share (post here) your 16 steps to getting alfresco war/jboss configuration going? I have also spent a lot of time and searching on the web, One problem is that there is a lot of conflicting information out there. But, the Alfresco pdf install guide does not seem to cover all the basic's for sure …

For anyone else perhaps able to help: I'm stuck getting any of the over-rides to work - like a custom dir directory. The war works expanded "out of the box", but I can't get any customizations to work … the launch blows up … it's not clear where to put what: <jboss>/server/default/conf/alfresco/extension/  …. or …  <jboss>/server/default/deploy/alfresco.war/WEB-INF/classes/alfresco/extension/  

Basic config: Ubuntu 8.04 LTS Server, JBOSS 4.2.3, Alfresco Labs3, Java 1.5, MySQL 5x

I can post further details if this doesn't spark any basic config guidelines …

Thanks, John

Hi, jmcooper.

Here is my steps I logged during my research of this issue. Unfortunately I am not expert in JBoss classloading or some configurations really don't have any effect, but I couldn't resolve final conflict with Hibernate. The problem is that Alfresco use it's own "hibernate-patched.jar" but JBoss portal 2.7.2 has regular one. Because of specific features of the way how JBoss loading and caching classess it can be a real problem.

For you it would be not a problem because you use clean Jboss without portal application.
First of all forget about Install_Configure_Alfresco_Lab3Stable.pdf - it doesn't cover WAR installation.
  • Install and configure JBoss Portal
    • Download JBoss Portal Bundled with JBoss AS

    • Install it and change run.bat (run.sh) to use JDK 1.5 (JBoss AS is not fully compatible with JDK 1.6). Make sure you don't have any exceptions in the server log before proceed further

    • Edit the JBoss bin/run.bat or run.sh file and add to the JAVA_OPTS line: -XX:MaxPermSize=256m -server

    • Edit the following file: \jboss\server\default\deploy\ejb3.deployer\META-INF\persistence.properties and change the line:
    • hibernate.bytecode.provider=javassist
      to:
      hibernate.bytecode.provider=cglib
    • Inside the alfresco-labs-war-3Stable.zip download, there are files specific for a Windows deployment.
    • The files are in alfresco-labs-war-3Stable.zip/commands/bin.
      Copy (Win32Utils.dll & Win32NetBIOS.dll) or (Win32Utilsx64.dll & Win32NetBIOSx64.dll) depending on the version of Windows to your JBoss bin folder.
    • Remove jcl104-over-slf4j-1.3.0.jar from jboss\server\default\deploy\jboss-portal.sar\portal-cms.sar\lib
  • Prepare database
    • Create a new empty database schema instance called 'alfresco' in MySQL - use the example files in the Alfresco bundle in /extra/databases/mysql to perform this with the correct user permissions.

    • Download the MySQL JDBC driver file from MySQL

    • Extract the MySQL JDBC driver .jar file and copy to \jboss\server\default\lib
  • Install alfresco.war
    • Extract alfresco.war from the alfresco bundle and copy to \jboss\server\default\deploy. You have to change properties inside war before start

    • Make sure that __alfresco.war/WEB-INF/web.xml__ has following:
    • <context-param>
        <param-name>org.jboss.jbossfaces.WAR_BUNDLES_JSF_IMPL</param-name>
        <param-value>true</param-value>
      </context-param>
      And add/edit it if it doesn't
    • Remove /WEB-INF/lib/jta.jar if you plan on using JTA.

    • Edit alfresco.war\WEB-INF\classes\alfresco\repository.properties
      • Set value for dir.root property (default is ./alf_data which is wrong for WAR).

      • Set values in # Database configuration section
        • db.name (ex. ''db.name=alfresco-slava'')

        • db.url (ex. ''db.url=jdbc:mysql://10.10.10.108:3306/${db.name}'')

        • db.username (ex. ''db.username=sensei'')

        • db.password (ex. ''db.password=sensei'')
      • Set index.recovery.mode=FULL
—-

Some info at Alfresco Server Installation

Because of this conflict we decided to stop this research and forget about using alfresco,war in Jboss Portal for now. We use Standalone Alfresco installation with JCR-RMI connection.