Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Failed to launch the browser process! #8192

Closed
meirtb opened this issue Apr 5, 2022 · 4 comments
Closed

[Bug]: Failed to launch the browser process! #8192

meirtb opened this issue Apr 5, 2022 · 4 comments

Comments

@meirtb
Copy link

meirtb commented Apr 5, 2022

Bug description

I have a REST API deployed to Heroku with the puppeteer buildpack.

For some reason sometimes the request fails because puppeteer throws one of the following errors:
1.

Failed to launch the browser process! spawn /app/node_modules/puppeteer/.local-chromium/linux-970485/chrome-linux/chrome EAGAIN


TROUBLESHOOTING: https://github.com/puppeteer/puppeteer/blob/main/docs/troubleshooting.md
Failed to launch the browser process!
[0405/091201.326548:ERROR:platform_thread_posix.cc(151)] pthread_create: Resource temporarily unavailable (11)
[0405/091201.326655:FATAL:simple_thread.cc(55)] Check failed: success. 
#0 0x559bebb89469 base::debug::CollectStackTrace()
#1 0x559bebaeff33 base::debug::StackTrace::StackTrace()
#2 0x559bebb02d50 logging::LogMessage::~LogMessage()
#3 0x559bebb0390e logging::LogMessage::~LogMessage()
#4 0x559bebb7364f base::SimpleThread::StartAsync()
#5 0x559bebb735ce base::SimpleThread::Start()
#6 0x559be9bc27c8 content::SandboxHostLinux::Init()
#7 0x559beb69cd41 content::ContentMainRunnerImpl::Initialize()
#8 0x559beb69aeb9 content::RunContentProcess()
#9 0x559beb69b00e content::ContentMain()
#10 0x559beb6f5fca headless::(anonymous namespace)::RunContentMain()
#11 0x559beb6f5cd5 headless::HeadlessShellMain()
#12 0x559be82e7668 ChromeMain
#13 0x7f96da9650b3 __libc_start_main
#14 0x559be82e74aa _start

Received signal 6
#0 0x559bebb89469 base::debug::CollectStackTrace()
#1 0x559bebaeff33 base::debug::StackTrace::StackTrace()
#2 0x559bebb88f71 base::debug::(anonymous namespace)::StackDumpSignalHandler()
#3 0x7f96db83a3c0 (/usr/lib/x86_64-linux-gnu/libpthread-2.31.so+0x143bf)
#4 0x7f96da98403b gsignal
#5 0x7f96da963859 abort
#6 0x559bebb881f5 base::debug::BreakDebuggerAsyncSafe()
#7 0x559bebb03221 logging::LogMessage::~LogMessage()
#8 0x559bebb0390e logging::LogMessage::~LogMessage()
#9 0x559bebb7364f base::SimpleThread::StartAsync()
#10 0x559bebb735ce base::SimpleThread::Start()
#11 0x559be9bc27c8 content::SandboxHostLinux::Init()
#12 0x559beb69cd41 content::ContentMainRunnerImpl::Initialize()
#13 0x559beb69aeb9 content::RunContentProcess()
#14 0x559beb69b00e content::ContentMain()
#15 0x559beb6f5fca headless::(anonymous namespace)::RunContentMain()
#16 0x559beb6f5cd5 headless::HeadlessShellMain()
#17 0x559be82e7668 ChromeMain
#18 0x7f96da9650b3 __libc_start_main
#19 0x559be82e74aa _start
  r8: 0000000000000000  r9: 00007ffd506a4ad0 r10: 0000000000000008 r11: 0000000000000246
 r12: 000009e4002b8000 r13: 000009e4002b8018 r14: 000009e4002b8010 r15: 000009e4003bca80
  di: 0000000000000002  si: 00007ffd506a4ad0  bp: 00007ffd506a4d20  bx: 00007f96d97a4e00
  dx: 0000000000000000  ax: 0000000000000000  cx: 00007f96da98403b  sp: 00007ffd506a4ad0
  ip: 00007f96da98403b efl: 0000000000000246 cgf: 0000000000000033 erf: 0000000000000000
 trp: 0000000000000000 msk: 0000000000000000 cr2: 0000000000000000
[end of stack trace]


