How do I debug rspec running out of memory?

I am working on a PR that upgrades Ruby and Webpacker. For some reason, my rspec processes are running out of memory in every build. I changed the docker image from circleci/ruby:2.6.7-browsers to circleci/ruby:2.7.5-browsers which changes from Debian 10 to Debian 11.

I found a community post that mentioned using dmesg to debug these issues, but it didn’t say how. Can anyone tell me how I could start debugging these issues?

:wave: Hi @brandoncc,

Welcome to the CircleCI community!

Have you tried SSH-ing into the build to run the related commands manually? You can do so as outlined in our documentation.

Alternatively, you could opt to record/monitor the job’s memory usage.

Also, in case you haven’t already done so, try using a larger resource class.

Let me know if this helps.