Is anyone else testing MRP in 2024 Pilot and noticing the same file-locking issue on the log files as happened back in June in 2023.2?
If you weren’t hit by the June bug, oh boy! We had MRP down for a full week and support was…slow (I’m being generous here)…to get it back up. Turned out it was a combination Microsoft and Epicor issue causing the log file to lock while MRP is running, and it just spins and spins until it finally dies and no unfirm jobs are created.
The log file entries look like this:
<Erp.Internal.MR.MrpExp msg=“System.IO.IOException: The process cannot access the file ‘C:\epi\storage\epicordata[obscured]\Companies[obscured]\Log[obscured]\AdHocMRP.log’ because it is being used by another process.
at Microsoft.Win32.SafeHandles.SafeFileHandle.CreateFile(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options)
at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode)
at System.IO.File.WriteToFile(String path, FileMode mode, String contents, Encoding encoding)
at Erp.Internal.MR.MrpExp.logfile_logType() in C:_releases\ERP\ERP11.3.100.8\Source\Server\Internal\MR\MrpExp\MrpExp.cs:line 1734” machine=“[obscured]” pid=“28256” tid=“22”/>
(edit) and this: <Erp.Internal.MR.MrpExp msg="Overwrite of log file unsuccessful. Log will be appended to." machine="PLT159751" pid="28256" tid="22"/>
Support is telling me it’s fixed in 2024.1.8, it can’t be replicated in their system, and no one else is having this issue. I have a very hard time believing that.
I’m going to test that now…appreciate the suggestion. In reality, we need log files to root out MRP issues, because we always have them. But it would at least lead to more proof that the issue is in the log writing.
No luck, although there isn’t really an explicit option to exclude a log file, that I can find. I just ran it without a name and it’s stuck…been running for over 12 hours. Sigh…
Not sure what your part setup is like but something I have used to diagnose part setup issues is to turn off the finite scheduling and increase the processes to 3 for both MRP and Scheduling. The scheduling processor is used for job deletion and some other items other than just scheduling. If that runs without a log and completes then you can move to adding the logs for additional details.
I have also reviewed the log files before the process has completed, sometimes you are able to see where it has stopped or see a log file that is significantly larger than the rest which can indicate a issue, although the size sort in the server file download doesn’t work.
Most of the time when I had MRP hangs it was due to the swapping pieces per hour for hours per piece, resulting in the scheduling engine trying to schedule out 12 years.
Appreciate the advice. The screenshot wasn’t showing the settings as we usually have them when running. We don’t typically enable finite scheduling. I will definitely pass along your advice about the number of processes.
Other than your current log issue, what other issues do you use the log files to diagnose?
What are the typical settings you use for MRP?
I am sure it has been tried but did changing AdHocMRP.log to something else work?
One other thing to check is create a BAQ for the ice.SysTask table, filter on TaskStatus = ‘Active’ or History = False (Make sure to try both) this may show a MRP process that was stuck and killed in the background but not updated correctly in the database. I have seen it stop the process from working correctly as there are a few different fields that can indicate a process is running. If you find anything in there share it, there might be a way to update the table to clear the bad process.
I used to do a lot of consulting with MRP and diagnostics of issues. I am now on the customer cloud side so I have had to come up with some different ways to diagnose issues.
I’m not the person who typically runs it - I’m just trying to assist getting it fixed. I tried running MRP last night leaving the filename blank, and that’s what’s currently stuck. I can’t try anything until support can kill the task for me.
Really appreciate the advice about the Ice.SysTask table - I didn’t know about that. I can see MRP is 5% complete after running since 4:30PM EST yeseterday. I ran it both ways and got the same result (TaskStatus = ‘Active’, History=false).
I had someone run me through the options they usually select when running MRP yesterday. They are:
Allow Historical Dates
Use Production Preparation Buffer
Get Details from Quote
Include only parts w/Activity or Min/Safety
No recommendations on # of MRP/Schedulers, so I left them at 1 each.