• Mail importer don't working, why?

  • 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.
 #8732  by kizs
 
I setup an user's email account correctly (check button said "Success!") and put "schedule.mail.importer=10" into OpenKM.cfg.
But mails won't syncronize. Why? I don't see any mails in user's e-mail folder.
I've tried POP3, IMAP and IMAPS too, and nothing. No error in log files, the check successed, ...
What should I do?
 #8741  by jllort
 
First decide for some system imap, pop3 etc ... and then will make some checklist.

Is case imap, ensure your mail is marked as not vieweb, otherside it'll not be imported. Easy way to testing it is using gmail account and tags on gmail acts as imap folders
 #8746  by kizs
 
Basically I use our company mail server with IMAP. I get many mails from our customers and an e-mail rule (on mail server) put these in "Munka/IA" folder.
So, I would like to import all mails from "Munka/IA" folder into OpenKM "/okm:root/Invitel/IA" folder.

This is what I did:

first try:
Logged in with "okmAdmin".
Add new mail account to user "kiss".
protocol: Imap
host, user, password, etc...
folder: Munka/IA
active: true
click "check" button, and it said: "success!"

Add new mail filter to this account:
folder: /okm:root/Invitel/IA
grouping: true
active: true
and put this line into OpenKM.cfg: "schedule.mail.importer=10"
restart server

second try:
Logged in with "kiss".
in user configuration setup my email account
server, user name, password
folder: Munka/IA
push "test" button and it said: "IMAP configuration ok"


but mail doesn't coming in...
 #9949  by joako
 
jllort wrote:First decide for some system imap, pop3 etc ... and then will make some checklist.

Is case imap, ensure your mail is marked as not vieweb, otherside it'll not be imported. Easy way to testing it is using gmail account and tags on gmail acts as imap folders
I don't understand this. I already have Gmail account and I can add it IMAP to my mail client and see the mails.

When I try to set it up in OpenKM I don't get any mail imported. I try to put the same folders in my Mail client and then I always see a message like:

folder cannot contain messages

Or:

[Gmail]\All Mail not found

/edit:

The solution for Gmail is ignore whatever folder name you have, and use folder name INBOX and it will indeed show your mails.
Last edited by joako on Wed Mar 30, 2011 4:03 am, edited 1 time in total.
 #9952  by joako
 
Now I think I might have set it up right, but every time I switch to some new folder in OpenKM I get this error message pop up:
Attachments
Screen shot 2011-03-29 at 11.31.34 PM.png
Screen shot 2011-03-29 at 11.31.34 PM.png (36.09 KiB) Viewed 9680 times
 #9953  by joako
 
Last error was caused by some other issue.

But now I am getting the mails imported:

1) I see more read mail in the Gmail account and mails are imported
2) Mails in gmail all have an attachment. When I view in openkm: A) Some have attachment that is corrupt (PDF file can not be viewed) and B) Some email are fully missing attachment.

All the errors I see are:
Code: Select all


23:55:29,511 WARN  [BaseParser] Invalid dictionary, found:? but expected:''
23:55:29,571 WARN  [PdfTextExtractor] Failed to extract PDF text content
java.lang.NullPointerException
	at org.apache.pdfbox.pdmodel.PDPageNode.getAllKids(PDPageNode.java:187)
	at org.apache.pdfbox.pdmodel.PDPageNode.getAllKids(PDPageNode.java:175)
	at org.apache.pdfbox.pdmodel.PDDocumentCatalog.getAllPages(PDDocumentCatalog.java:213)
	at org.apache.pdfbox.util.PDFTextStripper.writeText(PDFTextStripper.java:258)
	at com.openkm.extractor.PdfTextExtractor.extractText(PdfTextExtractor.java:60)
	at org.apache.jackrabbit.extractor.CompositeTextExtractor.extractText(CompositeTextExtractor.java:90)
	at org.apache.jackrabbit.core.query.lucene.JackrabbitTextExtractor.extractText(JackrabbitTextExtractor.java:195)
	at org.apache.jackrabbit.core.query.lucene.TextExtractorJob$1.call(TextExtractorJob.java:93)
	at EDU.oswego.cs.dl.util.concurrent.FutureResult$1.run(Unknown Source)
	at org.apache.jackrabbit.core.query.lucene.TextExtractorJob.run(TextExtractorJob.java:172)
	at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown Source)
	at java.lang.Thread.run(Thread.java:680)
23:55:29,623 WARN  [BaseParser] Invalid dictionary, found:? but expected:''
23:55:29,625 WARN  [PdfTextExtractor] Failed to extract PDF text content
java.lang.NullPointerException
	at org.apache.pdfbox.pdmodel.PDPageNode.getAllKids(PDPageNode.java:187)
	at org.apache.pdfbox.pdmodel.PDPageNode.getAllKids(PDPageNode.java:175)
	at org.apache.pdfbox.pdmodel.PDDocumentCatalog.getAllPages(PDDocumentCatalog.java:213)
	at org.apache.pdfbox.util.PDFTextStripper.writeText(PDFTextStripper.java:258)
	at com.openkm.extractor.PdfTextExtractor.extractText(PdfTextExtractor.java:60)
	at org.apache.jackrabbit.extractor.CompositeTextExtractor.extractText(CompositeTextExtractor.java:90)
	at org.apache.jackrabbit.core.query.lucene.JackrabbitTextExtractor.extractText(JackrabbitTextExtractor.java:195)
	at org.apache.jackrabbit.core.query.lucene.TextExtractorJob$1.call(TextExtractorJob.java:93)
	at EDU.oswego.cs.dl.util.concurrent.FutureResult$1.run(Unknown Source)
	at org.apache.jackrabbit.core.query.lucene.TextExtractorJob.run(TextExtractorJob.java:172)
	at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown Source)
	at java.lang.Thread.run(Thread.java:680)
