EC2实例在./gradlew汇编之后无法到达

发布于 2025-01-23 19:45:03 字数 463 浏览 2 评论 0原文

问题 : 我在EC2实例(Ubuntu)中有一个React应用程序。我正在尝试执行此命令,但是它在尝试执行“ NPM run build”

./gradlew :webapp:assemble

故障过程时被卡住了: 当我这样做时,一些过程会成功进行,直到调用npm run构建。在该终端冻结之后,并且在我收到SSH连接超时错误之前不会提供任何错误消息。当我尝试重新连接使用SSH实例时,实例不会以任何方式响应。

我检查/尝试了什么: 我尝试在自己的PC中使用同一应用程序进行相同的操作,但没有任何问题。我还尝试在不使用gradle的情况下在EC2中运行npm Run Build,而且它的工作正常,因此我认为我的React应用程序没有任何问题。

我如何对此进行故障排除并了解​​导致实例陷入不可到达状态的原因?例如,有没有办法了解这是否是由CPU使用过高引起的?

The problem :
I have a react application in my ec2 instance(ubuntu). I'm trying to execute this command but it gets stuck while trying to execute "npm run build"

./gradlew :webapp:assemble

Faulty Process :
When I do this, some process goes on succesfully, until it calls npm run build. After that terminal freezes as it is and does not give any error messages until I get an ssh connection time out error. When I try to reconnect to instance with ssh, instance doesn't respond in any way.

What I checked/tried :
I've tried to do same operation with same application in my own pc and there isn't any problem. I also tried to run npm run build in ec2 without using gradle and its also working fine so I don't think there is any problem about my react application.

How can I troubleshoot this and learn what's causing instance to stuck in a not reachable state ? For example, is there a way to learn if this is caused by too high CPU usage ?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

生生漫 2025-01-30 19:45:03

多亏了@Riz的评论,我意识到RAM不足引起的问题。我通过切换到另一台机器,用更多的RAM解决了它

Thanks to @Riz 's comment I realized that there is a problem caused by insufficient ram. I Solved it by switching to another machine with more RAM

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文