Email are not fetching automatically

Moderator: crythias

Post Reply
lightwave22
Znuny newbie
Posts: 13
Joined: 03 Jun 2011, 04:09
Znuny Version: 3.0.7
Real Name: stephane
Company: Solutions PRP

Email are not fetching automatically

Post by lightwave22 »

:( I just re install OTRS 3.0.8 Since that OTRS is not fetching the email automatically. I alway need to it the refresh bottum.

thank you for the help
Wolfgangf
Znuny ninja
Posts: 1029
Joined: 13 Apr 2009, 12:26
Znuny Version: 6.0.13
Real Name: Wolfgang Fürtbauer
Company: PBS Logitek GmbH
Location: Pinsdorf

Re: Email are not fetching automatically

Post by Wolfgangf »

probably your cron-jobs are not running - did you check this already?
Produktiv:
OTRS 6.0.13/ ITSM 6.0.13
OS: SUSE Linux (SLES 12, Leap), MySql 5.5.x, 5.6.x
Windows 2012 AD Integration (agents and customers), Nagios integration (incidents, CMDB), Survey, TimeAccounting
lightwave22
Znuny newbie
Posts: 13
Joined: 03 Jun 2011, 04:09
Znuny Version: 3.0.7
Real Name: stephane
Company: Solutions PRP

Re: Email are not fetching automatically

Post by lightwave22 »

Wolfgangf wrote:probably your cron-jobs are not running - did you check this already?
Sorry i am a newby :? No I did not check. I am on windows 2008 server. where can i found that?
Wolfgangf
Znuny ninja
Posts: 1029
Joined: 13 Apr 2009, 12:26
Znuny Version: 6.0.13
Real Name: Wolfgang Fürtbauer
Company: PBS Logitek GmbH
Location: Pinsdorf

Re: Email are not fetching automatically

Post by Wolfgangf »

in the bin directory is a program otrs.Cron4Win32.pl

and: even (and specially) newbys should read the docu / admin handbook!
Produktiv:
OTRS 6.0.13/ ITSM 6.0.13
OS: SUSE Linux (SLES 12, Leap), MySql 5.5.x, 5.6.x
Windows 2012 AD Integration (agents and customers), Nagios integration (incidents, CMDB), Survey, TimeAccounting
lightwave22
Znuny newbie
Posts: 13
Joined: 03 Jun 2011, 04:09
Znuny Version: 3.0.7
Real Name: stephane
Company: Solutions PRP

Re: Email are not fetching automatically

Post by lightwave22 »

Thank you Wolfgangf, i check cron-job is not running, what can i do to solve that problem?
Wolfgangf
Znuny ninja
Posts: 1029
Joined: 13 Apr 2009, 12:26
Znuny Version: 6.0.13
Real Name: Wolfgang Fürtbauer
Company: PBS Logitek GmbH
Location: Pinsdorf

Re: Email are not fetching automatically

Post by Wolfgangf »

I'm not running it on Windows :(
but as far as I know:
- create the crontab with otrs.Cron4Win32.pl
- start cron by starting the cmd.exe and enter the command

Code: Select all

net start cron
BR
Produktiv:
OTRS 6.0.13/ ITSM 6.0.13
OS: SUSE Linux (SLES 12, Leap), MySql 5.5.x, 5.6.x
Windows 2012 AD Integration (agents and customers), Nagios integration (incidents, CMDB), Survey, TimeAccounting
lightwave22
Znuny newbie
Posts: 13
Joined: 03 Jun 2011, 04:09
Znuny Version: 3.0.7
Real Name: stephane
Company: Solutions PRP

Re: Email are not fetching automatically

Post by lightwave22 »

Now the service is running,

I just check the crontab.txt files and the files is completly empty. I don't know if it is normal?
Wolfgangf
Znuny ninja
Posts: 1029
Joined: 13 Apr 2009, 12:26
Znuny Version: 6.0.13
Real Name: Wolfgang Fürtbauer
Company: PBS Logitek GmbH
Location: Pinsdorf

Re: Email are not fetching automatically

Post by Wolfgangf »

that's what otrs.Cron4Win32.pl is good for
if you run

Code: Select all

perl.exe <install-root>otrs\bin\otrs.Cron4Win32.pl
it reads the .dist files in

Code: Select all

 <install-root>var\cron\
and creates the crontab.txt

Hope that helps
Produktiv:
OTRS 6.0.13/ ITSM 6.0.13
OS: SUSE Linux (SLES 12, Leap), MySql 5.5.x, 5.6.x
Windows 2012 AD Integration (agents and customers), Nagios integration (incidents, CMDB), Survey, TimeAccounting
lightwave22
Znuny newbie
Posts: 13
Joined: 03 Jun 2011, 04:09
Znuny Version: 3.0.7
Real Name: stephane
Company: Solutions PRP

Re: Email are not fetching automatically

Post by lightwave22 »

Hello Wolfgangf,

I tried exactly what you told me, but the when i do perl.exe <install-root>otrs\bin\otrs.Cron4Win32.pl the crontab.txt created is always empty.
OSAdam
Znuny newbie
Posts: 2
Joined: 10 Jun 2011, 17:22
Znuny Version: 3.0.8
Real Name: Adam G
Company: One Stop

Re: Email are not fetching automatically

Post by OSAdam »

We are having the exact same problem. We can manually fetch and the emails arrive. I ran the perl script but didn't have access so I updated the security to allow my login full access. Ran the script and it ran. Looked at crontab.txt and it was blank. We've installed previously on an old server with Windows 2003 and that works perfectly (OTRS 3.0.6). I took that crontab.txt and it still doesn't fetch.

Thanks in advance!
Adam
Wolfgangf
Znuny ninja
Posts: 1029
Joined: 13 Apr 2009, 12:26
Znuny Version: 6.0.13
Real Name: Wolfgang Fürtbauer
Company: PBS Logitek GmbH
Location: Pinsdorf

Re: Email are not fetching automatically

Post by Wolfgangf »

:( I don't have a Windows installation, but ...
1) I've seen the same problem beeing posted in the forum
2) you could paste your <install-root>var\cron\*.dist files probably we can take the relevant lines and copy it to crontab.txt
3) can one of the windows guys help please?
Produktiv:
OTRS 6.0.13/ ITSM 6.0.13
OS: SUSE Linux (SLES 12, Leap), MySql 5.5.x, 5.6.x
Windows 2012 AD Integration (agents and customers), Nagios integration (incidents, CMDB), Survey, TimeAccounting
crythias
Moderator
Posts: 10169
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Email are not fetching automatically

