【发布时间】:2023-03-03 21:47:01
【问题描述】:
我有一个java进程,它的classpath包含很多jar,所以启动命令很长。
假设进程id是110101,当我通过命令cat /proc/110101/cmdline查看命令时,我发现命令不完整,它只包含大约4000个字符。
还有其他方法可以显示原来的启动命令吗?
【问题讨论】:
我有一个java进程,它的classpath包含很多jar,所以启动命令很长。
假设进程id是110101,当我通过命令cat /proc/110101/cmdline查看命令时,我发现命令不完整,它只包含大约4000个字符。
还有其他方法可以显示原来的启动命令吗?
【问题讨论】:
man proc
/proc/[pid]/cmdline
This holds the complete command line for the process, unless
the process is a zombie. In the latter case, there is nothing
in this file: that is, a read on this file will return 0
characters. The command-line arguments appear in this file as
a set of strings separated by null bytes ('\0'), with a
further null byte after the last string.
它可能不会通过 cat 文件为您提供所有参数。
【讨论】: