(SOLVED) Pending Auto fails since renaming state

Moderator: crythias

Locked
bayerex
Znuny expert
Posts: 164
Joined: 03 Dec 2012, 00:30
Znuny Version: 3.2.7

(SOLVED) Pending Auto fails since renaming state

Post by bayerex »

Hi all,

a while ago I renamed the 'pending auto' state to "auto close" and also renamed 'closed successful' to "closed" and I believe it is since then that it has stopped working. When I set a ticket to 'auto close' it never changes the state to 'closed' after the elapsed time and the continues forever to decrease into the minus.

I've already updated the value to 'closed' in: Ticket -> Core::Ticket:::PendingAutoStateType

Cron is running and checks for new emails.

What else do I need to do?

Thanks in advance.
Last edited by bayerex on 28 Feb 2013, 12:48, edited 1 time in total.
Current Production Server (recently switched from Windows)
OTRS 3.2.7 on Ubuntu 12.04LTS 64bit
PHP 5.3.10-1ubuntu3.6
mysql Ver 14.14 Distrib 5.5.31

Previous Production Server:
Windows 2008
MySQL 5.1.51 Community Server
Strawberry Perl 5.12.3.0
bayerex
Znuny expert
Posts: 164
Joined: 03 Dec 2012, 00:30
Znuny Version: 3.2.7

Re: Pending Auto fails since renaming state

Post by bayerex »

Does anyone have any suggestions for this? Would be appreciated! Thanks
Current Production Server (recently switched from Windows)
OTRS 3.2.7 on Ubuntu 12.04LTS 64bit
PHP 5.3.10-1ubuntu3.6
mysql Ver 14.14 Distrib 5.5.31

Previous Production Server:
Windows 2008
MySQL 5.1.51 Community Server
Strawberry Perl 5.12.3.0
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Pending Auto fails since renaming state

Post by crythias »

unfortunately, pending states require the word pending at the beginning.
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
jojo
Znuny guru
Posts: 15020
Joined: 26 Jan 2007, 14:50
Znuny Version: Git Master
Contact:

Re: Pending Auto fails since renaming state

Post by jojo »

you also have to adjust the settings in sysconfig to make it work.

