通过 ssh 和 sudo 连接到远程 RHEL VM
Connect to a remote RHEL VM via ssh and sudo
我已经在本地 Windows 7 和远程 RHEL 7 VM 上安装了 JProfiler 10.0.1。
由于格式问题,此处提供与第 3 点有关的输出:
bash-4.2$ hostname
l4513t.sss.se.com
bash-4.2$ ./jpenable
Select a JVM:
org.apache.nifi.bootstrap.RunNiFi start [29714] [1]
org.apache.nifi.NiFi [29731] [2]
2
Please select the profiling mode:
GUI mode (attach with JProfiler GUI) [1, Enter]
Offline mode (use config file to set profiling settings) [2]
1
Please enter a profiling port
[45180]
45180
You can now use the JProfiler GUI to connect on port 45180
bash-4.2$
一些事实:
- 我希望与用户 运行 一起监控的远程 RHEL JVM 'nifi'
- 由于我是 'sudoer',我使用自己的用户名 'ojoqcu' 通过 SSH(通过 Putty)连接到远程 VM,然后使用 'sudo su - , su nifi ”或简单的“sudo su nifi”。然后,我成为'nifi'用户而不提供密码
- 根据 jprofiler documentation,我以 'nifi' 用户 的身份执行了 'jpenable' 文件,以下是输出
当我尝试使用 JProfiler 向导从我的本地计算机连接到 'Remote Application' 时,出现连接错误。请注意,手动提供端口 45180 没有帮助,因为用户 运行正在使用 jprofiler。
Note that manually providing the port 45180 didn't help as the user running the jprofiler is nifi.
如果您已经 运行 jpenable,这就是您应该做的。您可以使用 "Manually specify profiling port" 而不是 "Discover running JVMs"。在那种情况下,除了在设置与远程计算机的 SSH 连接的上下文中之外,不会有关于用户的问题。
我已经在本地 Windows 7 和远程 RHEL 7 VM 上安装了 JProfiler 10.0.1。
由于格式问题,此处提供与第 3 点有关的输出:
bash-4.2$ hostname
l4513t.sss.se.com
bash-4.2$ ./jpenable
Select a JVM:
org.apache.nifi.bootstrap.RunNiFi start [29714] [1]
org.apache.nifi.NiFi [29731] [2]
2
Please select the profiling mode:
GUI mode (attach with JProfiler GUI) [1, Enter]
Offline mode (use config file to set profiling settings) [2]
1
Please enter a profiling port
[45180]
45180
You can now use the JProfiler GUI to connect on port 45180
bash-4.2$
一些事实:
- 我希望与用户 运行 一起监控的远程 RHEL JVM 'nifi'
- 由于我是 'sudoer',我使用自己的用户名 'ojoqcu' 通过 SSH(通过 Putty)连接到远程 VM,然后使用 'sudo su - , su nifi ”或简单的“sudo su nifi”。然后,我成为'nifi'用户而不提供密码
- 根据 jprofiler documentation,我以 'nifi' 用户 的身份执行了 'jpenable' 文件,以下是输出
当我尝试使用 JProfiler 向导从我的本地计算机连接到 'Remote Application' 时,出现连接错误。请注意,手动提供端口 45180 没有帮助,因为用户 运行正在使用 jprofiler。
Note that manually providing the port 45180 didn't help as the user running the jprofiler is nifi.
如果您已经 运行 jpenable,这就是您应该做的。您可以使用 "Manually specify profiling port" 而不是 "Discover running JVMs"。在那种情况下,除了在设置与远程计算机的 SSH 连接的上下文中之外,不会有关于用户的问题。