- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
const puppeteer = require('puppeteer-extra');
(async () => {
const eventPage = `https://www.bug.hr/`;
const browser = await puppeteer.launch({
headless: true,
dumpio: true
});
const page = await browser.newPage();
await page.goto(eventPage, {
waitUntil: 'domcontentloaded'
});
console.log("TITLE: ", await page.evaluate(() => document.title));
await browser.close();
})();
那应该启动 Puppeteer(在我重新启动服务器后它会启动),相反,我得到了这个:
ubuntu@ip-123-45-67-89:/var/www/tests$ env DEBUG="puppeteer:*" node bug.hr/homepage.js
puppeteer:launcher Calling /usr/bin/chromium-browser --disable-background-networking --enable-features=NetworkService,NetworkServiceInProcess --disable-background-timer-throttling --disable-backgrounding-occluded-windows --disable-breakpad --disable-client-side-phishing-detection --disable-component-extensions-with-background-pages --disable-default-apps --disable-dev-shm-usage --disable-extensions --disable-features=Translate --disable-hang-monitor --disable-ipc-flooding-protection --disable-popup-blocking --disable-prompt-on-repost --disable-renderer-backgrounding --disable-sync --force-color-profile=srgb --metrics-recording-only --no-first-run --enable-automation --password-store=basic --use-mock-keychain --enable-blink-features=IdleDetection --headless --hide-scrollbars --mute-audio about:blank --remote-debugging-port=0 --user-data-dir=/tmp/puppeteer_dev_chrome_profile-fvYjAc +0ms
DevTools listening on ws://127.0.0.1:42943/devtools/browser/5a94e4ce-f053-4e83-afdb-f44731fc185e
[1109/015336.602361:ERROR:devtools_http_handler.cc(292)] Error writing DevTools active port to file
[1109/015336.608627:ERROR:gpu_init.cc(453)] Passthrough is not supported, GL is swiftshader, ANGLE is
[1109/015336.612599:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015336.613361:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015336.613265:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
puppeteer:protocol:SEND ► {"method":"Target.setDiscoverTargets","params":{"discover":true},"id":1} +0ms
puppeteer:protocol:RECV ◀ {"method":"Target.targetCreated","params":{"targetInfo":{"targetId":"17591FCF231B151133561BADC2D1A20C","type":"page","title":"","url":"about:blank","attached":false,"canAccessOpener":false,"browserContextId":"3F175AC4C3C999720E0FFEFA74971974"}}} +0ms
puppeteer:protocol:RECV ◀ {"method":"Target.targetCreated","params":{"targetInfo":{"targetId":"3066064f-b08d-429f-af6c-99c828566f63","type":"browser","title":"","url":"","attached":false,"canAccessOpener":false}}} +1ms
puppeteer:protocol:RECV ◀ {"method":"Target.targetCreated","params":{"targetInfo":{"targetId":"7b188175-60bc-4608-b6a2-a83ed34381b0","type":"browser","title":"","url":"","attached":true,"canAccessOpener":false}}} +0ms
puppeteer:protocol:RECV ◀ {"id":1,"result":{}} +0ms
puppeteer:protocol:SEND ► {"method":"Target.createTarget","params":{"url":"about:blank"},"id":2} +4ms
puppeteer:protocol:RECV ◀ {"method":"Target.targetCreated","params":{"targetInfo":{"targetId":"BD017C91F9A3803C4D1204C1F648B61E","type":"page","title":"","url":"","attached":false,"canAccessOpener":false,"browserContextId":"3F175AC4C3C999720E0FFEFA74971974"}}} +4ms
puppeteer:protocol:RECV ◀ {"id":2,"result":{"targetId":"BD017C91F9A3803C4D1204C1F648B61E"}} +0ms
[1109/015336.626616:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
puppeteer:protocol:RECV ◀ {"method":"Target.targetCrashed","params":{"targetId":"17591FCF231B151133561BADC2D1A20C","status":"crashed","errorCode":133}} +187ms
[1109/015336.827392:ERROR:gpu_process_host.cc(979)] GPU process exited unexpectedly: exit_code=133
[1109/015336.827421:WARNING:gpu_process_host.cc(1292)] The GPU process has crashed 1 time(s)
[1109/015336.834997:ERROR:gpu_init.cc(453)] Passthrough is not supported, GL is swiftshader, ANGLE is
[1109/015336.838813:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015336.839148:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
puppeteer:protocol:RECV ◀ {"method":"Target.targetCrashed","params":{"targetId":"BD017C91F9A3803C4D1204C1F648B61E","status":"crashed","errorCode":133}} +49ms
[1109/015337.039942:ERROR:gpu_process_host.cc(979)] GPU process exited unexpectedly: exit_code=133
[1109/015337.039973:WARNING:gpu_process_host.cc(1292)] The GPU process has crashed 2 time(s)
[1109/015337.047216:ERROR:gpu_init.cc(453)] Passthrough is not supported, GL is swiftshader, ANGLE is
[1109/015337.051080:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015337.051332:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015337.248703:ERROR:gpu_process_host.cc(979)] GPU process exited unexpectedly: exit_code=133
[1109/015337.248732:WARNING:gpu_process_host.cc(1292)] The GPU process has crashed 3 time(s)
[1109/015337.255892:ERROR:gpu_init.cc(453)] Passthrough is not supported, GL is swiftshader, ANGLE is
[1109/015337.259819:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015337.260091:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015337.454161:ERROR:gpu_process_host.cc(979)] GPU process exited unexpectedly: exit_code=133
[1109/015337.454191:WARNING:gpu_process_host.cc(1292)] The GPU process has crashed 4 time(s)
[1109/015337.461741:ERROR:gpu_init.cc(453)] Passthrough is not supported, GL is swiftshader, ANGLE is
[1109/015337.465935:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015337.466181:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015337.666248:ERROR:gpu_process_host.cc(979)] GPU process exited unexpectedly: exit_code=133
[1109/015337.666276:WARNING:gpu_process_host.cc(1292)] The GPU process has crashed 5 time(s)
[1109/015337.673524:ERROR:gpu_init.cc(453)] Passthrough is not supported, GL is swiftshader, ANGLE is
[1109/015337.677539:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015337.677807:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015337.880581:ERROR:gpu_process_host.cc(979)] GPU process exited unexpectedly: exit_code=133
[1109/015337.880610:WARNING:gpu_process_host.cc(1292)] The GPU process has crashed 6 time(s)
[1109/015337.882645:ERROR:gpu_init.cc(453)] Passthrough is not supported, GL is disabled, ANGLE is
[1109/015337.884399:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015337.884679:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015338.076122:ERROR:gpu_process_host.cc(979)] GPU process exited unexpectedly: exit_code=133
[1109/015338.076151:WARNING:gpu_process_host.cc(1292)] The GPU process has crashed 7 time(s)
[1109/015338.078253:ERROR:gpu_init.cc(453)] Passthrough is not supported, GL is disabled, ANGLE is
[1109/015338.079942:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015338.080236:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015338.268891:ERROR:gpu_process_host.cc(979)] GPU process exited unexpectedly: exit_code=133
[1109/015338.268920:WARNING:gpu_process_host.cc(1292)] The GPU process has crashed 8 time(s)
[1109/015338.271026:ERROR:gpu_init.cc(453)] Passthrough is not supported, GL is disabled, ANGLE is
[1109/015338.272679:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015338.272975:FATAL:sandbox_bpf.cc(283)] Kernel refuses to turn on BPF filters
[1109/015338.461377:ERROR:gpu_process_host.cc(979)] GPU process exited unexpectedly: exit_code=133
[1109/015338.461406:WARNING:gpu_process_host.cc(1292)] The GPU process has crashed 9 time(s)
[1109/015338.461419:FATAL:gpu_data_manager_impl_private.cc(417)] GPU process isn't usable. Goodbye.
我不能随意复制它。这发生在服务器运行一周或两周之后。
Kernel refuses to turn on BPF filters
,从日志中。
--disable-seccomp-filter-sandbox
来修复Chrome 的参数,它引入了安全问题,因为它禁用了 Chrome 沙箱的第 2 层 (
https://chromium.googlesource.com/chromium/src/+/HEAD/docs/linux/sandboxing.md#the-sandbox-1)
/usr/bin/chromium-browser --product-version
给出 95.0.4638.69
apt update && apt upgrade
时也会发生这种情况:
/usr/bin/mandb: can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter: Unknown error 524/usr/bin/mandb:
can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter: Unknown error 524
/usr/bin/mandb: can't load seccomp filter/usr/bin/mandb: can't load seccomp filter: Unknown error 524: Unknown error 524
这在 Ubuntu-amd64(现在是 Arm)上没有发生。
最佳答案
尝试添加 {args: ['--no-sandbox']}
await puppeteer.launch()
中的标志因为它似乎是一个沙盒问题,给出了错误 FATAL:sandbox_bpf.cc(283)
关于node.js - 几天后,我无法再启动 Puppeteer,直到我重新启动服务器,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/69892137/
我通过 spring ioc 编写了一些 Rest 应用程序。但我无法解决这个问题。这是我的异常(exception): org.springframework.beans.factory.BeanC
我对 TestNG、Spring 框架等完全陌生,我正在尝试使用注释 @Value通过 @Configuration 访问配置文件注释。 我在这里想要实现的目标是让控制台从配置文件中写出“hi”,通过
为此工作了几个小时。我完全被难住了。 这是 CS113 的实验室。 如果用户在程序(二进制计算器)结束时选择继续,我们需要使用 goto 语句来到达程序的顶部。 但是,我们还需要释放所有分配的内存。
我正在尝试使用 ffmpeg 库构建一个小的 C 程序。但是我什至无法使用 avformat_open_input() 打开音频文件设置检查错误代码的函数后,我得到以下输出: Error code:
使用 Spring Initializer 创建一个简单的 Spring boot。我只在可用选项下选择 DevTools。 创建项目后,无需对其进行任何更改,即可正常运行程序。 现在,当我尝试在项目
所以我只是在 Mac OS X 中通过 brew 安装了 qt。但是它无法链接它。当我尝试运行 brew link qt 或 brew link --overwrite qt 我得到以下信息: ton
我在提交和 pull 时遇到了问题:在提交的 IDE 中,我看到: warning not all local changes may be shown due to an error: unable
我跑 man gcc | grep "-L" 我明白了 Usage: grep [OPTION]... PATTERN [FILE]... Try `grep --help' for more inf
我有一段代码,旨在接收任何 URL 并将其从网络上撕下来。到目前为止,它运行良好,直到有人给了它这个 URL: http://www.aspensurgical.com/static/images/a
在过去的 5 个小时里,我一直在尝试在我的服务器上设置 WireGuard,但在完成所有设置后,我无法 ping IP 或解析域。 下面是服务器配置 [Interface] Address = 10.
我正在尝试在 GitLab 中 fork 我的一个私有(private)项目,但是当我按下 fork 按钮时,我会收到以下信息: No available namespaces to fork the
我这里遇到了一些问题。我是 node.js 和 Rest API 的新手,但我正在尝试自学。我制作了 REST API,使用 MongoDB 与我的数据库进行通信,我使用 Postman 来测试我的路
下面的代码在控制台中给出以下消息: Uncaught DOMException: Failed to execute 'appendChild' on 'Node': The new child el
我正在尝试调用一个新端点来显示数据,我意识到在上一组有效的数据中,它在数据周围用一对额外的“[]”括号进行控制台,我认为这就是问题是,而新端点不会以我使用数据的方式产生它! 这是 NgFor 失败的原
我正在尝试将我的 Symfony2 应用程序部署到我的 Azure Web 应用程序,但遇到了一些麻烦。 推送到远程时,我在终端中收到以下消息 remote: Updating branch 'mas
Minikube已启动并正在运行,没有任何错误,但是我无法 curl IP。我在这里遵循:https://docs.traefik.io/user-guide/kubernetes/,似乎没有提到关闭
每当我尝试docker组成任何项目时,都会出现以下错误。 我尝试过有和没有sudo 我在这台机器上只有这个问题。我可以在Mac和Amazon WorkSpace上运行相同的容器。 (myslabs)
我正在尝试 pip install stanza 并收到此消息: ERROR: No matching distribution found for torch>=1.3.0 (from stanza
DNS 解析看起来不错,但我无法 ping 我的服务。可能是什么原因? 来自集群中的另一个 Pod: $ ping backend PING backend.default.svc.cluster.l
我正在使用Hibernate 4 + Spring MVC 4当我开始 Apache Tomcat Server 8我收到此错误: Error creating bean with name 'wel
我是一名优秀的程序员,十分优秀!