Difference between revisions of "SPP Command Interface"

From ARL Wiki
Jump to navigationJump to search
Line 16: Line 16:
 
Or a user may want to reserve resources in advance (e.g., port bandwidth and NPE fastpath).
 
Or a user may want to reserve resources in advance (e.g., port bandwidth and NPE fastpath).
  
That command line interface is provided through four programs:
+
That command line interface is currently provided through four programs: ''client'', ''resrv'', ''fltr_ipv4'' and ''create_fp_ipv4''.
 +
The ''client'' and ''resrv'' programs apply to any metanet while ''fltr_ipv4'' and ''create_fp_ipv4'' are specific to the IPv4 code option.
  
{| align=center border=0 cellspacing=5 cellpadding=2
+
{| align=center border=1 cellspacing=0 cellpadding=3
 +
! Program            || Functionality
 
|-
 
|-
| client   || XXX
+
| ''client''        || Interface information, endpoint management, <br>fastpath management, queue management
 
|-
 
|-
| resrv     || XXX
+
| ''resrv''          || Resource reservation
 
|-
 
|-
| fltr     || XXX
+
| ''fltr_ipv4''     || Filter management
 
|-
 
|-
| create_fp || XXX
+
| ''create_fp_ipv4'' || Fastpath configuration, LD and EX traffic handling
 
|}
 
|}
  
The first two (client and resrv) provide commands that are used for all metanets.
+
There will be other metanet-specific programs as other code options get developed.
There exist metanet-specific versions of the second two (fltr and create_fp).
+
It is worth noting that all of these programs implement their functionallity by calling RMP library functions.
For example, the ''fltr'' and ''create_fp'' programs used in the [[The GEC4 Demo]] configuration script are specific to the IPv4 code option.
+
The fact that these programs exist as separate programs is historic.
Even though all of these programs implement their functionallity by calling RMP library functions, they exist as separate programs for historical reasons.
+
For example, one could have a single ''ipv4_control'' program that included all of the functionality of these programs.
 +
Furthermore, a new code option such as ''vnet'' would have a ''vnet_control'' program that included the functionality in the ''client'' and ''resrv'' programs above and vnet-specific functionality for filters and handling LD and EX traffic.
 +
(Note:  The programs ''fltr_ipv4'' and ''create_fp_ipv4'' were called ''fltr'' and ''create_fp'' respectively in [[The GEC4 Demo]].)
  
 
== Command Interface Syntax ==
 
== Command Interface Syntax ==
Line 78: Line 82:
 
