Jenkins Agent running slow MacOS

Jenkins version - 2.387.3.5
JDK - 11.0
Plugins - multiple

Hi this question is extremely similar to HELP! Only the Jenkins agent running on Mac OS is slow. I’m creating this topic as there doesn’t seem like there was any resolution.

Context:
I’ve recently set up a brand new MacOS M2 Mini physical machine using agent.jar as an agent node to run a script in the pipeline. Running the script locally (not through the pipeline) works fine and reasonably fast.

Running through the pipeline however, takes more than an hour just to run a simple pip install script.

I’ve previously ran this script on another node/agent through another MacOS Virtual Machine and there was no issues. My physical machine is moderately spec’ed with 16GB RAM.

Was wondering what could be causing this. Thanks

Do i have to configure the heap of the agent?

Tried tweaking around with JVM options but to no avail

Hello and welcome to this community, @wilfy. :wave:

Would you be able to share your pipeline, your configuration, the JDK you’re using (version number and vendor), your macOS distro, and your Jenkins plugin list?

You could maybe have a detailed look at the steps to see which one is taking the most time, and you could also try a thread dump.

My $0.02.