1

We have a Raspberry Pi (with Raspbian/Debian 8/Jessie) set up to run chromium in kiosk mode as a status monitor for our local network. It is set up to load one page from a server on our network; the page has a tiny bit of Javascript that simply reloads the page every 30 seconds.

It works great for about 2 hours then crashes with an "aw snap!" error page.

I've been doing some digging & figured out how to turn on logging for chromium. This revealed the following error message:

[246:254:0117/113914:ERROR:platform_thread_posix.cc(118)] pthread_create: Resource temporarily unavailable

A little googling led me to this page which suggests that the problem is that the system does not have enough threads available. I checked the limit on the system using ulimit -a abd found that max user processes is equal to 7336.

Next I set up a simple script to log the number of chromium processes using ps -elfT | grep chrom | wc -l and found that chromium is slowly spawning more threads, crashing when the number of threads reaches 222 (up from a low of around 50).

It's not definitive proof that this is the problem, but the steadily increasing number of threads does look like a problem, which leads to my question:

How can I prevent chromium from constantly spawning new threads?

  • Not using chrome/chromium i guess. That is the best way to prevent it from opening so many threads. lol - blog.chromium.org/2008/09/multi-process-architecture.html - Despite the joke it is at chrome's heart to do that way, and some tweaks like --memory-model=low(that enable low resource profile) can no longer be configured. – user34720 Jan 17 '17 at 19:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.