TROUBLESHOOTING: https://github.com/puppeteer/puppeteer/blob/main/docs/troubleshooting.md
Failed to launch the browser process!
[0405/082259.515193:ERROR:bus.cc(397)] Failed to connect to the bus: Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
[0405/082259.515285:ERROR:bus.cc(397)] Failed to connect to the bus: Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
[0405/082259.516995:ERROR:platform_thread_posix.cc(151)] pthread_create: Resource temporarily unavailable (11)
Received signal 6
#0 0x55ad9ecd1469 base::debug::CollectStackTrace()
#1 0x55ad9ec37f33 base::debug::StackTrace::StackTrace()
#2 0x55ad9ecd0f71 base::debug::(anonymous namespace)::StackDumpSignalHandler()
#3 0x7fead73c93c0 (/usr/lib/x86_64-linux-gnu/libpthread-2.31.so+0x143bf)
#4 0x7fead651303b gsignal
#5 0x7fead64f2859 abort
#6 0x7feac562cc68 <unknown>
#7 0x7feac562c95b <unknown>
#8 0x7feac562c8d5 <unknown>
#9 0x7feac562c342 <unknown>
#10 0x7feac54a3038 <unknown>
#11 0x7feac54a2dd0 <unknown>
#12 0x7feac54a2d59 <unknown>
#13 0x7feac549d63f <unknown>
#14 0x7feac549dad5 <unknown>
#15 0x7feac5492ab1 <unknown>
#16 0x7feac5842e13 <unknown>
#17 0x7feac58408ea <unknown>
#18 0x7feac583fdb0 <unknown>
#19 0x7feac584932e <unknown>
#20 0x7feac6d06083 <unknown>
#21 0x7feac6d034a3 <unknown>
#22 0x7feac6ce794d <unknown>
#23 0x7feac6d7cba8 <unknown>
#24 0x7feac6b4b030 <unknown>
#25 0x7feac6ad9dbf <unknown>
#26 0x7feac6adc0a1 <unknown>
#27 0x7feac589bbc2 <unknown>
#28 0x55ad9ff25b02 gl::GLSurfaceEGL::InitializeDisplay()
#29 0x55ad9ff25053 gl::GLSurfaceEGL::InitializeOneOff()
#30 0x55ad9bdbb40c ui::GLOzoneEGL::InitializeGLOneOffPlatform()
#31 0x55ad9ffbb178 gl::init::InitializeGLOneOffPlatformImplementation()
#32 0x55ad9ffbaf03 gl::init::(anonymous namespace)::InitializeGLOneOffPlatformHelper()
#33 0x55ad9ffbaffc gl::init::InitializeGLNoExtensionsOneOff()
#34 0x55ada08b344c gpu::GpuInit::InitializeInProcess()
#35 0x55ada21f1e1a content::InProcessGpuThread::Init()
#36 0x55ad9ecbc304 base::Thread::ThreadMain()
#37 0x55ad9ece211e base::(anonymous namespace)::ThreadFunc()
#38 0x7fead73bd609 start_thread
#39 0x7fead65ef163 clone
  r8: 0000000000000000  r9: 00007feac8f22fb0 r10: 0000000000000008 r11: 0000000000000246
 r12: 00003cca0060cd40 r13: 00003cca00264580 r14: 00007feac562c2c0 r15: 00007feac5793e30
  di: 0000000000000002  si: 00007feac8f22fb0  bp: 00007feac8f23210  bx: 00007feac8f27700
  dx: 0000000000000000  ax: 0000000000000000  cx: 00007fead651303b  sp: 00007feac8f22fb0
  ip: 00007fead651303b efl: 0000000000000246 cgf: 0000000000000033 erf: 0000000000000000
 trp: 0000000000000000 msk: 0000000000000000 cr2: 0000000000000000
[end of stack trace]


TROUBLESHOOTING: https://github.com/puppeteer/puppeteer/blob/main/docs/troubleshooting.md

Restarting the dynos seems to solve this for a while, but then it happens again.

Any ideas what might be causing this?

Thanks in advance

Puppeteer version

^13.5.1

Node.js version

16.13.0

npm version

8.1.0

What operating system are you seeing the problem on?

Linux

@meirtb meirtb added the bug label Apr 5, 2022
@bryanfaundez
Copy link

Hi, I have the same error.

2022-05-25T17:17:57.220146261Z Error: Failed to launch the browser process!
2022-05-25T17:17:57.220146261Z [0525/171757.201974:ERROR:platform_thread_posix.cc(151)] pthread_create: Resource temporarily unavailable (11)
2022-05-25T17:17:57.220146261Z [0525/171757.202121:FATAL:browser_task_executor.cc(399)] Failed to start BrowserThread:IO
2022-05-25T17:17:57.220146261Z 
2022-05-25T17:17:57.220146261Z 
2022-05-25T17:17:57.220146261Z TROUBLESHOOTING: https://github.com/puppeteer/puppeteer/blob/master/docs/troubleshooting.md
2022-05-25T17:17:57.220146261Z 
2022-05-25T17:17:57.220146261Z     at onClose (/app/node_modules/puppeteer/lib/Launcher.js:750:14)
2022-05-25T17:17:57.220146261Z     at ChildProcess.<anonymous> (/app/node_modules/puppeteer/lib/Launcher.js:740:61)
2022-05-25T17:17:57.220146261Z     at ChildProcess.emit (events.js:326:22)
2022-05-25T17:17:57.220146261Z     at Process.ChildProcess._handle.onexit (internal/child_process.js:276:12)

The documentation does not explain the error control or socket reset.

@stale
Copy link

stale bot commented Jul 25, 2022

We're marking this issue as unconfirmed because it has not had recent activity and we weren't able to confirm it yet. It will be closed if no further activity occurs within the next 30 days.

@stale stale bot added the unconfirmed label Jul 25, 2022
@wifiuk
Copy link

wifiuk commented Aug 17, 2022

same when using n8n docker and this as a community node:

`Error: Failed to launch the browser process! spawn /home/node/.n8n/nodes/node_modules/puppeteer/.local-chromium/linux-1002410/chrome-linux/chrome ENOENT

TROUBLESHOOTING: https://github.com/puppeteer/puppeteer/blob/main/docs/troubleshooting.md

at onClose (/home/node/.n8n/nodes/node_modules/puppeteer/lib/cjs/puppeteer/node/BrowserRunner.js:286:20)
at ChildProcess.<anonymous> (/home/node/.n8n/nodes/node_modules/puppeteer/lib/cjs/puppeteer/node/BrowserRunner.js:280:24)
at ChildProcess.emit (node:events:527:28)
at Process.ChildProcess._handle.onexit (node:internal/child_process:289:12)
at onErrorNT (node:internal/child_process:478:16)
at processTicksAndRejections (node:internal/process/task_queues:83:21)`

@stale
Copy link

stale bot commented Sep 16, 2022

We are closing this issue. If the issue still persists in the latest version of Puppeteer, please reopen the issue and update the description. We will try our best to accomodate it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants