From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mogw2033.ocn.ad.jp (mogw2033.ocn.ad.jp [61.118.33.35]) by dpdk.org (Postfix) with ESMTP id 851831B443 for ; Tue, 12 Feb 2019 08:48:29 +0100 (CET) Received: from mf-smf-unw007c1 (mf-smf-unw007c1.ocn.ad.jp [153.138.219.99]) by mogw2033.ocn.ad.jp (Postfix) with ESMTP id 28E5D240236; Tue, 12 Feb 2019 16:48:28 +0900 (JST) Received: from ocn-vc-mts-203c1.ocn.ad.jp ([153.138.219.218]) by mf-smf-unw007c1 with ESMTP id tSisgYXhNQ5zctSnsgZ7Fc; Tue, 12 Feb 2019 16:48:28 +0900 Received: from smtp.ocn.ne.jp ([153.149.227.135]) by ocn-vc-mts-203c1.ocn.ad.jp with ESMTP id tSnrgZ8xolSxJtSnrgQ17C; Tue, 12 Feb 2019 16:48:28 +0900 Received: from localhost.localdomain (p1649004-ipngn15701marunouchi.tokyo.ocn.ne.jp [153.204.174.4]) by smtp.ocn.ne.jp (Postfix) with ESMTPA; Tue, 12 Feb 2019 16:48:27 +0900 (JST) From: ogawa.yasufumi@lab.ntt.co.jp To: spp@dpdk.org, ferruh.yigit@intel.com, ogawa.yasufumi@lab.ntt.co.jp Date: Tue, 12 Feb 2019 16:48:24 +0900 Message-Id: <1549957704-9632-1-git-send-email-ogawa.yasufumi@lab.ntt.co.jp> X-Mailer: git-send-email 2.7.4 Subject: [spp] [PATCH] docs: add desc for default config file X-BeenThere: spp@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Soft Patch Panel List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Feb 2019 07:48:30 -0000 From: Yasufumi Ogawa As config of SPP CLI is imported from the config file, add descriptions about. This update also includes some of revisings of config command. Signed-off-by: Yasufumi Ogawa --- docs/guides/commands/common.rst | 4 +-- docs/guides/setup/howto_use.rst | 55 +++++++++++++++++++++++++++++++++++++---- 2 files changed, 52 insertions(+), 7 deletions(-) diff --git a/docs/guides/commands/common.rst b/docs/guides/commands/common.rst index 441c100..cfa4eaf 100644 --- a/docs/guides/commands/common.rst +++ b/docs/guides/commands/common.rst @@ -41,8 +41,8 @@ other than default ``spp >``. .. code-block:: none - # set prompt to "$ spp" - spp > config prompt "$ spp" + # set prompt to "$ spp " + spp > config prompt "$ spp " Set prompt: "$ spp " $ spp diff --git a/docs/guides/setup/howto_use.rst b/docs/guides/setup/howto_use.rst index 2f3e37f..cc3dd9b 100644 --- a/docs/guides/setup/howto_use.rst +++ b/docs/guides/setup/howto_use.rst @@ -135,20 +135,34 @@ soure or destination of phy ports. Multiple SPP nodes Launch SPP CLI with three entries of binding addresses with ``-b`` option -for specifying ``spp-ctl``. Here is an example. +for specifying ``spp-ctl``. .. code-block:: console - # Launch SPP CLI + # Launch SPP CLI with three nodes $ python src/spp.py -b 192.168.11.101 \ -b 192.168.11.102 \ -b 192.168.11.103 \ -You can find the host under the management of SPP CLI and switch with -``server`` command. +You can also add nodes after SPP CLI is launched. .. code-block:: console + # Launch SPP CLI with one node + $ python src/spp.py -b 192.168.11.101 + Welcome to the SPP CLI. Type `help` or `?` to list commands. + + # Add the rest of nodes after + spp > server add 192.168.11.102 + Registered spp-ctl "192.168.11.102:7777". + spp > server add 192.168.11.103 + Registered spp-ctl "192.168.11.103:7777". + +You find the host under the management of SPP CLI and switch with +``server`` command. + +.. code-block:: none + spp > server list 1: 192.168.1.101:7777 * 2: 192.168.1.102:7777 @@ -156,7 +170,7 @@ You can find the host under the management of SPP CLI and switch with To change the server, add an index number after ``server``. -.. code-block:: console +.. code-block:: none # Launch SPP CLI spp > server 3 @@ -181,6 +195,37 @@ All of options can be referred with help option ``-h``. All of SPP CLI commands are described in :doc:`../../commands/index`. +Default Configuration +^^^^^^^^^^^^^^^^^^^^^ + +SPP CLI imports several params from configuration file while launching. +Some of behaviours of SPP CLI depends on the params. +The default configuration is defined in +``src/controller/config/default.yml``. +You can change this params by editing the config file, or from ``config`` +command after SPP CLI is launched. + +All of config params are referred by ``config`` command. + +.. code-block:: none + + # show list of config + spp > config + - max_secondary: "16" # The maximum number of secondary processes + - sec_nfv_nof_lcores: "1" # Default num of lcores for workers of spp_nfv + .... + +To change the config, set a value for the param. +Here is an example for changing command prompt. + +.. code-block:: none + + # set prompt to "$ spp " + spp > config prompt "$ spp " + Set prompt: "$ spp " + $ spp + + SPP Primary ----------- -- 2.7.4