• ==

  • OpenKM has many interesting features, but requires some configuration process to show its full potential.
OpenKM has many interesting features, but requires some configuration process to show its full potential.
Forum rules: Please, before asking something see the documentation wiki or use the search feature of the forum. And remember we don't have a crystal ball or mental readers, so if you post about an issue tell us which OpenKM are you using and also the browser and operating system version. For more info read How to Report Bugs Effectively.
 #959  by tidus2728
 
Hi hbcomcn,

Your OpenKM.cfg and openkm-emails.properties seem to be correct. The problem is probably in the mail-service.xml.

From your first config, the mail service is bound properly but the smtp does not seem to be configured properly. You need to configure your smtp server to relay to smtp.gmail.com.

For your second config, which you used skowit\'s setup, it should work but it did not because the mail service is not bound. You may try to change mail-service.xml in this line:

<attribute name=\"JNDIName\">java:/mail/OpenKM</attribute>

to

<attribute name=\"JNDIName\">java:/Mail/OpenKM</attribute>

in real time, meaning OpenKM is running then check the logs for the mail service to bound. If this doesn\'t work then revert back to the previous setting while checking the log for the mail service to bind. You may also want to restart OpenKM then check.

Thanks.
 #966  by hbcomcn
 
Hello tidus2728
I changed my first \'mail-service.xml\', it works like:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!-- $Id: mail-service.xml 62349 2007-04-15 16:48:15Z dimitris@jboss.org $ -->
<server>

  <!-- ==================================================================== -->
  <!-- Mail Connection Factory                                              -->
  <!-- ==================================================================== -->

  <mbean code="org.jboss.mail.MailService"
         name="jboss:service=mail/OpenKM">
    <attribute name="JNDIName">java:/mail/OpenKM</attribute>
    <attribute name="User">openkmfan</attribute>
    <attribute name="Password">XXXXXX</attribute>
    <attribute name="Configuration">
      <!-- A test configuration -->
      <configuration>
        <!-- Change to your mail server prototocol -->
        <property name="mail.store.protocol" value="pop3"/>
        <property name="mail.transport.protocol" value="smtp"/>

        <!-- Change to the user who will receive mail  -->
        <property name="mail.user" value="nobody"/>

        <!-- Change to the mail server  -->
        <property name="mail.pop3.host" value="pop3.nosuchhost.nosuchdomain.com"/>

        <!-- Change to the SMTP gateway server -->
        <property name="mail.smtp.host" value="smtp.gmail.com"/>
        
        <!-- The mail server port -->
        <property name="mail.smtp.port" value="587"/>
        
        <!-- Change to the address mail will be from  -->
        <property name="mail.from" value="openkmfan@gmail.com"/>

        <!-- Enable debugging output from the javamail classes -->
        <property name="mail.debug" value="false"/>
      </configuration>
    </attribute>
    <depends>jboss:service=Naming</depends>
  </mbean>

</server>
but still have errors:
Code: Select all
10:23:27,546 ERROR [STDERR] javax.mail.MessagingException: Exception reading res
ponse;
  nested exception is:
        java.net.SocketException: Connection reset
10:23:27,546 ERROR [STDERR]     at com.sun.mail.smtp.SMTPTransport.readServerRes
ponse(SMTPTransport.java:1462)
10:23:27,546 ERROR [STDERR]     at com.sun.mail.smtp.SMTPTransport.close(SMTPTra
nsport.java:645)
10:23:27,546 ERROR [STDERR]     at javax.mail.Transport.send0(Transport.java:171
)
10:23:27,546 ERROR [STDERR]     at javax.mail.Transport.send(Transport.java:98)
10:23:27,546 ERROR [STDERR]     at es.git.openkm.util.Mail.send(Mail.java:88)
10:23:27,546 ERROR [STDERR]     at es.git.openkm.module.direct.DirectNotificatio
nModule.notify(DirectNotificationModule.java:279)
10:23:27,546 ERROR [STDERR]     at es.git.openkm.api.OKMNotification.notify(OKMN
otification.java:87)
10:23:27,546 ERROR [STDERR]     at es.git.openkm.frontend.server.OKMFileUploadSe
rvlet.doPost(OKMFileUploadServlet.java:139)
10:23:27,546 ERROR [STDERR]     at javax.servlet.http.HttpServlet.service(HttpSe
rvlet.java:710)
10:23:27,546 ERROR [STDERR]     at javax.servlet.http.HttpServlet.service(HttpSe
rvlet.java:803)
10:23:27,546 ERROR [STDERR]     at org.apache.catalina.core.ApplicationFilterCha
in.internalDoFilter(ApplicationFilterChain.java:290)
10:23:27,546 ERROR [STDERR]     at org.apache.catalina.core.ApplicationFilterCha
in.doFilter(ApplicationFilterChain.java:206)
10:23:27,546 ERROR [STDERR]     at org.jboss.web.tomcat.filters.ReplyHeaderFilte
r.doFilter(ReplyHeaderFilter.java:96)
10:23:27,546 ERROR [STDERR]     at org.apache.catalina.core.ApplicationFilterCha
in.internalDoFilter(ApplicationFilterChain.java:235)
10:23:27,546 ERROR [STDERR]     at org.apache.catalina.core.ApplicationFilterCha
in.doFilter(ApplicationFilterChain.java:206)
10:23:27,546 ERROR [STDERR]     at org.apache.catalina.core.StandardWrapperValve
.invoke(StandardWrapperValve.java:230)
10:23:27,546 ERROR [STDERR]     at org.apache.catalina.core.StandardContextValve
.invoke(StandardContextValve.java:175)
10:23:27,546 ERROR [STDERR]     at org.jboss.web.tomcat.security.SecurityAssocia
tionValve.invoke(SecurityAssociationValve.java:179)
10:23:27,546 ERROR [STDERR]     at org.apache.catalina.authenticator.Authenticat
orBase.invoke(AuthenticatorBase.java:524)
10:23:27,546 ERROR [STDERR]     at org.jboss.web.tomcat.security.JaccContextValv
e.invoke(JaccContextValve.java:84)
10:23:27,546 ERROR [STDERR]     at org.apache.catalina.core.StandardHostValve.in
voke(StandardHostValve.java:127)
10:23:27,546 ERROR [STDERR]     at org.apache.catalina.valves.ErrorReportValve.i
nvoke(ErrorReportValve.java:102)
10:23:27,546 ERROR [STDERR]     at org.jboss.web.tomcat.service.jca.CachedConnec
tionValve.invoke(CachedConnectionValve.java:157)
10:23:27,546 ERROR [STDERR]     at org.apache.catalina.core.StandardEngineValve.
invoke(StandardEngineValve.java:109)
10:23:27,546 ERROR [STDERR]     at org.apache.catalina.connector.CoyoteAdapter.s
ervice(CoyoteAdapter.java:262)
10:23:27,546 ERROR [STDERR]     at org.apache.coyote.http11.Http11Processor.proc
ess(Http11Processor.java:844)
10:23:27,546 ERROR [STDERR]     at org.apache.coyote.http11.Http11Protocol$Http1
1ConnectionHandler.process(Http11Protocol.java:583)
10:23:27,546 ERROR [STDERR]     at org.apache.tomcat.util.net.JIoEndpoint$Worker
.run(JIoEndpoint.java:446)
10:23:27,546 ERROR [STDERR]     at java.lang.Thread.run(Thread.java:595)
10:23:27,546 ERROR [STDERR] Caused by: java.net.SocketException: Connection rese
t
10:23:27,546 ERROR [STDERR]     at java.net.SocketInputStream.read(SocketInputSt
ream.java:168)
10:23:27,562 ERROR [STDERR]     at com.sun.mail.util.TraceInputStream.read(Trace
InputStream.java:97)
10:23:27,562 ERROR [STDERR]     at java.io.BufferedInputStream.fill(BufferedInpu
tStream.java:218)
10:23:27,562 ERROR [STDERR]     at java.io.BufferedInputStream.read(BufferedInpu
tStream.java:235)
10:23:27,562 ERROR [STDERR]     at com.sun.mail.util.LineInputStream.readLine(Li
neInputStream.java:75)
10:23:27,562 ERROR [STDERR]     at com.sun.mail.smtp.SMTPTransport.readServerRes
ponse(SMTPTransport.java:1440)
10:23:27,562 ERROR [STDERR]     ... 28 more
10:23:27,843 INFO  [CacheManager] resizeAll size=7
attachment is the server log
Thanks!!!
tidus2728 wrote:Hi hbcomcn,

Your OpenKM.cfg and openkm-emails.properties seem to be correct. The problem is probably in the mail-service.xml.

From your first config, the mail service is bound properly but the smtp does not seem to be configured properly. You need to configure your smtp server to relay to smtp.gmail.com.

For your second config, which you used skowit\'s setup, it should work but it did not because the mail service is not bound. You may try to change mail-service.xml in this line:

<attribute name="JNDIName">java:/mail/OpenKM</attribute>

to

<attribute name="JNDIName">java:/Mail/OpenKM</attribute>

in real time, meaning OpenKM is running then check the logs for the mail service to bound. If this doesn\'t work then revert back to the previous setting while checking the log for the mail service to bind. You may also want to restart OpenKM then check.

Thanks.
[file name=server-91e7eab85db850e20b0a07c4bef3eeee.zip size=70689]http://www.openkm.com/images/fbfiles/fi ... f3eeee.zip[/file]
 #968  by hbcomcn
 
when I change \'mail-service.xml\' file to:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!-- $Id: mail-service.xml 62349 2007-04-15 16:48:15Z dimitris@jboss.org $ -->
<server>

<!-- ==================================================================== -->
<!-- Mail Connection Factory -->
<!-- ==================================================================== -->

