Skip to main content

Posts

Showing posts from May, 2014

SSH Public Key Based Authentication

1-        Generate public and private keys by using  puttygen . Save public and private keys with or without passphrase. 2-        Public key which is seen as selected in picture, needs to be added to authorized_keys file in GIT server. While copying make sure that: -            Key starts with “ssh-rsa” -            Key does not include “ rsa-key-20140505” -            Key must be single line. 3-        In GIT server, generated key needs to be added to   ~/.ssh/authorized_keys  file. Make sure public key is copied according to remarks above. A sample public key is as below: ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAQEAi6ZlUMEIwB4UAhE8WQL0BFzDK/4dnQzSHhhIGgqmrunLd4IkK1lGDF3YpqMOz5VLFggfJZPx+VgGkqliOvHdHn4GVsqOQZOiIku3ZuipvWIR4ZC6IBO31N/2nZaeRYXWPVdT9WzcT8mWi6Xh+0ULZdf++b8CqyFa4uuziqw7qb15dIczhDfsZfxpJovYwb/HDKFKznFtehrLG1Xc3VlfUzq2SO89+7vWFjLBaSPG5y7Fcx20SreJiF4ESV0wBdAh7N6ab1vYpK++ab1sNxD5rrdbgqsoUT7yFcGroBPmFuIfqKyP6QWwNYFjH2urhmG5efiLTbRWOQEXsL1nt9PMPQ==

Remote Monitoring of Java Process Using Jvisual VM

A-    Using Jstatd Jstatd deamon is a process which comes with JDK. It can be used to remotely monitor jvm processes. It is possible to monitor any jvm processes without need to commanline parameters. However, it is limited when compared to JMX connection. 1-        Create a  jstatd.all.policy  file in statd directory. cd /usr/jdk/bin touch jstatd.all.policy vi jstatd.all.policy Add following lines to  jstatd.all.policy : grant codebase "file:${java.home}/../lib/tools.jar" {    permission java.security.AllPermission; }; 2-        Run jstatd daemon. ./jstatd -J-Djava.security.policy=jstatd.all.policy 3-        In client machine, open Jvisualvm and goto  Applications->Remote->Add Remote Host  and enter ip address of remote machine hosting java process. 4-        Right click newly added remote node and click “ Add Jstatd connection... ” . 5-         Available process will be listed under newly created remote no