After the install and configuration of IMAP Mailbox app, it's not indexing any email. I was successful at getting this working in our lab environment, but not our production splunk environment.
Splunk is being run as root, so this shouldn't be a permission issue. I was able to run the debug command and it successfully returns mail in our production system.
/opt/splunk/bin/splunk cmd python /opt/splunk/etc/apps/IMAPmailbox/bin/get_imap_email.py --debug
What could I be missing? Does anyone know of any other troubleshooting steps to resolve this issue?
Yes it does. You will need to install the app on the search head. This will let you "see" the app in your splunk web. But you should not be running your input on this box at all. There is no index for it to save to. This could be your problem.
The README file has instructions for a distributed setup. There is a TA app loaded with this app. You will need to install that TA on the indexer. This is where your input will execute the get_imap_email.py script and thus be able to save it to your indexer.
I hope that helps.
I also experienced two challenges using IMAP App in corporate environments:
Yes it does. You will need to install the app on the search head. This will let you "see" the app in your splunk web. But you should not be running your input on this box at all. There is no index for it to save to. This could be your problem.
The README file has instructions for a distributed setup. There is a TA app loaded with this app. You will need to install that TA on the indexer. This is where your input will execute the get_imap_email.py script and thus be able to save it to your indexer.
I hope that helps.
ragingwire, that worked!
The TA add on needed to be installed and configured on the Indexer. See the release TA Release notes below.
Technology Add On (TA) for the IMAP Mailbox app
This TA is meant to be installed on Universal Forwarders, indexers, or other Forwarders if you are running a distributed Splunk design.
Note: Make sure that only ONE of the IMAP apps has the input script enabled. You will get email duplications if more than one is running.
I validated my settings and changed the following settings in the imap.conf
imapSearch = UNDELETED LARGER 1
deleteWhenDone = True
mimeTypes = text/richtext,text/plain,text/rtf
The emails are getting removed from the mailbox, but the imap mailbox app is still showing 0 indexed emails. Any other ideas?
Does it matter that our search head and indexer are on different servers?
Try changing the search to return emails larger than 1 k. The following worked for me.
In the IMAP config file, I changed the search to:
imapSearch = UNDELETED LARGER 1
The theory is that email size is being combined with multiple emails. When there are a lot of emails, the size is larger than 300k (which is the default) and the emails are skipped and then deleted.
Here are some of the changes I've done to get it to work:
Make sure the script is enabled to run automatically
Look in local/imap.conf
[IMAP Configuration]
disabled = 0
Restart Splunk if you made any changes.
Or restart splunk just incase to see if that will trigger it to start.
You should see a log in index=_internal for the imap script if it is set to run.
Hi,
do we have to even make changes to get_imap_email.py file on the search head or comment out any specifics so that it connects to the addon ? i can see the script successfully connect to my mailbox but unale to link the forwarder to the search head.
no changes to the script needed. You should NOT run the script on your search head. It should be disabled there. You should run it from an indexer or forwarder if possible. There are instructions in the addon directory.