Hi, the sa user was removed from the database last month because of security reasons. Everything is still working fine from what needs to be working. However, every Saturday morning, between 2AM and 3AM, something is causing timeouts and database lag to th

Hi, the sa user was removed from the database last month because of security reasons. Everything is still working fine from what needs to be working. However, every Saturday morning, between 2AM and 3AM, something is causing timeouts and database lag to the point where the data can't log to the database, and they thus can't run production. All SQL log executes time out. Looked into the logs and they indicate the attached:

The logs start around 10 minutes before 2am and continue up to about 20 minutes before 3am, which aligns with when they are experiencing the data logging issues. I'm not sure if the issue is indeed with MES or if something else is running at this time that just happens to cause the below issues. Can you please assist?
Not using the MES anymore to its fullest (all OCO objects are undeployed). The data is logged to normal "flat file" tables, however there is still MES code that runs that logs data to the data_log_16 and 48 tables. But this is executed for every single part, could this be the issue?

MES 2014 R2 Version 5.2.0
Windows Server 2012 R2 Standard

My question is also if you know what in MES normally uses the SA user (is there any configurator?) and what could possibly be running every week at this time? Are there something like jobs or routines that can be setup in MES that I can look at? If so, where are they setup and configured?
We are not using the MES anymore to its fullest (all OCO objects are undeployed). The data is logged to normal "flat file" tables, however there is still MES code that runs that logs data to the data_log_16 and 48 tables. But this is executed for every single part.

  • First, I'm sure you realize that MES 2014 R2 (release date of Feb 2016) is an older version of MES.  If security is a concern, then you really should upgrade to the latest version.  There will be another MES release later this year.

    Within the MES product, the MES Service runs periodic tasks in the background.  These tasks occur minutely, hourly, and daily.  There are no weekly tasks; however, there are some configuration options that could trigger something to happen at a specific time.

    One option is Supply Chain Connector (SCC).  Are there any integrations defined in your system that leverage Supply Chain Connector?  If you are unsure, run the MES Supervisor application and see if SCC is enabled and any tasks defined.  SCC has options to execute custom SQL Server stored procedures or query tables.  These can be scheduled to happen at specific times.

    The other option is if you've configured the MES Service to archive data at a specific time.  In MES Client, find the system parameters "Day to archive data" and "Time to archive data".  As part of the hourly task, the MES Service will check to see if these parameters set a time to run the archive process and if so will use the "Archive database server name" and "Archive database name" system parameters to run a stored procedure.  This is not generally an approach used and has been removed from the product in the current version.

    As this is happening at a specific time and day, there may be SQL Server jobs defined for archiving, restoring, or backup that were configured using the "sa" account.  Someone may also have created a windows job to call the MES APRSchedule.exe as described here Running an Archive or Purge Job Automatically.

    I don't have the documentation set from MES 2014 R2 but look for a document titled MES Service User Guide that would provide additional details on what I've covered.  The current version of this guide is here Maintenance Services which does not include content about the removed archiving system parameters.