<mbean code="org.jboss.mail.MailService"
name="jbosservice=mail/OpenKM">
<attribute name="JNDIName">java:/Mail/OpenKM</attribute>
<attribute name="User">openkmfan@gmail.com</attribute>
<attribute name="Password">XXXXXX</attribute>
<attribute name="Configuration">
<configuration>
<property name="mail.transport.protocol" value="smtp"/>
<property name="mail.smtp.host" value="smtp.gmail.com"/>
<property name="mail.smtp.port" value="587"/>
<property name="mail.smtp.starttls.enable" value="true"/>
<property name="mail.smtp.auth" value="true"/>
<property name="mail.from" value="openkmfan@gmail.com"/>
<property name="mail.debug" value="false"/>
</configuration>
</attribute>
<depends>jbosservice=Naming</depends>
</mbean>
</server>
Still the same problem as before:
Code: Select all
--- Incompletely deployed packages ---
org.jboss.deployment.DeploymentInfo@f28ae0a9 { url=file:/C:/FMS/OpenKM/OpenKM-2.
0_JBoss-4.2.2.GA/server/default/deploy/mail-service.xml }
  deployer: org.jboss.deployment.SARDeployer@1f78040
  status: Deployment FAILED reason: Domain part must be specified; - nested thro
wable: (javax.management.MalformedObjectNameException: Domain part must be speci
fied)
  state: FAILED
  watch: file:/C:/FMS/OpenKM/OpenKM-2.0_JBoss-4.2.2.GA/server/default/deploy/mai
l-service.xml
  altDD: null
  lastDeployed: 1218052072718
  lastModified: 1218052072703
  mbeans:


15:48:50,812 INFO  [Http11Protocol] Starting Coyote HTTP/1.1 on http-127.0.0.1-8
080
15:48:50,843 INFO  [AjpProtocol] Starting Coyote AJP/1.3 on ajp-127.0.0.1-8009
15:48:50,921 INFO  [Server] JBoss (MX MicroKernel) [4.2.2.GA (build: SVNTag=JBos
s_4_2_2_GA date=200710221139)] Started in 1m:28s:62ms
why so many problems for me...

attach the server log file

Thanks!!!
tidus2728 wrote:Hi hbcomcn,

Your OpenKM.cfg and openkm-emails.properties seem to be correct. The problem is probably in the mail-service.xml.

From your first config, the mail service is bound properly but the smtp does not seem to be configured properly. You need to configure your smtp server to relay to smtp.gmail.com.

For your second config, which you used skowit\'s setup, it should work but it did not because the mail service is not bound. You may try to change mail-service.xml in this line:

<attribute name="JNDIName">java:/mail/OpenKM</attribute>

to

<attribute name="JNDIName">java:/Mail/OpenKM</attribute>

in real time, meaning OpenKM is running then check the logs for the mail service to bound. If this doesn\'t work then revert back to the previous setting while checking the log for the mail service to bind. You may also want to restart OpenKM then check.

Thanks.
[file name=server-a98ddc1469653b78353fb3fee809b450.zip size=70089]http://www.openkm.com/images/fbfiles/fi ... 09b450.zip[/file]
 #970  by tidus2728
 
Hi hbcomcn,

I am intrigued by how OpenKM behaves on your machine. But, you can try and return the settings to mail-service.xml from a fresh copy of the file without any revisions then change to these settings:

<attribute name=\"JNDIName\">java:/mail/OpenKM</attribute>

<attribute name=\"User\">openkmfan@gmail.com</attribute>

<attribute name=\"Password\">XXXXXX</attribute>

<property name=\"mail.smtp.host\" value=\"smtp.gmail.com\"/>

<property name=\"mail.smtp.port\" value=\"587\"/>

<property name=\"mail.smtp.starttls.enable\" value=\"true\"/>

<property name=\"mail.smtp.auth\" value=\"true\"/>

<property name=\"mail.from\" value=\"openkmfan@gmail.com\"/>

<property name=\"mail.debug\" value=\"true\"/>

I omitted the other lines as these need to be in default. Also make sure that your machine directly access the internet without any proxy settings, otherwise, search the forum for the proxy configuration.

Then restart OpenKM and check the boot log of OpenKM to see if the mail is bound.

The try sending email notification and check the server log for the debug info.

Thanks.
 #988  by jllort
 
Really hbcomcn, we can\'t imagine which is your problem, we\'re sure it\'s external to OpenKM because mail service configuration has no much problems.

On your case I\'ll revise network configuration ( some firewall or similar ? ) and I\'ll try with other mail account (if it\'s an enterprise one, better ) for discarding.
 #1264  by martinriver
 
Hello

I was the same problem, but now the mail is OK.

The change correct for me:

<attribute name=\"JNDIName\">java:/mail/OpenKM</attribute>

<property name=\"mail.debug\" value=\"true\"/>


Regards

About Us

OpenKM is part of the management software. A management software is a program that facilitates the accomplishment of administrative tasks. OpenKM is a document management system that allows you to manage business content and workflow in a more efficient way. Document managers guarantee data protection by establishing information security for business content.