Page 1 of 1
OpenKM 6.2.2 Mail account - strange problem
PostPosted:Wed Nov 21, 2012 10:28 am
by luke
Hi
I have a problem with mail account in OpenKM. I configured it, checked with success. The problem is with duplicates. I sent an e-mail to test it on 19-11-2012 and I have the same one in the folders 19, 20 and 21. I try to delete it and the next day situation continues the mail appears in the folders. In the day 20 even twice. There is also one strange thing when I click folders in Mail they sometimes have the same names for example I have days 19, 20, 21 I clicked once on 19 and I have 19 and 20,20. When I click refresh everything backs to normal.
Please help.
Best wishes
Luke
Re: OpenKM 6.2.2 Mail account - strange problem
PostPosted:Thu Nov 22, 2012 6:33 pm
by jllort
Some screenshot wil help us. And sure you do not have this mails in your imap server (or what you're using ?)
Re: OpenKM 6.2.2 Mail account - strange problem
PostPosted:Tue Nov 27, 2012 5:37 pm
by luke
Code: Select allThis message was created automatically by mail delivery software.
A message that you sent could not be delivered to one or more of its
recipients. This is a permanent error. The following address(es) failed:
noreply@openkm.com
SMTP error from remote mail server after RCPT TO:<noreply@openkm.com>:
host mail.mail.st [*.*.*.*]: 550 5.1.1 <noreply@openkm.com>:
Recipient address rejected: User unknown in virtual mailbox table
------ This is a copy of the message, including all the headers. ------
Return-path: <test@test.pl>
Received: from d156215.test.pl ([*.*.*.*] helo=test.test.pl)
by s69.linuxpl.com with esmtpa (Exim 4.80)
(envelope-from <test@test.pl>)
id 1TdOW1-0003hW-U1
for noreply@openkm.com; Tue, 27 Nov 2012 18:00:09 +0100
Date: Tue, 27 Nov 2012 18:00:06 +0100 (CET)
From: test@test.pl
To: noreply@openkm.com
Message-ID: <19844629.725.1354035606716.JavaMail.test@test.pl>
Subject: Cron task 'UserMailImporter' executed - Error
MIME-Version: 1.0
Subject: Cron task 'UserMailImporter' executed - Error
MIME-Version: 1.0
Content-Type: multipart/alternative;
boundary="----=_Part_724_30407201.1354035606716"
charset: UTF-8
------=_Part_724_30407201.1354035606716
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
Sourced file: inline evaluation of: ``new
com.openkm.core.UserMailImporter().run();'' : target exception : at Line:
1 : in file: inline evaluation of: ``new
com.openkm.core.UserMailImporter().run();'' : .run ( )
Target exception: java.lang.NullPointerException
------=_Part_724_30407201.1354035606716
Content-Type: text/html
Content-Transfer-Encoding: 7bit
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=UTF-8" http-equiv="Content-Type"/>
</head>
<body>
Sourced file: inline evaluation of: ``new
com.openkm.core.UserMailImporter().run();'' : target exception : at Line:
1 : in file: inline evaluation of: ``new
com.openkm.core.UserMailImporter().run();'' : .run ( )
Target exception: java.lang.NullPointerException
</body>
</html>
I get such errors when try to import mails from my mail account. I get this message every 60min (my mail importer is set to 60).
Re: OpenKM 6.2.2 Mail account - strange problem
PostPosted:Thu Nov 29, 2012 10:55 pm
by jllort
Here we got two errors, one because is trying to send mail to
no_reply@oepnkm.com ( I suggest you configure your mail account at server.xml ) and then seems when is trying to import mail found something null ( some empty value ). I suggest you take a look at server.log to see if we can see a complete stack trace error ( error could be caused by empty subject ... something in mail is empty and logic break ).
seems you have imported some mail but arrived someone get some error. Take a look on mail message trying to identify which is the next and what is different on it.
Re: OpenKM 6.2.2 Mail account - strange problem
PostPosted:Sun Dec 02, 2012 7:43 pm
by luke
That`s my tomcat server conf.
Code: Select all<Server port="8005" shutdown="SHUTDOWN">
<!-- Security listener. Documentation at /docs/config/listeners.html
<Listener className="org.apache.catalina.security.SecurityListener" />
-->
<!--APR library loader. Documentation at /docs/apr.html -->
<Listener className="org.apache.catalina.core.AprLifecycleListener" SSLEngine="on" />
<!--Initialize Jasper prior to webapps are loaded. Documentation at /docs/jasper-howto.html -->
<Listener className="org.apache.catalina.core.JasperListener" />
<!-- Prevent memory leaks due to use of particular java/javax APIs-->
<Listener className="org.apache.catalina.core.JreMemoryLeakPreventionListener" />
<Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener" />
<Listener className="org.apache.catalina.core.ThreadLocalLeakPreventionListener" />
<!-- Automatically reload log4j configuration -->
<Listener className="com.openkm.util.Log4JInitializer" configFile="${catalina.base}/conf/log4j.properties"/>
<!-- Global JNDI resources
Documentation at /docs/jndi-resources-howto.html
-->
<GlobalNamingResources>
<!-- Editable user database that can also be used by
UserDatabaseRealm to authenticate users
-->
<Resource name="UserDatabase" auth="Container"
type="org.apache.catalina.UserDatabase"
description="User database that can be updated and saved"
factory="org.apache.catalina.users.MemoryUserDatabaseFactory"
pathname="conf/tomcat-users.xml" />
<Resource name="jdbc/OpenKMDS" auth="Container" type="javax.sql.DataSource"
maxActive="100" maxIdle="30" maxWait="10000" validationQuery="select 1 from INFORMATION_SCHEMA.SYSTEM_USERS"
username="sa" password="" driverClassName="org.hsqldb.jdbcDriver"
url="jdbc:hsqldb:${catalina.base}/repository/okmdb"/>
<!-- <Resource name="jdbc/OpenKMDS" auth="Container" type="javax.sql.DataSource"
maxActive="100" maxIdle="30" maxWait="10000" validationQuery="select 1"
username="openkm" password="*****" driverClassName="com.mysql.jdbc.Driver"
url="jdbc:mysql://localhost:3306/okmdb?autoReconnect=true&useUnicode=true&characterEncoding=UTF8"/> -->
<Resource name="mail/OpenKM" auth="Container" type="javax.mail.Session"
mail.smtp.host="mail.test.pl" mail.from="test@test.pl"
mail.transport.protocol="smtp"
mail.smtp.auth="true"
mail.smtp.user="test@test.pl"
password="test1234"
mail.port="25"
mail.debug="true"
/>
</GlobalNamingResources>
<!-- A "Service" is a collection of one or more "Connectors" that share
a single "Container" Note: A "Service" is not itself a "Container",
so you may not define subcomponents such as "Valves" at this level.
Documentation at /docs/config/service.html
-->
<Service name="Catalina">
<!--The connectors can use a shared executor, you can define one or more named thread pools-->
<!--
<Executor name="tomcatThreadPool" namePrefix="catalina-exec-"
maxThreads="150" minSpareThreads="4"/>
-->
<!-- A "Connector" represents an endpoint by which requests are received
and responses are returned. Documentation at :
Java HTTP Connector: /docs/config/http.html (blocking & non-blocking)
Java AJP Connector: /docs/config/ajp.html
APR (HTTP/AJP) Connector: /docs/apr.html
Define a non-SSL HTTP/1.1 Connector on port 8080
-->
<Connector port="8080" address="0.0.0.0" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443" />
<!-- A "Connector" using the shared thread pool-->
<!--
<Connector executor="tomcatThreadPool"
port="8080" address="127.0.0.1" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443" />
-->
<!-- Define a SSL HTTP/1.1 Connector on port 8443
This connector uses the JSSE configuration, when using APR, the
connector should be using the OpenSSL style configuration
described in the APR documentation -->
<!--
<Connector port="8443" address="127.0.0.1" protocol="HTTP/1.1" SSLEnabled="true"
maxThreads="150" scheme="https" secure="true"
clientAuth="false" sslProtocol="TLS" />
-->
<!-- Define an AJP 1.3 Connector on port 8009 -->
<Connector port="8009" address="127.0.0.1" protocol="AJP/1.3" redirectPort="8443" />
<!-- An Engine represents the entry point (within Catalina) that processes
every request. The Engine implementation for Tomcat stand alone
analyzes the HTTP headers included with the request, and passes them
on to the appropriate Host (virtual host).
Documentation at /docs/config/engine.html -->
<!-- You should set jvmRoute to support load-balancing via AJP ie :
<Engine name="Catalina" defaultHost="localhost" jvmRoute="jvm1">
-->
<Engine name="Catalina" defaultHost="localhost">
<!--For clustering, please take a look at documentation at:
/docs/cluster-howto.html (simple how to)
/docs/config/cluster.html (reference documentation) -->
<!--
<Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster"/>
-->
<!-- Use the LockOutRealm to prevent attempts to guess user passwords
via a brute-force attack -->
<Realm className="org.apache.catalina.realm.LockOutRealm">
<!-- This Realm uses the UserDatabase configured in the global JNDI
resources under the key "UserDatabase". Any edits
that are performed against this UserDatabase are immediately
available for use by the Realm. -->
<Realm className="org.apache.catalina.realm.UserDatabaseRealm"
resourceName="UserDatabase"/>
</Realm>
<Host name="localhost" appBase="webapps"
unpackWARs="true" autoDeploy="true">
<!-- SingleSignOn valve, share authentication between web applications
Documentation at: /docs/config/valve.html -->
<!--
<Valve className="org.apache.catalina.authenticator.SingleSignOn" />
-->
<!-- Access log processes all example.
Documentation at: /docs/config/valve.html
Note: The pattern used is equivalent to using pattern="common" -->
<Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs"
prefix="localhost_access_log." suffix=".txt"
pattern="%h %l %u %t "%r" %s %b" />
</Host>
</Engine>
</Service>
</Server>
Re: OpenKM 6.2.2 Mail account - strange problem
PostPosted:Tue Dec 04, 2012 8:33 am
by Rudolf21
Are you sure that you have to add those additional config strings beside mail.smtp.host="mail.test.pl" mail.from="
test@test.pl" in server.xml?
I'm currently using 6.2.1 and it's working like a charm.
I've only added a mailbox to a openkm user, configured mail.scheduler and added the smtp.host and mail.from to server.xml.
Re: OpenKM 6.2.2 Mail account - strange problem
PostPosted:Tue Dec 04, 2012 9:39 am
by luke
I added it as wiki said. Maybe the problem is because the mail in tomcat server is the same as the user has. I am using this mail to send messages (notification) from openkm and I want this mail to be used for the user (receiving mails). This works for couple of hours but then it crashes and I get a lot of emails with the error I described in the upper post.
Re: OpenKM 6.2.2 Mail account - strange problem
PostPosted:Thu Dec 06, 2012 7:55 am
by jllort
1- The changes in server.xml need tomcat restart
2- If you ping from server to mail.test.pl then you get correct response.
If other data is right then sure you have enabled openkm mail service. Note that a good testing is for example use the same mail data to configure some mail client ( if your data not goes fine with mail client configuration will not run on openkm too ).