imbajin commented on code in PR #509:
URL: https://github.com/apache/hugegraph-doc/pull/509#discussion_r4239824176


##########
content/en/docs/quickstart/hugegraph/hugegraph-server.md:
##########
@@ -535,6 +535,27 @@ This indicates the successful creation of the sample graph.
 
 `bin/stop-hugegraph.sh` accepts `-m true|false` (default `true`), which 
controls whether the cron monitor task is removed along with the service.
 
+`bin/hugegraph-server.sh` puts `-XX:+HeapDumpOnOutOfMemoryError`, 
`-XX:HeapDumpPath` and `-XX:ErrorFile` first in `JAVA_TOOL_OPTIONS`, so whether 
or not
+`JAVA_OPTIONS` is set, an out-of-memory heap dump (`heapdump_<host>_<launch 
time>/java_pid<pid>.hprof`) and a JVM crash log
+(`hs_err_pid<pid>_<host>_<launch time>.log`) land in `logs/`, where `<launch 
time>` is the local time as `YYYYMMDD-HHMMSS`. Each start gets its own 
`heapdump_*`
+directory, so the server and the JVMs it starts, such as computer jobs, write 
separate dumps (HotSpot names each dump and crash log after the JVM's PID, so a
+JVM that reuses an earlier PID from the same start cannot write its dump, and 
its crash log replaces the earlier one's). The host name keeps servers that 
share
+one log directory from picking the same name, and a counter (`<launch 
time>-1`, `-2`, ...) is added when the same host already used that second. If 
the
+directory cannot be created, for example on a full disk, the server still 
starts and dumps go to `logs/` itself, as a best effort: a full disk may have 
no room
+for the dump either. A heap dump can be as large as the heap. The launcher 
never deletes dumps or `heapdump_*` directories: each start leaves one, empty 
unless

Review Comment:
   🧹 Minor. Blocking: no. Summary: This says every start leaves a `heapdump_*` 
directory, but a launch that fails before Java starts leaves none. Please 
qualify this to launches that pass preflight, and sync the Chinese quickstart 
and both Docker-guide statements. Evidence: [the paired launcher creates the 
directory after its preflight checks and states earlier failures leave 
nothing](https://github.com/apache/hugegraph/blob/d3db8e73691bc864cdee6124e779140ecaf259cd/hugegraph-server/hugegraph-dist/src/assembly/static/bin/hugegraph-server.sh#L290-L291).



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to