SSH-Telnet-MP Stitching Guide

From GEANT2-JRA1 Wiki

Contents

Stitching for perfSONAR Bundle 2.1, 2.2

Objectives

  • To create a service.properties file for your SSH Telnet MP Installation which will configure the list of devices avaiable for querying as well as the list of commands permitted

Requirements before using this guide

  1. List of devices that you want to allow your SSH Telnet MP installation to contact
    1. This list can either be (alias,device DNS/URL). The alias could be device DNS/URL itself. Example: (paris,rt1.par.fr.geant2.net) or (rt1.par.fr.geant2.net,rt1.par.fr.geant2.net)
  2. For each device you also need to know:
    1. The type of equipment (manufacturer) - Juniper/Cisco/Quagga
    2. The type of access - SSH/Telnet and Password/Key
    3. The port on the device that can be used to access via SSH/Telnet
    4. The prompt on the device (i.e., how does the command prompt on the router look like)
    5. The Access rate for the device (minimum interval between two commands in milliseconds)
    6. The username, password or key (depending on the option that you chose earlier)
    7. The list of commands allowed on the device. This list includes Aliases for commands that you want to allow. Aliases should begin with one of the following: BGP_, IP_, IPv6_ or STATUS_ depending on the type of information. (Example: STATUS_WHO). For each Alias for a command in this list, you also need to know
      1. The actual command to be executed on the device
      2. The minimum and maximum number of parameters that are allowed along with the command


  • An Example service.properties file which lists out commands for various types of devices is available as the last page in the document above


Option 1: Using interactive questions

  • The perfSONAR Bundle installer makes use of the SSH Telnet MP installer to install the service for you.
  • The installer asks if you have an existing service.properties file that you wish to use. If you don't have one, answer no (n) and it will automatically build the file by asking you questions listed in the interactive questions section of this manual
  • You also have the option to provide a CSV file containing the devices and commands you wish to be supported by the SSH Telnet MP. You can view the layout of the CSV file here: http://users.atlantis.ugent.be/smelis/sshtelnetconfigtemplate.csv. For every kind of device and access method there is an example in that template. A real life example of such a CSV file can be found here.
  • The perfSONAR Bundle installation manual for 2.1 lists out the questions that the installer asks (for configuration of SSH Telnet MP). We recommend that you read through these questions and prepare the list of answers that you want to provide.
  • If you make any mistake while answering the question, stop the installer (ctrl-c) and start again
  • Once you have gone through the process, if you wish to modify the values that you had entered previously, you can either start with the configuration again (i.e. this option) or you can modify the service.properties file as explained in option 2 below.


Option 1a: Using pre-configured list of commands

  • Commands that need to be configured for SSH Telnet MP can either be input manually or a pre-configured list can be chosen.
  • The bundle installer asks if you wish to use a pre-configured list. Choose this option if you are happy with the commands available in the pre-configured list.
  • The commands included in the pre-configured list are:
