概述
查看 Java 进程日志
sudo dmesg -T | grep "(java)"
[root@VM-0-5-centos jar]# sudo dmesg -T | grep "(java)"
[Fri May
6 19:31:49 2022] Out of memory: Kill process 5175 (java) score 223 or sacrifice child
[Fri May
6 19:31:49 2022] Killed process 5175 (java), UID 0, total-vm:3647080kB, anon-rss:892680kB, file-rss:0kB, shmem-rss:0kB
[Sat May
7 10:39:18 2022] Out of memory: Kill process 22349 (java) score 241 or sacrifice child
[Sat May
7 10:39:18 2022] Killed process 22349 (java), UID 0, total-vm:3909556kB, anon-rss:963280kB, file-rss:0kB, shmem-rss:0kB
[Sat May
7 10:39:18 2022] Out of memory: Kill process 14309 (java) score 221 or sacrifice child
[Sat May
7 10:39:18 2022] Killed process 14309 (java), UID 0, total-vm:3700392kB, anon-rss:882980kB, file-rss:0kB, shmem-rss:0kB
没内存,杀掉了 Java 进程,该充钱升级了
或者查看系统日志文件也可以
tail -n 100 /var/log/messages
[root@VM-0-5-centos ~]# tail -n 100 /var/log/messages
May
7 10:39:20 VM-0-5-centos kernel: Out of memory: Kill process 14309 (java) score 221 or sacrifice child
May
7 10:39:20 VM-0-5-centos kernel: Killed process 14309 (java), UID 0, total-vm:3700392kB, anon-rss:882980kB, file-rss:0kB, shmem-rss:0kB
May
7 10:39:20 VM-0-5-centos systemd-logind: Removed session 536815.
May
7 10:39:20 VM-0-5-centos systemd-logind: Removed session 226291.
May
7 10:40:01 VM-0-5-centos systemd: Started Session 538133 of user root.
May
7 10:40:01 VM-0-5-centos systemd: Started Session 538135 of user root.
最后
以上就是单薄冬日为你收集整理的Java项目突然挂掉的全部内容,希望文章能够帮你解决Java项目突然挂掉所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复