23:55:33,697 ERROR [DirectDocumentModule] Error in encoded stream: needed 4 valid base64 characters but only got 1 before EOF, the 10 most recent characters were: "gICAgICAgI"
java.io.IOException: Error in encoded stream: needed 4 valid base64 characters but only got 1 before EOF, the 10 most recent characters were: "gICAgICAgI"
	at com.sun.mail.util.BASE64DecoderStream.decode(BASE64DecoderStream.java:237)
	at com.sun.mail.util.BASE64DecoderStream.read(BASE64DecoderStream.java:135)
	at java.io.FilterInputStream.read(FilterInputStream.java:90)
	at com.openkm.module.direct.DirectDocumentModule.create(DirectDocumentModule.java:397)
	at com.openkm.api.OKMDocument.create(OKMDocument.java:69)
	at com.openkm.util.MailUtils.addAttachments(MailUtils.java:620)
	at com.openkm.util.MailUtils.importMail(MailUtils.java:455)
	at com.openkm.util.MailUtils.importMessages(MailUtils.java:397)
	at com.openkm.core.UserMailImporter.run(UserMailImporter.java:57)
	at java.util.TimerThread.mainLoop(Timer.java:512)
	at java.util.TimerThread.run(Timer.java:462)
23:55:33,697 WARN  [JCRUtils] node == NULL
23:55:33,697 ERROR [MailUtils] Error in encoded stream: needed 4 valid base64 characters but only got 1 before EOF, the 10 most recent characters were: "gICAgICAgI"
java.io.IOException: Error in encoded stream: needed 4 valid base64 characters but only got 1 before EOF, the 10 most recent characters were: "gICAgICAgI"
	at com.sun.mail.util.BASE64DecoderStream.decode(BASE64DecoderStream.java:237)
	at com.sun.mail.util.BASE64DecoderStream.read(BASE64DecoderStream.java:135)
	at java.io.FilterInputStream.read(FilterInputStream.java:90)
	at com.openkm.module.direct.DirectDocumentModule.create(DirectDocumentModule.java:397)
	at com.openkm.api.OKMDocument.create(OKMDocument.java:69)
	at com.openkm.util.MailUtils.addAttachments(MailUtils.java:620)
	at com.openkm.util.MailUtils.importMail(MailUtils.java:455)
	at com.openkm.util.MailUtils.importMessages(MailUtils.java:397)
	at com.openkm.core.UserMailImporter.run(UserMailImporter.java:57)
	at java.util.TimerThread.mainLoop(Timer.java:512)
	at java.util.TimerThread.run(Timer.java:462)
23:58:28,659 ERROR [DirectDocumentModule] Error in encoded stream: needed 4 valid base64 characters but only got 2 before EOF, the 10 most recent characters were: "ZjphYm91dD"
java.io.IOException: Error in encoded stream: needed 4 valid base64 characters but only got 2 before EOF, the 10 most recent characters were: "ZjphYm91dD"
	at com.sun.mail.util.BASE64DecoderStream.decode(BASE64DecoderStream.java:237)
	at com.sun.mail.util.BASE64DecoderStream.read(BASE64DecoderStream.java:135)
	at java.io.FilterInputStream.read(FilterInputStream.java:90)
	at com.openkm.module.direct.DirectDocumentModule.create(DirectDocumentModule.java:397)
	at com.openkm.api.OKMDocument.create(OKMDocument.java:69)
	at com.openkm.util.MailUtils.addAttachments(MailUtils.java:620)
	at com.openkm.util.MailUtils.importMail(MailUtils.java:455)
	at com.openkm.util.MailUtils.importMessages(MailUtils.java:397)
	at com.openkm.core.UserMailImporter.run(UserMailImporter.java:57)
	at java.util.TimerThread.mainLoop(Timer.java:512)
	at java.util.TimerThread.run(Timer.java:462)
23:58:28,659 WARN  [JCRUtils] node == NULL
23:58:28,660 ERROR [MailUtils] Error in encoded stream: needed 4 valid base64 characters but only got 2 before EOF, the 10 most recent characters were: "ZjphYm91dD"
java.io.IOException: Error in encoded stream: needed 4 valid base64 characters but only got 2 before EOF, the 10 most recent characters were: "ZjphYm91dD"
	at com.sun.mail.util.BASE64DecoderStream.decode(BASE64DecoderStream.java:237)
	at com.sun.mail.util.BASE64DecoderStream.read(BASE64DecoderStream.java:135)
	at java.io.FilterInputStream.read(FilterInputStream.java:90)
	at com.openkm.module.direct.DirectDocumentModule.create(DirectDocumentModule.java:397)
	at com.openkm.api.OKMDocument.create(OKMDocument.java:69)
	at com.openkm.util.MailUtils.addAttachments(MailUtils.java:620)
	at com.openkm.util.MailUtils.importMail(MailUtils.java:455)
	at com.openkm.util.MailUtils.importMessages(MailUtils.java:397)
	at com.openkm.core.UserMailImporter.run(UserMailImporter.java:57)
	at java.util.TimerThread.mainLoop(Timer.java:512)
	at java.util.TimerThread.run(Timer.java:462)
 #10022  by jllort
 
Open new post for it. All gmail mails have same problem or only ones. With pdf or other file types etc... describe as well as you can in order to try reproduce the problem.
 #12696  by Vinay
 
Can anyone give me the complete steps if I want to see my mails from Gmail in OpenKM. The version which I am using is 5.17
 #12706  by jllort
 
Vinay open new post for it, please. It's other kind of question.

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.