For Cisco:
STATUS_SHOW_ENVIRONMENT - show environment (show chassis environment)
STATUS_INTERFACE_STATS - show interface <interface> (show interface statistics)
BGP_ROUTE_IPv4 - show ip bgp <ip address> (show bgp routing table)
IP_SHOW_ROUTE - show ip route <ip address> (show the current IP routing table for <ip address>)
STATUS_SHOW_INTERFACE_CONFIGURATION - show running interface <ip address> (display the interface configuration for <interface>)
IP_PING - ping <ip address> (ping an <ip address>)
IP_TRACEROUTE - trace <ip address> (trace the IPv4 path to <ip address>)
IPv6_SHOW_ROUTE - show ipv6 route <ipv6 address> (display IPv6 routing table entry for <ipv6 address>)
IPv6_BGP_TABLE - show bgp ipv6 <IPv6 prefix network/length> (display current BGP table routing entry for <IPv6 prefix>)
IPv6_PING - ping ipv6 <ipv6 address> (ping an <ipv6 address>)
IPv6_TRACEROUTE - trace ipv6 <ipv6 address> (trace the ipv6 path to <ipv6 address>)
STATUS_SHOW_MPLS_L2_VC_DETAIL - show mpls l2transport vc detail (display detailed information about Any Transport over MPLS (AToM) virtual circuits (VCs))
IP_SHOW_ROUTE_VRF - show ip route vrf <VPN name> (display the IP routing table associated with a Virtual Private Network (VPN) routing/forwarding instance (VRF))
IP_PING_VRF - ping vrf <ip address> (pings an <ip address> that has a specific VRF)
IP_TRACEROUTE_VRF - trace vrf <ip address> (displays the path to <ip address> that has a specific VRF)
For Juniper:
STATUS_INTERFACE_STATS - show interfaces <interface> (show interface statistics)
STATUS_INTERFACE_DESCRIPTIOM - show interfaces descriptions (show interfaces descriptions)
BGP_ROUTE_IPv4 - show route protocol bgp <ip address> (show bgp routing table)
IP_SHOW_ROUTE_VRF - show route table <routing-instance name> (display the IP routing table associated with a Virtual Private Network (VPN) routing/forwarding instance (VRF))
STATUS_SHOW_INTERFACE_CONFIGURATION - show configuration interfaces <interface> (display the interface configuration for <interface>)
IP_PING - ping <ip address> (ping an <ip address>)
IP_TRACEROUTE - traceroute <ip address> (trace the IPv4 path to <ip address>)
IPv6_SHOW_ROUTE - show route table inet6 <IPv6 address> (display IPv6 routing table entry for <ipv6 address>)
IPv6_BGP_TABLE - show route protocol bgp table inet6 <IPv6 address> (display current BGP table routing entry for <IPv6 prefix>)
IPv6_PING - ping inet6 <IPv6 address> (ping an <ipv6 address>)
IPv6_TRACEROUTE - traceroute inet6 <IPv6 address> (trace the ipv6 path to <ipv6 address>)
STATUS_MPLS_L2_VC_DETAIL - show l2circuit connections extensive (display detailled information about Any Transport over MPLS (AToM) virtual circuits (VCs))
IP_SHOW_ROUTE_VRF - show route table <routing-instance name> (display the IP routing table associated with a Virtual Private Network (VPN) routing/forwarding instance (VRF))
IP_PING_VRF - ping <ip address> routing-instance <routing-instance name> (pings an <ip address> that has a specific VRF)
IP_TRACEROUTE_VRF - traceroute <ip address> routing-instance <routing-instance name> (displays the path to <ip address> that has a specific VRF)


Option 1b: Providing your own set of commands via interactive questions

  • If you are not happy with the pre-configured list, you can enter your own set of commands
  • Refer to the interactive questions section in the bundle installer manual for more information on what questions will be asked and in which order
  • The commands supported are shown in this file: http://users.atlantis.ugent.be/smelis/supported_commands.xls. The commands shown in yellow are the ones that are in the minimum package.



Option 2: Writing up/Modifying service.properties file

  • You can either write up a new service.properties file or modify the existing one based on the descripton document available via the link provided in the Requirements section
  • The document provides a detailed explanation of what fields are allowed, which are mandatory, the default values to be provided and some examples
  • If you have installed the service via the bundle installer, usually the service.properties file is located here:

/home/perfsonar/perfsonar-bundle-2.1/webapps/JAVA-SSHTELNET-MP-1.2/WEB-INF/classes/perfsonar/conf/service.properties

where
/home/perfsonar/perfsonar-bundle-2.1 is where perfsonar-bundle tar file has been extracted
/home/perfsonar/perfsonar-bundle-2.1/webapps is where the webapps directory is located (default)
JAVA-SSHTELNET-MP-1.2 is the name of the service
  • Before you edit the file, we recommend that you make a backup copy of it.


Administration (Backup, modify, restore) of the service.properties file

  • The service.properties file in a deployed service can be found here:

/home/perfsonar/perfsonar-bundle-2.1/webapps/JAVA-SSHTELNET-MP-1.2/WEB-INF/classes/perfsonar/conf/service.properties

where
/home/perfsonar/perfsonar-bundle-2.1 is where perfsonar-bundle tar file has been extracted
/home/perfsonar/perfsonar-bundle-2.1/webapps is where the webapps directory is located (default)
JAVA-SSHTELNET-MP-1.2 is the name of the service
  • If you need to make any modifications to this file, you can do so with the help of the guide document (link in the requirements section)
  • If for some reason this file is lost, you can either simply restore the file from the backup location and then restart tomcat or you can install the service again and give this file as the service.properties file (you will be asked during installation).
  • When you make any modifications to the service.properties file, you will need to save the file and RESTART TOMCAT for changes to take effect
  • Note: the file name service.properties is case sensitive. If the service cannot find this file in the specified directory. It will crash!
  • We recommend that a backup copy of service.properties file is created before modifying it


