Active Sync and Mobile Web Client not working

Forum to discuss the Scalix ActiveSync product

Moderators: ScalixSupport, admin

brutus
Posts: 11
Joined: Thu Jan 17, 2008 4:30 pm

Active Sync and Mobile Web Client not working

Postby brutus » Wed Mar 10, 2010 6:17 am

Hi all,

i'm trying to get Active Sync (latest version) and the mobile web client (11.4.6) running. I receive the following error messages from the tomcat:

2010-03-10 11:04:46,178 FATAL [ImapDataCache.getSession:148] could not create database connection
org.hibernate.exception.GenericJDBCException: Cannot open connection
at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:103)
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:91)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:29)
at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:426)
at org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.java:144)
at org.hibernate.jdbc.BorrowedConnectionProxy.invoke(BorrowedConnectionProxy.java:50)
at $Proxy0.createStatement(Unknown Source)
at com.scalix.api.mailbox.ImapDataCache.getSession(ImapDataCache.java:144)
at com.scalix.api.mailbox.ImapDataCache.checkForTables(ImapDataCache.java:1007)
at com.scalix.api.mailbox.ImapDataCache.init(ImapDataCache.java:96)
at com.scalix.api.mailbox.CacheService.init(CacheService.java:42)
at com.scalix.api.service.Context.getServiceByName(Context.java:229)
at com.scalix.api.service.Context.getServiceByName(Context.java:213)
at com.scalix.api.mailbox.Mailbox.init(Mailbox.java:155)
at com.scalix.api.service.Context.getServiceByName(Context.java:229)
at com.scalix.api.service.Context.getMailboxService(Context.java:196)
at com.scalix.api.rest.MailboxServlet.doGet(MailboxServlet.java:71)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:627)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
at org.springframework.web.servlet.mvc.ServletWrappingController.handleRequestInternal(ServletWrappingController.java:174)
at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:48)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:839)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:774)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:460)
at com.scalix.api.PlatformDispatcherServlet.service(PlatformDispatcherServlet.java:76)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.springframework.web.filter.AbstractRequestLoggingFilter.doFilterInternal(AbstractRequestLoggingFilter.java:133)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:75)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:873)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
at java.lang.Thread.run(Unknown Source)
Caused by: java.sql.SQLException: Connections could not be acquired from the underlying database!
at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:106)
at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:529)
at com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.getConnection(AbstractPoolBackedDataSource.java:128)
at org.hibernate.connection.C3P0ConnectionProvider.getConnection(C3P0ConnectionProvider.java:56)
at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:423)
... 41 more
Caused by: com.mchange.v2.resourcepool.CannotAcquireResourceException: A ResourcePool could not acquire a resource from its primary factory or source.
at com.mchange.v2.resourcepool.BasicResourcePool.awaitAvailable(BasicResourcePool.java:1319)
at com.mchange.v2.resourcepool.BasicResourcePool.prelimCheckoutResource(BasicResourcePool.java:557)
at com.mchange.v2.resourcepool.BasicResourcePool.checkoutResource(BasicResourcePool.java:477)
at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:525)
... 44 more
2010-03-10 11:04:46,181 WARN [PlatformDispatcherServlet.service:83] Problem processing request method=GET URI=/api/Andreas.Krummrich@subdomain.domain.com/mailbox
org.springframework.web.util.NestedServletException: Request processing failed; 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.java:91)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:29)
at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:426)
at org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.java:144)
at org.hibernate.jdbc.BorrowedConnectionProxy.invoke(BorrowedConnectionProxy.java:50)
at $Proxy0.createStatement(Unknown Source)
at com.scalix.api.mailbox.ImapDataCache.getSession(ImapDataCache.java:144)
at com.scalix.api.mailbox.ImapDataCache.checkForTables(ImapDataCache.java:1007)
at com.scalix.api.mailbox.ImapDataCache.init(ImapDataCache.java:96)
at com.scalix.api.mailbox.CacheService.init(CacheService.java:42)
at com.scalix.api.service.Context.getServiceByName(Context.java:229)
at com.scalix.api.service.Context.getServiceByName(Context.java:213)
at com.scalix.api.mailbox.Mailbox.init(Mailbox.java:155)
at com.scalix.api.service.Context.getServiceByName(Context.java:229)
at com.scalix.api.service.Context.getMailboxService(Context.java:196)
at com.scalix.api.rest.MailboxServlet.doGet(MailboxServlet.java:71)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:627)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
at org.springframework.web.servlet.mvc.ServletWrappingController.handleRequestInternal(ServletWrappingController.java:174)
at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:48)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:839)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:774)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:460)
at com.scalix.api.PlatformDispatcherServlet.service(PlatformDispatcherServlet.java:76)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.springframework.web.filter.AbstractRequestLoggingFilter.doFilterInternal(AbstractRequestLoggingFilter.java:133)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:75)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:873)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
at java.lang.Thread.run(Unknown Source)
Caused by: java.sql.SQLException: Connections could not be acquired from the underlying database!
at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:106)
at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:529)
at com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.getConnection(AbstractPoolBackedDataSource.java:128)
at org.hibernate.connection.C3P0ConnectionProvider.getConnection(C3P0ConnectionProvider.java:56)
at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:423)
... 41 more
Caused by: com.mchange.v2.resourcepool.CannotAcquireResourceException: A ResourcePool could not acquire a resource from its primary factory or source.
at com.mchange.v2.resourcepool.BasicResourcePool.awaitAvailable(BasicResourcePool.java:1319)
at com.mchange.v2.resourcepool.BasicResourcePool.prelimCheckoutResource(BasicResourcePool.java:557)
at com.mchange.v2.resourcepool.BasicResourcePool.checkoutResource(BasicResourcePool.java:477)
at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:525)
... 44 more