Post by crythias »

Actually, it shouldn't read the .dist files. remove the .dist (because .dist = .distributed with the install)

Edit: but only the .dist for files that make sense to cron.
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
OSAdam
Znuny newbie
Posts: 2
Joined: 10 Jun 2011, 17:22
Znuny Version: 3.0.8
Real Name: Adam G
Company: One Stop

Re: Email are not fetching automatically

Post by OSAdam »

Hello,
First, thanks so much for the quick responses.

In our Windows 2003, OTRS 3.0.6, we only installed and it worked immediately. We didn't have to delete the .dist or anything. I just uninstalled and reinstalled but in the Program Files directory (vs. the Program Files (x86) directory). In the .06 version, I edited the crontab.txt file from 10 to 2 minutes (crontab.txt had the data below in it already) and it started fetching ever 2 minutes.

The current environment: 64 bit, Windows 2008 R2, run on a VM (using HyperV).
Previous Version that worked without a hitch: 32 bit, Windows 2003

Resolution:
I think I figured out what the problem was in this latest install. The original install, I accepted the default location for the installation....which was "program files (x86)". I uninstalled and installed but changed to "program files" directory. At first, the crontab.txt was still blank so I copied the Windows 2003 info (see below) into this new install and 10 minutes later the emails started coming in.


MAILTO="root@localhost"

20 0 * * 0 C:/PROGRA~1/OTRS/StrawberryPerl/perl/bin/perl.exe C:/PROGRA~1/OTRS/OTRS/bin/otrs.DeleteCache.pl --expired
30 0 * * 0 C:/PROGRA~1/OTRS/StrawberryPerl/perl/bin/perl.exe C:/PROGRA~1/OTRS/OTRS/bin/otrs.LoaderCache.pl -o delete


*/10 * * * * C:/PROGRA~1/OTRS/StrawberryPerl/perl/bin/perl.exe C:/PROGRA~1/OTRS/OTRS/bin/otrs.GenericAgent.pl -c db

*/20 * * * * C:/PROGRA~1/OTRS/StrawberryPerl/perl/bin/perl.exe C:/PROGRA~1/OTRS/OTRS/bin/otrs.GenericAgent.pl


45 */2 * * * C:/PROGRA~1/OTRS/StrawberryPerl/perl/bin/perl.exe C:/PROGRA~1/OTRS/OTRS/bin/otrs.PendingJobs.pl

10 0 * * * C:/PROGRA~1/OTRS/StrawberryPerl/perl/bin/perl.exe C:/PROGRA~1/OTRS/OTRS/bin/otrs.cleanup