(Pendig states won't need the word pending in the name)
"Production": OTRS™ 8, OTRS™ 7, STORM powered by OTRS
"Testing": ((OTRS Community Edition)) and git Master

Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
bayerex
Znuny expert
Posts: 164
Joined: 03 Dec 2012, 00:30
Znuny Version: 3.2.7

Re: Pending Auto fails since renaming state

Post by bayerex »

jojo wrote:you also have to adjust the settings in sysconfig to make it work.

(Pendig states won't need the word pending in the name)
Thanks Jojo, although could you give me any more clue what I have to change in there? As I said, I've already updated 'Core::Ticket:::PendingAutoStateType' without success. Searching 'pending auto close+' doesn't bring up much either.
Current Production Server (recently switched from Windows)
OTRS 3.2.7 on Ubuntu 12.04LTS 64bit
PHP 5.3.10-1ubuntu3.6
mysql Ver 14.14 Distrib 5.5.31

Previous Production Server:
Windows 2008
MySQL 5.1.51 Community Server
Strawberry Perl 5.12.3.0
jojo
Znuny guru
Posts: 15020
Joined: 26 Jan 2007, 14:50
Znuny Version: Git Master
Contact:

Re: Pending Auto fails since renaming state

Post by jojo »

don't change Core::Ticket:::PendingAutoStateType!

Have a look at Ticket::StateAfterPending
"Production": OTRS™ 8, OTRS™ 7, STORM powered by OTRS
"Testing": ((OTRS Community Edition)) and git Master

Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
bayerex
Znuny expert
Posts: 164
Joined: 03 Dec 2012, 00:30
Znuny Version: 3.2.7

Re: Pending Auto fails since renaming state

Post by bayerex »

jojo wrote: Have a look at Ticket::StateAfterPending
These are my settings, they seem correct to me so I don't understand why it just doesn't work!
pending settings.png
pending settings2.png
You do not have the required permissions to view the files attached to this post.
Current Production Server (recently switched from Windows)
OTRS 3.2.7 on Ubuntu 12.04LTS 64bit
PHP 5.3.10-1ubuntu3.6
mysql Ver 14.14 Distrib 5.5.31

Previous Production Server:
Windows 2008
MySQL 5.1.51 Community Server
Strawberry Perl 5.12.3.0
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Pending Auto fails since renaming state

Post by crythias »

make sure bin/otrs.PendingJobs.pl is running in cron under otrs user. It's the only thing that obeys Ticket::StateAfterPending

otrs/var/cron/pending_jobs should not have a .dist after it.

It also only checks by default every 2 hours at 45 minutes after the hour.
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
bayerex
Znuny expert
Posts: 164
Joined: 03 Dec 2012, 00:30
Znuny Version: 3.2.7

Re: Pending Auto fails since renaming state

Post by bayerex »

crythias wrote:make sure bin/otrs.PendingJobs.pl is running in cron under otrs user. It's the only thing that obeys Ticket::StateAfterPending

otrs/var/cron/pending_jobs should not have a .dist after it.

It also only checks by default every 2 hours at 45 minutes after the hour.
Funny thing is, since I ran PendingJobs.pl from the command line, everything works again and has done for a week now :)

Out of interest. How do I check what user a .pl is running under? Is that the top line in crontab.txt? (MAILTO=...)
Current Production Server (recently switched from Windows)
OTRS 3.2.7 on Ubuntu 12.04LTS 64bit
PHP 5.3.10-1ubuntu3.6
mysql Ver 14.14 Distrib 5.5.31

Previous Production Server:
Windows 2008
MySQL 5.1.51 Community Server
Strawberry Perl 5.12.3.0
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: (SOLVED) Pending Auto fails since renaming state

Post by crythias »

bayerex wrote:Out of interest. How do I check what user a .pl is running under? Is that the top line in crontab.txt? (MAILTO=...)
the icky response is to answer the reverse question:
How do I check if the .pl is running under otrs?
crontab -l -u otrs | more
or
crontab -l -u otrs | grep "\.pl"
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
bayerex
Znuny expert
Posts: 164
Joined: 03 Dec 2012, 00:30
Znuny Version: 3.2.7

Re: (SOLVED) Pending Auto fails since renaming state

Post by bayerex »

crythias wrote:
bayerex wrote:Out of interest. How do I check what user a .pl is running under? Is that the top line in crontab.txt? (MAILTO=...)
the icky response is to answer the reverse question:
How do I check if the .pl is running under otrs?
crontab -l -u otrs | more
or
crontab -l -u otrs | grep "\.pl"
ok... how does that work under windows?
Current Production Server (recently switched from Windows)
OTRS 3.2.7 on Ubuntu 12.04LTS 64bit
PHP 5.3.10-1ubuntu3.6
mysql Ver 14.14 Distrib 5.5.31

Previous Production Server:
Windows 2008
MySQL 5.1.51 Community Server
Strawberry Perl 5.12.3.0
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: (SOLVED) Pending Auto fails since renaming state

Post by crythias »

bayerex wrote:ok... how does that work under windows?
In theory, it *should* run as the service account.
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
bayerex
Znuny expert
Posts: 164
Joined: 03 Dec 2012, 00:30
Znuny Version: 3.2.7

Re: (SOLVED) Pending Auto fails since renaming state

Post by bayerex »

crythias wrote:
bayerex wrote:ok... how does that work under windows?
In theory, it *should* run as the service account.
No, I mean literally how does one enter that command in Windows? Doesn't it work a bit different?
Current Production Server (recently switched from Windows)
OTRS 3.2.7 on Ubuntu 12.04LTS 64bit
PHP 5.3.10-1ubuntu3.6
mysql Ver 14.14 Distrib 5.5.31

Previous Production Server:
Windows 2008
MySQL 5.1.51 Community Server
Strawberry Perl 5.12.3.0
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: (SOLVED) Pending Auto fails since renaming state

Post by crythias »

bayerex wrote:No, I mean literally how does one enter that command in Windows? Doesn't it work a bit different?
I don't expect there to be a crontab command line in windows, unless it's part of CronW, about which I am unfamiliar as I use OTRS on Linux. That's why I said the cronjob will likely run as the service account used in services.msc for CronW
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