LibraryToggle FramesPrintFeedback

Connecting to a Standalone Container from a Remote Container

Overview

Any container's command console can be used to access a remote container. Using SSH, the local container's console connects to the remote container and functions as a command console for the remote container.

Using the ssh:ssh console command

You connect to a remote container's console using the ssh:ssh console command.

Example 6. ssh:ssh Command Syntax

ssh:ssh {-l username} {-P password} {-p port} { hostname }


-l username

The username used to connect to the remote container. Use valid JAAS login credentials that have admin privileges (see Configuring JAAS Security).

-P password

The password used to connect to the remote container.

-p port

The SSH port used to access the desired container's remote console.

By default this value is 8101. See Configuring a standalone container for remote access for details on changing the port number.

hostname

The hostname of the machine that the remote container is running on. See Configuring a standalone container for remote access for details on changing the hostname.

[Warning]Warning

We recommend that you customize the username and password in the etc/users.properties file. See Configuring JAAS Securityfor details.

Example 7. Connecting to a Remote Console

karaf@root>ssh:ssh -l smx -P smx -p 8108 hostname

To confirm that you have connected to the correct container, type shell:info at the prompt. Information about the currently connected instance is returned, as shown in Example 8.

Example 8. Output of the shell:info Command

Karaf
  Karaf version               2.2.5.fuse-beta-7-052
  Karaf home                  /Volumes/ESB/fuse-esb-7.1.0.fuse-047
  Karaf base                  /Volumes/ESB/fuse-esb-7.1.0.fuse-047
  OSGi Framework              org.apache.felix.framework - 4.0.3.fuse-beta-7-052

JVM
  Java Virtual Machine        Java HotSpot(TM) 64-Bit Server VM version 20.6-b01-415
  Version                     1.6.0_31
  Vendor                      Apple Inc.
  Uptime                      6 minutes
  Total compile time          24.048 seconds
Threads
  Live threads                62
  Daemon threads              43
  Peak                        287
  Total started               313
Memory
  Current heap size           78,981 kbytes
  Maximum heap size           466,048 kbytes
  Committed heap size         241,920 kbytes
  Pending objects             0
  Garbage collector           Name = 'PS Scavenge', Collections = 11, Time = 0.271 seconds
  Garbage collector           Name = 'PS MarkSweep', Collections = 1, Time = 0.117 seconds
Classes
  Current classes loaded      5,720
  Total classes loaded        5,720
  Total classes unloaded      0
Operating system
  Name                        Mac OS X version 10.7.3
  Architecture                x86_64
  Processors                  2

Disconnecting from a remote console

To disconnect from a remote console, enter logout or press Ctrl+D at the prompt.

You will be disconnected from the remote container and the console will once again manage the local container.

Comments powered by Disqus