ARD Agent leaks memory

DeltaMac

macrumors G4
Jul 30, 2003
10,338
2,736
Delaware
How much memory do you have installed?
What does the "Memory Pressure" graph show, at the bottom of your Activity Monitor/Memory tab?
 
  • Like
Reactions: Surveyor

Surveyor

macrumors newbie
Jun 25, 2020
2
0
Suffolk
Hi,
I am having the same issue on a MacMini with 8GB ram. This Mac only runs Filemaker Server and I find that the memory used by ARDAgent increases throughout the day until it completely fills the memory and causes the machine to become very sluggish. Remote users of the FMP server are also significantly affected.

So far my solution has been to force quit ARDAgent whenever I find the server running slowly. ARDAgent is immediately reloaded by the OS and starts with 3.6mb memory used but stats to increase this at a rate of approximately 1mb every 5 minutes initially. This rate varies and seems to speed up exponentially (increased to 23.2mb after 15 mins) so that the memory is full within 4-5 hours.

Is there a 'proper' solution to this, other than running a cron job (deprecated) every hour?
 

Surveyor

macrumors newbie
Jun 25, 2020
2
0
Suffolk
Ok, done some more digging and found an article about memory leaks from developer.apple that says memory must be deallocated when using malloc. I ran leaks (sudo leaks [pid]) and found there were thousands of 'notes mallocs for 1241k'. The number of nodes continually increases, so I am guessing Apple have not followed their own developer guidelines on coding.

I then checked another Mac (i5 iMac 27") that was running the same OS Catalina and found that ARDAgent memory stays put at 3.9mb. There are many more apps running on the iMac and only one server process running on the MacMini (FMS) and first thought it may be related to Filemaker. I then realised that my router port points the ARD ports (5900, 3282, 3031) to the MacMini so switched this over to the iMac and the rate of memory increase on the MacMini has slowed dramatically and all but stopped. The odd thing is that ARDAgent running on the iMac does not appear to be increasing its memory usage.

A possible solution but needs further observation. Post a reply if this works for anyone else.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.