*/10 * * * * C:/PROGRA~1/OTRS/StrawberryPerl/perl/bin/perl.exe C:/PROGRA~1/OTRS/OTRS/bin/otrs.PostMasterMailbox.pl

01 01 * * * C:/PROGRA~1/OTRS/StrawberryPerl/perl/bin/perl.exe C:/PROGRA~1/OTRS/OTRS/bin/otrs.RebuildTicketIndex.pl

55 */2 * * * C:/PROGRA~1/OTRS/StrawberryPerl/perl/bin/perl.exe C:/PROGRA~1/OTRS/OTRS/bin/otrs.DeleteSessionIDs.pl --expired

35 * * * * C:/PROGRA~1/OTRS/StrawberryPerl/perl/bin/perl.exe C:/PROGRA~1/OTRS/OTRS/bin/otrs.UnlockTickets.pl --timeout
lightwave22
Znuny newbie
Posts: 13
Joined: 03 Jun 2011, 04:09
Znuny Version: 3.0.7
Real Name: stephane
Company: Solutions PRP

Re: Email are not fetching automatically

Post by lightwave22 »

ty you for the data it work now
MichaelR
Znuny expert
Posts: 250
Joined: 12 Oct 2010, 01:35
Znuny Version: 3.0.9
Company: LRS Health

Re: Email are not fetching automatically

Post by MichaelR »

Yeah, mine is running on x64 Windows 7, never had to use otrs.Cron4Win32.pl
I installed it in the default location, and the service should start automatically at boot, if not, change it to that!
OTRS: 3.0.9 & ITSM 3.0.4 - OS: Windows 7 - DB: MySQL - Heaps of random/useful hacks :)
[Major Code Changes]
ArticleFreeTime1-3
Ability to search ArticleFreeText
lightwave22
Znuny newbie
Posts: 13
Joined: 03 Jun 2011, 04:09
Znuny Version: 3.0.7
Real Name: stephane
Company: Solutions PRP

Re: Email are not fetching automatically

Post by lightwave22 »

MichaelR wrote:Yeah, mine is running on x64 Windows 7, never had to use otrs.Cron4Win32.pl
I installed it in the default location, and the service should start automatically at boot, if not, change it to that!
Juste found out that averytime I boot the server, the files crontab.txt contant is errase.
Mike_B
Moderator
Posts: 266
Joined: 12 Jan 2010, 18:16
Znuny Version: CVS HEAD

Re: Email are not fetching automatically

Post by Mike_B »

Yes, that is because of said issue with the bin/otrs.Cron4Win32.pl file -- I'm sorry, it was me who made the error here..

If you would open the file, change line 48 from

Code: Select all

next CRONFILE if ( !-f $CronData );
to

Code: Select all

next CRONFILE if ( !-f "$Directory/$CronData" );
then you will be good.

Thanks, and sorry for the inconvenience caused...
--
Mike
huntingbears.nl - @michielbeijen on Twitter
MichaelR
Znuny expert
Posts: 250
Joined: 12 Oct 2010, 01:35
Znuny Version: 3.0.9
Company: LRS Health

Re: Email are not fetching automatically

Post by MichaelR »

Mike_B wrote:Yes, that is because of said issue with the bin/otrs.Cron4Win32.pl file -- I'm sorry, it was me who made the error here..

If you would open the file, change line 48 from

Code: Select all

next CRONFILE if ( !-f $CronData );
to

Code: Select all

next CRONFILE if ( !-f "$Directory/$CronData" );
then you will be good.
I can't see that line anywhere, must have been already fixed in 3.0.7 :D
OTRS: 3.0.9 & ITSM 3.0.4 - OS: Windows 7 - DB: MySQL - Heaps of random/useful hacks :)
[Major Code Changes]
ArticleFreeTime1-3
Ability to search ArticleFreeText
Mike_B
Moderator
Posts: 266
Joined: 12 Jan 2010, 18:16
Znuny Version: CVS HEAD

Re: Email are not fetching automatically

Post by Mike_B »

MichaelR wrote: I can't see that line anywhere, must have been already fixed in 3.0.7 :D
No, actually, it's working in 3.0.7, it's broken in 3.0.8 and in upcoming 3.0.9 it will be working again.
--
Mike
huntingbears.nl - @michielbeijen on Twitter
lightwave22
Znuny newbie
Posts: 13
Joined: 03 Jun 2011, 04:09
Znuny Version: 3.0.7
Real Name: stephane
Company: Solutions PRP

Re: Email are not fetching automatically

Post by lightwave22 »

thank you guy's for the info.

I have a other issus with the fetch When user reply to a mail OTRS don't erase the mail And ad the same copie of the reply my over and over.

Need some help.
Post Reply