I already searched the forum but nothing helped. I've already checked all needed config files:

sis.properties:

# lock down requests from given IP addresses only
# default: empty
index.client.whitelist=10.1.42.12,127.0.0.1

platform.properties:

#
# Hibernate configuration
#
hibernate.connection.driver_class = org.postgresql.Driver
hibernate.connection.url = jdbc:postgresql://server.domain.com:5733/scalix
hibernate.connection.username = scalix
hibernate.connection.password = XXXXXXXX
hibernate.c3p0.min_size=5
hibernate.c3p0.max_size=100
hibernate.c3p0.timeout=1800
hibernate.dialect = org.hibernate.dialect.PostgreSQLDialect
hibernate.show_sql = false
hibernate.cache.use_second_level_cache = false
hibernate.generate_statistics = true

pg_hba.conf

# List of Scalix Platform hosts begins here
host all scalix 10.1.42.12/32 md5
host all scalix 127.0.0.1/32 md5

The ip of the server is 10.1.42.12.

Is there any way to get some more verbose output from the postgres db, or does anybody has any idea?

Thanks and kind regards,
Andreas

Jeremy James
Posts: 40
Joined: Thu Apr 26, 2007 5:12 am
Location: Frankfurt, Germany

Re: Active Sync and Mobile Web Client not working

Postby Jeremy James » Wed Mar 10, 2010 7:34 am

hi,

did you try to enter the IP directly into this line to prevent DNS problems to be causing the error you are having?

Code: Select all

hibernate.connection.url = jdbc:postgresql://server.domain.com:5733/scalix


change to

Code: Select all

hibernate.connection.url = jdbc:postgresql://10.1.42.12:5733/scalix


also, is postgres running at all?

is there something listening if you enter

Code: Select all

netstat -an|grep 5733

brutus
Posts: 11
Joined: Thu Jan 17, 2008 4:30 pm

Re: Active Sync and Mobile Web Client not working

Postby brutus » Wed Mar 10, 2010 8:09 am

Hi,

yes I just tried that. Same error messages and Postgres is running. I verified it.

One thing that I forget to mention. Scalix is running on SLES 10.

Kind Regards,
Andreas

brutus
Posts: 11
Joined: Thu Jan 17, 2008 4:30 pm

Re: Active Sync and Mobile Web Client not working

Postby brutus » Wed Mar 10, 2010 8:29 am

Hi,

this is what I just found in a postgres log:

scalix 2010-03-10 13:23:40.670 CETFATAL: Passwort-Authentifizierung f<C3><BC>r Benutzer <C2><BB>scalix<C2><AB> fehlgeschlagen

Seems that the user scalix can not logon to the database. I reconfigured the db via the installer. So the password should be ok.

Anything other that I can do?

Andreas

Jeremy James
Posts: 40
Joined: Thu Apr 26, 2007 5:12 am
Location: Frankfurt, Germany

Re: Active Sync and Mobile Web Client not working

Postby Jeremy James » Wed Mar 10, 2010 10:48 am

hmm, is SElinux reporting something?

i use RHEL and Centos mainly therefore no exact knowledge about SLES, but for some reason which i never found out why, Tomcat always listens on eth1 and not eth0, so i always have to allow the IP of eth1 for hba access (and add it in postfix' main.cf to "mynetworks" as i do not use sendmail)

also, could it be that there was already a different instance of postgres running on your box and the one of scalix is not starting because port 5733 is already in use?


Return to “Scalix ActiveSync”



Who is online

Users browsing this forum: No registered users and 2 guests

cron