5 Replies Latest reply on Jul 14, 2017 1:06 PM by philmodjunk

    FMS Scheduled Script time limit exceeded


      I have a client who has three scripts scheduled to run on the server overnight. They have been running fine for a year and a half. Since Monday one of the has been getting the following error:


      2017-07-14 04:15:00.076 -0400    Error      691  Schedule "Employee_Time" aborted; time limit exceeded or server stopped.


      Since the FMS logs don't give any real debug type of information. What is the best way to determine why the script is suddenly timing out?



        • 1. Re: FMS Scheduled Script time limit exceeded

          Do the logs show any error codes?( some do not indicate that your script is failing)


          We add our own logging system that adds records to a table as the script runs. The trick is to log data that tells what part of your script created the record along with any field or variable values that might be of interest. 

          1 of 1 people found this helpful
          • 2. Re: FMS Scheduled Script time limit exceeded

            First ask what has changed in the system in the last year and a half?

            i.e. have you upgraded FM versions? Have you upgraded your OS? Have you implemented any functionality that could interfere with the proper running of the script?

            If there is no change that could contribute then step through the script to see if there are any bottlenecks..

            processing lots of records than before, new script triggers firing when switching layouts etc...

            • 3. Re: FMS Scheduled Script time limit exceeded

              Kris has made very good points. The amount of time batch operations take are often a non linear function of the number of items in the batch. Sorts and Searches are very common examples of this. Doubling the number of records to sort or search more than doubles the amount of time required to complete the task. Thus, a task that completed in a reasonable time a year ago might now take very unreasonable amounts of time to complete because the number of items to process have greatly increased over time.

              • 4. Re: FMS Scheduled Script time limit exceeded

                Nothing has changed. Neither the OS nor FMS have been upgraded. The script itself hasn't been changed.


                I've stepped through the script on a local version of the database. It runs fine. There are a number of Finds/Constrain Found Set script steps. I suppose it could be possible that the number of records in the table has just reached a point where it is slowing down the script.


                I do see a number of Error 509 (Field requires a valid value). Doesn't make a lot of sense since it shows the script step as "Go to Record/Request/Page"

                • 5. Re: FMS Scheduled Script time limit exceeded

                  That makes perfect sense to me. Changing to another record will commit any data changes your script made to the current record and that in turn will trip data validation errors if any exist. Looks like you need to set up your own logger to check field values at this point in the process.