Display the endpoint associated with (fastpath I, meta-interface I')
 
Display the endpoint associated with (fastpath I, meta-interface I')
 
         </ul>
 
         </ul>
=== Resource Reservations ===
+
=== Reservation Management ===
  
INFORMATION:
 
 
   resrv --cmd get_resrvs
 
   resrv --cmd get_resrvs
 +
        <ul style="padding-left: 0.5in;">
 
Display all slice reservations
 
Display all slice reservations
 +
        </ul>
 
   resrv --cmd get_resrv [--date D]
 
   resrv --cmd get_resrv [--date D]
Display slice reservation for period covered by date D (default: current)
+
        <ul style="padding-left: 0.5in;">
Date format is YYYYMMDDHHMMSS
+
Display slice reservation for period covered by date D (default: current).
RESERVATIONS:
+
<br>Date format is YYYYMMDDHHMMSS.
 +
        </ul>
 
   resrv --cmd make_resrv --xfile F
 
   resrv --cmd make_resrv --xfile F
 +
        <ul style="padding-left: 0.5in;">
 
Make a reservation described by XML file F
 
Make a reservation described by XML file F
 +
        </ul>
 
   resrv --cmd cancel_resrv [--date D]
 
   resrv --cmd cancel_resrv [--date D]
Cancel slice reservation for period covered by date D (default: current)
+
        <ul style="padding-left: 0.5in;">
Date format is YYYYMMDDHHMMSS
+
Cancel slice reservation for period covered by date D (default: current).
 +
<br>Date format is YYYYMMDDHHMMSS.
 +
        </ul>
 
   resrv --cmd update_resrv --xfile F
 
   resrv --cmd update_resrv --xfile F
 +
        <ul style="padding-left: 0.5in;">
 
Update slice reservation described by XML file F
 
Update slice reservation described by XML file F
RESOURCES:
+
        </ul>
 
   resrv --cmd alloc_plspec
 
   resrv --cmd alloc_plspec
 +
        <ul style="padding-left: 0.5in;">
 
Allocate GPE slice resources
 
Allocate GPE slice resources
 +
        </ul>
 
   resrv --cmd free_plspec
 
   resrv --cmd free_plspec
 +
        <ul style="padding-left: 0.5in;">
 
Free GPE slice resources
 
Free GPE slice resources
 +
        </ul>
 
   resrv --cmd free_fpspec --fpid I
 
   resrv --cmd free_fpspec --fpid I
 +
        <ul style="padding-left: 0.5in;">
 
Free fastpath slice resources for fastpath I
 
Free fastpath slice resources for fastpath I
 +
        </ul>
  
  
Line 124: Line 141:
 
Free (A, N) as a local end of a UDP tunnel
 
Free (A, N) as a local end of a UDP tunnel
 
         </ul>
 
         </ul>
  client --cmd alloc_fastpath --copt C --firm K --soft 0
+
<!-- COMMENT
                --fltrs N1 --qs N2 --stats N3 --buffs N4 --sram 4096 --dram 0
+
client --cmd alloc_fastpath --copt C --firm K --soft 0
        <ul style="padding-left: 0.5in;">
+
#                --fltrs N1 --qs N2 --stats N3 --buffs N4 --sram 4096 --dram 0
Allocate fastpath resources for code option C:
+
#        <ul style="padding-left: 0.5in;">
  K Kbps firm bandwidth, N1 filters, N2 queues, N3 stats indices, N4 buffers
+
# Allocate fastpath resources for code option C:
        </ul>
+
#   K Kbps firm bandwidth, N1 filters, N2 queues, N3 stats indices, N4 buffers
  client --cmd free_fastpath --fpid I
+
#        </ul>
        <ul style="padding-left: 0.5in;">
+
client --cmd free_fastpath --fpid I
Free the resources for fastpath I
+
#        <ul style="padding-left: 0.5in;">
        </ul>
+
# Free the resources for fastpath I
 +
#        </ul>
 +
END -->
  
 
=== Queue Management ===
 
=== Queue Management ===
  
   client --cmd get_queue_params --fpid I --qid I'
+
   client --cmd get_queue_params --fpid I --qid Q
 
         <ul style="padding-left: 0.5in;">
 
         <ul style="padding-left: 0.5in;">
Get the threshold and bandwidth for (fastpath I, queue I')
+
Get the threshold and bandwidth for (fastpath I, queue Q)
 
         </ul>
 
         </ul>
   client --cmd get_queue_len --fpid I --qid I'
+
   client --cmd get_queue_len --fpid I --qid Q
 
         <ul style="padding-left: 0.5in;">
 
         <ul style="padding-left: 0.5in;">
Get the length (bytes) of (fastpath I, queue I')
+
Get the length (bytes) of (fastpath I, queue Q)
 
         </ul>
 
         </ul>
 
   client --cmd bind_queue --fpid I --miid I' --qid_list_type 0 --qid_list Q1 --qid_list Q2 ...
 
   client --cmd bind_queue --fpid I --miid I' --qid_list_type 0 --qid_list Q1 --qid_list Q2 ...
Line 153: Line 172:
 
Bind queues in the range Q1 to Q2-1 inclusive to (fastpath I, meta-interface I')
 
Bind queues in the range Q1 to Q2-1 inclusive to (fastpath I, meta-interface I')
 
         </ul>
 
         </ul>
   client --cmd set_queue_params --fpid I --qid I' --threshold B --bw K
+
   client --cmd set_queue_params --fpid I --qid Q --threshold B --bw K
 
         <ul style="padding-left: 0.5in;">
 
         <ul style="padding-left: 0.5in;">
 
Set the threshold and bandwidth of (fastpath I, queue I') to B bytes and K Kbps
 
Set the threshold and bandwidth of (fastpath I, queue I') to B bytes and K Kbps
Line 159: Line 178:
  
 
=== Filter Management ===
 
=== Filter Management ===
 +
 +
xxx
 +
 +
=== Fastpath Creation ===
 +
 +
xxx

Revision as of 20:37, 11 December 2009


System Resource Manager (SRM) and Resource Manager Proxy (RMP)

Major Control Software Modules

The page SPP Control Software describes the System Resource Manager (SRM) that runs on the SPP's Control Processor and the Resource Manager Proxy (RMP) that runs on each SPP's GPE, and it describes the programming API provided by the RMP. This page describes the accompanying command line interface which allows users to reserve and configure resources interactively or through a shell script. In brief, the SRM coordinates the use of various SPP resources while the RMP provides an interface through which user slices can request and configure resources. The RMP, in turn, may communicate with the Substrate Control Daemons (SCD) in the Line Card and the NPE to configure packet pathways.

User requests are made through an interface provided by the RMP on the user’s assigned GPE. The RMP forwards these requests to the SRM which manages all system level resources, including external port numbers, physical interface bandwidth and NPE resources. For example, a user can request the use of a specific external port number in order to run a server that listens on that port at the user's GPE. Or a user may want to reserve resources in advance (e.g., port bandwidth and NPE fastpath).

That command line interface is currently provided through four programs: client, resrv, fltr_ipv4 and create_fp_ipv4. The client and resrv programs apply to any metanet while fltr_ipv4 and create_fp_ipv4 are specific to the IPv4 code option.

Program Functionality
client Interface information, endpoint management,
fastpath management, queue management
resrv Resource reservation
fltr_ipv4 Filter management
create_fp_ipv4 Fastpath configuration, LD and EX traffic handling

There will be other metanet-specific programs as other code options get developed. It is worth noting that all of these programs implement their functionallity by calling RMP library functions. The fact that these programs exist as separate programs is historic. For example, one could have a single ipv4_control program that included all of the functionality of these programs. Furthermore, a new code option such as vnet would have a vnet_control program that included the functionality in the client and resrv programs above and vnet-specific functionality for filters and handling LD and EX traffic. (Note: The programs fltr_ipv4 and create_fp_ipv4 were called fltr and create_fp respectively in The GEC4 Demo.)

Command Interface Syntax

The client and resrv commands use GNU-style long options (e.g., --cmd get_endpoint, --ipaddr 10.1.2.3). And although they both have a few arguments that controls their configuration (e.g., message log noise volume), this page only describes the user commands. In the descriptions below, the following metasymbols are used in the syntactic descriptions:

A An IP address (e.g., 192.168.2.32) K The number of Kilobits per second
D A date in YYYMMDDHHMMSS format N A number (non-negative)
F A filename P Protocol number (e.g., 6 (TCP), 17 (UDP))
I An identifier or index Q Queue identifier

When a command uses multiple instances of a metasymbol, quotes or integers may be used to distinguish each instance (e.g., N and N' or N1, N2 and N3).

Command Interface

Getting Interface Information

 client --cmd get_ifaces
    Display all interfaces
 client --cmd get_ifpeer --ifn N
    Display the peer of interface num N
 client --cmd get_ifattrs --ifn N
    Display the attributes of interface num N
 client --cmd get_ifn --ipaddr A
    Display the interface associated with IP address A
 client --cmd get_endpoint --fpid I --mii I'
    Display the endpoint associated with (fastpath I, meta-interface I')

Reservation Management

 resrv --cmd get_resrvs
    Display all slice reservations
 resrv --cmd get_resrv [--date D]
    Display slice reservation for period covered by date D (default: current).
    Date format is YYYYMMDDHHMMSS.
 resrv --cmd make_resrv --xfile F
    Make a reservation described by XML file F
 resrv --cmd cancel_resrv [--date D]
    Cancel slice reservation for period covered by date D (default: current).
    Date format is YYYYMMDDHHMMSS.
 resrv --cmd update_resrv --xfile F
    Update slice reservation described by XML file F
 resrv --cmd alloc_plspec
    Allocate GPE slice resources
 resrv --cmd free_plspec
    Free GPE slice resources
 resrv --cmd free_fpspec --fpid I
    Free fastpath slice resources for fastpath I


Endpoint Management

 client --cmd alloc_endpoint --bw K --ipaddr A --port N --proto P
    Create the K Kbps capacity LC endpoint (A, N, P)
 client --cmd free_endpoint --ipaddr A --port N --proto P
    Remove the K Kbps capacity LC endpoint (A, N, P)

Fastpath Management

 client --cmd alloc_udp_tunnel --fpid I --bw  K --ipaddr A --port N
    Add (A, N) as a local end of a UDP tunnel with capacity K Kbps to fastpath I
 client --cmd free_udp_tunnel --fpid I --ipaddr A --port N
    Free (A, N) as a local end of a UDP tunnel

Queue Management

 client --cmd get_queue_params --fpid I --qid Q
    Get the threshold and bandwidth for (fastpath I, queue Q)
 client --cmd get_queue_len --fpid I --qid Q
    Get the length (bytes) of (fastpath I, queue Q)
 client --cmd bind_queue --fpid I --miid I' --qid_list_type 0 --qid_list Q1 --qid_list Q2 ...
    Bind queues Q1, Q2, ... to (fastpath I, meta-interface I')
 client --cmd bind_queue --fpid I --miid I' --qid_list_type 1 --qid_list Q1 --qid_list Q2
    Bind queues in the range Q1 to Q2-1 inclusive to (fastpath I, meta-interface I')
 client --cmd set_queue_params --fpid I --qid Q --threshold B --bw K
    Set the threshold and bandwidth of (fastpath I, queue I') to B bytes and K Kbps

Filter Management

xxx

Fastpath Creation

xxx