Stitching for perfSONAR Bundle 2.0

Objectives

  • To create a service.properties file for your SSH Telnet MP Installation which will configure the list of devices avaiable for querying as well as the list of commands permitted

Requirements before using this guide

  1. List of devices that you want to allow your SSH Telnet MP installation to contact
    1. This list can either be (alias,device DNS/URL). The alias could be device DNS/URL itself. Example: (paris,rt1.par.fr.geant2.net) or (rt1.par.fr.geant2.net,rt1.par.fr.geant2.net)
  2. For each device you also need to know:
    1. The type of equipment (manufacturer) - Juniper/Cisco/Quagga
    2. The type of access - SSH/Telnet and Password/Key
    3. The port on the device that can be used to access via SSH/Telnet
    4. The prompt on the device (i.e., how does the command prompt on the router look like)
    5. The Access rate for the device (minimum interval between two commands in milliseconds)
    6. The username, password or key (depending on the option that you chose earlier)
    7. The list of commands allowed on the device. This list includes Aliases for commands that you want to allow. Aliases should begin with one of the following: BGP_, IP_, IPv6_ or STATUS_ depending on the type of information. (Example: STATUS_WHO). For each Alias for a command in this list, you also need to know
      1. The actual command to be executed on the device
      2. The minimum and maximum number of parameters that are allowed along with the command


  • An Example service.properties file which lists out commands for various types of devices is available as the last page in the document above


Option 1: Using interactive questions

  • The perfSONAR Bundle installer makes use of the SSH Telnet MP installer to install the service for you.
  • The installer asks if you have an existing service.properties file that you wish to reuse. If you don't have one, answer no (n) and it will automatically build the file by asking you questions listed in the requirements section above
  • The perfSONAR Bundle installation manual for 2.x lists out the questions that the installer asks (for configuration of SSH Telnet MP). We recommend that you read through these questions and prepare the list of answers that you want to provide.
  • If you make any mistake while answering the question, stop the installer (ctrl-c) and start again
  • Once you have gone through the process, if you wish to modify the values that you had entered previously, you can either start with the configuration again (i.e. this option) or you can modify the service.properties file as explained in option 2 below.


Option 2: Writing up/Modifying service.properties file

  • You can either write up a new service.properties file or modify the existing one based on the descripton document available via the link provided in the Requirements section
  • The document provides a detailed explanation of what fields are allowed, which are mandatory, the default values to be provided and some examples
  • If you have installed the service via the bundle installer, usually the service.properties file is located here:

/home/perfsonar/perfsonar-bundle-2.0/webapps/JAVA-SSHTELNET-MP-1.1/WEB-INF/classes/perfsonar/conf/service.properties

where
/home/perfsonar/perfsonar-bundle-2.0 is where perfsonar-bundle tar file has been extracted
/home/perfsonar/perfsonar-bundle-2.0/webapps is where the webapps directory is located (default)
JAVA-SSHTELNET-MP-1.1 is the name of the service
  • Before you edit the file, we recommend that you make a backup copy of it.


Administration (Backup, modify, restore) of the service.properties file

  • The service.properties file in a deployed service can be found here:

/home/perfsonar/perfsonar-bundle-2.0/webapps/JAVA-SSHTELNET-MP-1.1/WEB-INF/classes/perfsonar/conf/service.properties

where
/home/perfsonar/perfsonar-bundle-2.0 is where perfsonar-bundle tar file has been extracted
/home/perfsonar/perfsonar-bundle-2.0/webapps is where the webapps directory is located (default)
JAVA-SSHTELNET-MP-1.1 is the name of the service
  • If you need to make any modifications to this file, you can do so with the help of the guide document (link in the requirements section)
  • If for some reason this file is lost, you can either simply restore the file from the backup location and then restart tomcat or you can install the service again and give this file as the service.properties file (you will be asked during installation).
  • When you make any modifications to the service.properties file, you will need to save the file and RESTART TOMCAT for changes to take effect
  • Note: the file name service.properties is case sensitive. If the service cannot find this file in the specified directory. It will crash!
  • We recommend that a backup copy of service.properties file is created before modifying it


Personal tools