New Ticket via Email

Moderator: crythias

Locked
aolgin
Znuny newbie
Posts: 21
Joined: 03 Jun 2013, 17:44
Znuny Version: 3.2.7

New Ticket via Email

Post by aolgin »

How do I set up my configuration so that when a known customer emails support@domain.com, a new ticket is created?
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: New Ticket via Email

Post by crythias »

this happens if you've already configured according to the instructions.

The cron will fetch from the pop3 box holding the email.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
aolgin
Znuny newbie
Posts: 21
Joined: 03 Jun 2013, 17:44
Znuny Version: 3.2.7

Re: New Ticket via Email

Post by aolgin »

Where are the instructions? Right now, the mail account is set up as IMAP, not POP3 at the moment
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: New Ticket via Email

Post by crythias »

ok. IMAP. concept is the same.
Instructions are in INSTALL.md and the Admin manual http://doc.otrs.org/3.2/en/html/

I don't know where to begin to ask what you've done and not done, what works and what doesn't, but the main thing is that the cron jobs should be running to fetch the mail from your configured postmaster mail accounts.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
aolgin
Znuny newbie
Posts: 21
Joined: 03 Jun 2013, 17:44
Znuny Version: 3.2.7

Re: New Ticket via Email

Post by aolgin »

Nevermind, I managed to get it working so that new tickets are created.

That leads to me two more questions:
1. How can I make it so that it will only create new tickets from emails that are sent by users already in the database, and reject the rest?
2. For the moment, as far as I can tell, it will only create ticket after I manually go to Admin>PostMaster Mail Accounts>Fetch Mail. Is there a way to automate this fetching process, and if so, can I change the time intervals in which it will fetch the mail from the email account?
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: New Ticket via Email

Post by crythias »

1) viewtopic.php?f=60&t=6586
2) See my last post
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
aolgin
Znuny newbie
Posts: 21
Joined: 03 Jun 2013, 17:44
Znuny Version: 3.2.7

Re: New Ticket via Email

Post by aolgin »

So is there no way to make the Fetch Mail run automatically over a time interval?

I also tried your suggested method for making only those emails in the database be accepted. As it stands, my system will bring up an Internal Server Error if there is a single email from a non-database user in the inbox, and nothing gets processed.
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: New Ticket via Email

Post by crythias »

aolgin wrote:So is there no way to make the Fetch Mail run automatically over a time interval?
http://doc.otrs.org/3.2/en/html/manual- ... l#cronjobs
aolgin wrote:I also tried your suggested method for making only those emails in the database be accepted. As it stands, my system will bring up an Internal Server Error if there is a single email from a non-database user in the inbox, and nothing gets processed.
What version of otrs are you using?
Did you look at your apache logs to determine what error was returned?

In 3.2.x, the code is around line 157:
Original code:

Code: Select all

    # if there is no customer user found!
    if ( !$GetParam{'X-OTRS-CustomerUser'} ) {
        $GetParam{'X-OTRS-CustomerUser'} = $GetParam{SenderEmailAddress};
    } 
Change to:

Code: Select all

    # if there is no customer user found!
    if ( !$GetParam{'X-OTRS-CustomerUser'} ) {
            $Self->{LogObject}->Log( Priority => 'info', Message => "$_ not in database" );
            return;
    } 
There really should be no error here as long as you've copy/pasted. I'd check the System Log entry as well to see what the error is.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
aolgin
Znuny newbie
Posts: 21
Joined: 03 Jun 2013, 17:44
Znuny Version: 3.2.7

Re: New Ticket via Email

Post by aolgin »

I have 3.2.7 installed.

That's the code I copied and pasted in, and I'm getting the following two errors when I run fetch mail:

[error] Can't locate object method "get" via package "Mail::IMAPClient" at C:/PROGRA~2/OTRS/OTRS//Kernel/System/MailAccount/IMAPTLS.pm line 210.\n
[error] [client 216.27.199.66] File does not exist: C:/Program Files (x86)/OTRS/Apache/htdocs/favicon.ico
aolgin
Znuny newbie
Posts: 21
Joined: 03 Jun 2013, 17:44
Znuny Version: 3.2.7

Re: New Ticket via Email

Post by aolgin »

Fetch mail runs automatically for me now.

Still having the issue when running Fetch Mail when there is an email from a non-registered email address in the inbox. Is there an easier way to do this than create several filters (my company has multiple domains for email) and have everything else go to spam?
montoxic
Znuny newbie
Posts: 38
Joined: 17 Feb 2013, 19:57
Znuny Version: 3.2.9
Real Name: Jonas Lindberg
Location: Sweden

Re: New Ticket via Email

Post by montoxic »

Hi

Crythias, do you know what to if i want to only accept customers mail that are in the customer db/ldap to just one emaildress.

for example i have like 10 mailboxes that are being fetch all the time, on one of these mailadresses(support@xxx.com) if want to only accept registred customers.

As i understand your current script does this to all mailboxes and ques?

Regards Jonas
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: New Ticket via Email

Post by crythias »

montoxic wrote:Crythias, do you know what to if i want to only accept customers mail that are in the customer db/ldap to just one emaildress.

for example i have like 10 mailboxes that are being fetch all the time, on one of these mailadresses(support@xxx.com) if want to only accept registred customers.
1) Please open new topic threads for your issue.
2) At the same time the code is looking for from, it can be altered to look for "to"
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
Locked