]> git.sven.stormbind.net Git - sven/jattach.git/blobdiff - README.md
New upstream version 2.2
[sven/jattach.git] / README.md
index 7532b569201ea6f2f1c8ad95d909f73f06f6a4ce..958420452d3341ae33bb7f1d58cddeeb8edbde79 100644 (file)
--- a/README.md
+++ b/README.md
@@ -2,7 +2,7 @@
 
 ### JVM Dynamic Attach utility
 
-The utility to send commands to remote JVM via Dynamic Attach mechanism.
+The utility to send commands to a JVM process via Dynamic Attach mechanism.
 
 All-in-one **jmap + jstack + jcmd + jinfo** functionality in a single tiny program.  
 No installed JDK required, works with just JRE. Supports Linux containers.
@@ -22,8 +22,14 @@ https://docs.oracle.com/javase/8/docs/jdk/api/attach/spec/
  - **printflag**       : print VM flag
  - **jcmd**            : execute jcmd command
 
+### Download
+
+Binaries are available on the [Releases](https://github.com/jattach/jattach/releases) page.
+
+On some platforms, you can also [install](#installation) jattach with a package manager.
+
 ### Examples
-#### Load JVMTI agent
+#### Load native agent
 
     $ jattach <pid> load <.so-path> { true | false } [ options ]
 
@@ -31,25 +37,39 @@ Where `true` means that the path is absolute, `false` -- the path is relative.
 
 `options` are passed to the agent.
 
+#### Load Java agent
+
+Java agents are loaded by the special built-in native agent named `instrument`,
+which takes .jar path and its arguments as a single options string.
+
+    $ jattach <pid> load instrument false "javaagent.jar=arguments"
+
 #### List available jcmd commands 
 
-    $ jattach <pid> jcmd "help -all"
+    $ jattach <pid> jcmd help -all
 
 ### Installation
-#### FreeBSD
+#### Debian, Ubuntu
 
-On FreeBSD, you can use the following command to install `jattach` package:
+On Debian and Ubuntu, you can install `jattach` from the official repository:
 
-    $ pkg install jattach
+    # apt install jattach
 
 #### Alpine Linux
 
-On Alpine Linux, you can use the following command to install `jattach` package from the edge/testing repository:
+On Alpine Linux, you can install `jattach` package from the edge/community repository:
 
-    $ apk add --no-cache jattach --repository http://dl-cdn.alpinelinux.org/alpine/edge/testing/
+    # apk add --no-cache jattach --repository http://dl-cdn.alpinelinux.org/alpine/edge/community/
 
 #### Archlinux
 
 [jattach](https://aur.archlinux.org/packages/jattach/) package can be installed from [AUR](https://wiki.archlinux.org/index.php/Arch_User_Repository) using one of [AUR helpers](https://wiki.archlinux.org/index.php/AUR_helpers), e.g., `yay`:
 
-    $ yay -S jattach
+    # yay -S jattach
+
+#### FreeBSD
+
+On FreeBSD, you can use the following command to install `jattach`:
+
+    # pkg install jattach
+