Last active
August 25, 2020 08:57
-
-
Save balcsida/dddb41acdaaecf482a2782418416420d to your computer and use it in GitHub Desktop.
Obtain heapdump through a shell where jmap is not available
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
shopt -s dotglob | |
curl -LO https://github.com/apangin/jattach/releases/download/v1.5/jattach | |
echo 'adab16e1081aa4fafc91f3f2e44262338a498d8f853d3c6801050889e6389548 jattach' | sha256sum --check --status | |
chmod +x jattach | |
./jattach $(pidof java) dumpheap /opt/liferay/data/LiferaySupport/$(hostname)/$(date +%Y_%m_%d-%H_%M).hprof |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment