VPP学习(五)VPP配置文件详解

这里分段解释配置文件内容

unix配置

 

cpu配置

cpu {
        ## In the VPP there is one main thread and optionally the user can create worker(s)
        ## vpp里有一个主线程,用户可以选择创建工作线程
        ## The main thread and worker thread(s) can be pinned to CPU core(s) manually or automatically
        ## 主线程和工作线程可以手动或自动固定到CPU核心上
        ## Manual pinning of thread(s) to CPU core(s)
        ## 手工将线程固定到CPU核心上
        ## Set logical CPU core where main thread runs, if main core is not set
        ## 如果没有设置主核,在主线程运行的地方设置逻辑CPU核心
        ## VPP will use core 1 if available
        ## 如果可用,VPP将使用核1
        # main-core 1

        ## Set logical CPU core(s) where worker threads are running
        ## 设置工作线程运行的逻辑CPU核心
        # corelist-workers 2-3,18-19
        ## 这里是分配到2 3 18 19上
        ## Automatic pinning of thread(s) to CPU core(s)
        ## 自动将线程固定到CPU核心上

        ## Sets number of CPU core(s) to be skipped (1 ... N-1)
        ## 设置要跳过的CPU核心的数量
        ## Skipped CPU core(s) are not used for pinning main thread and working thread(s).
        ## 跳过的CPU核心不用于固定主线程和工作线程
        ## The main thread is automatically pinned to the first available CPU core and worker(s)
        ## are pinned to next free CPU core(s) after core assigned to main thread
        ## 主线程自动固定到第一个可用的CPU核心上,工作线程在分配给主线线程的核心之后,被固定到下一个空闲CPU核心上
        # skip-cores 4

        ## Specify a number of workers to be created
        ## 指定要创建的工作线程数量
        ## Workers are pinned to N consecutive CPU cores while skipping "skip-cores" CPU core(s)
        ## and main thread's CPU core
        ## 工作线程被固定在N个连续的CPU核心上,而跳过skip-cores和主线程核
        # workers 2

        ## Set scheduling policy and priority of main and worker threads
        ## 设置主线程和工作线程的调度策略和优先级
        ## Scheduling policy options are: other (SCHED_OTHER), batch (SCHED_BATCH)
        ## idle (SCHED_IDLE), fifo (SCHED_FIFO), rr (SCHED_RR)
        ## 调度策略选项:other,batch,idle,fifo,rr
        # scheduler-policy fifo

        ## Scheduling priority is used only for "real-time policies (fifo and rr),
        ## and has to be in the range of priorities supported for a particular policy
        ## 调度优先级仅用于“实时策略”(fifo和rr),而且必须在特定政策的优先支持范围内
        # scheduler-priority 50
}

参考资料:https://wiki.fd.io/view/VPP/Command-line_Arguments

  • 0
    点赞
  • 4
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
VPP(Vector Packet Processing)是一种高性能数据平面框架,支持多种协议,包括 IKEv2(Internet Key Exchange version 2)协议。在VPP配置IKEv2,需要进行以下步骤: 1. 安装VPP 首先,需要安装VPP和相关的插件。可以从官方网站上下载最新版本的VPP,并按照官方文档进行安装。 2. 配置IKEv2插件 在VPP中,可以使用IKEv2插件来实现IKEv2协议的支持。需要启用IKEv2插件,可以使用以下命令: ``` set plugins plugin_path /usr/lib64/vpp_plugins/ set plugins plugin default-plugin-enable set plugins plugin ikev2-plugin-enable ``` 3. 配置IKEv2连接 在VPP中,可以使用IKEv2插件来创建IKEv2连接。可以使用以下命令创建IKEv2连接: ``` ikev2 profile name IKEV2-PROFILE ikev2 profile auth shared-secret KEY ikev2 profile local-auth method pre-shared-key ikev2 profile remote-auth method pre-shared-key ikev2 profile local-id name FQDN ikev2 profile remote-id name FQDN ikev2 profile tunnel-ip local IP_ADDRESS ikev2 profile tunnel-ip remote IP_ADDRESS ikev2 profile ike-crypto-profile IKE-CRYPTO-PROFILE ikev2 profile esp-crypto-profile ESP-CRYPTO-PROFILE ``` 4. 配置IKEv2策略 在VPP中,可以使用IKEv2插件来配置IKEv2策略。可以使用以下命令配置IKEv2策略: ``` ikev2 policy name IKEV2-POLICY ikev2 policy proposal 1 encryption aes-256-gcm ikev2 policy proposal 1 integrity sha-256 ikev2 policy proposal 1 dh-group 19 ikev2 policy proposal 1 lifetime seconds 3600 ``` 5. 配置IKEv2安全协议 在VPP中,可以使用IKEv2插件来配置IKEv2安全协议。可以使用以下命令配置IKEv2安全协议: ``` ikev2 crypto name IKE-CRYPTO ikev2 crypto proposal 1 encryption aes-256-gcm ikev2 crypto proposal 1 integrity sha-256 ikev2 crypto proposal 1 dh-group 19 ikev2 crypto proposal 1 lifetime seconds 3600 ``` 6. 配置ESP安全协议 在VPP中,可以使用IKEv2插件来配置ESP安全协议。可以使用以下命令配置ESP安全协议: ``` ikev2 crypto name ESP-CRYPTO ikev2 crypto proposal 1 encryption aes-256-gcm ikev2 crypto proposal 1 integrity sha-256 ikev2 crypto proposal 1 lifetime seconds 3600 ``` 7. 配置IKEv2转发 在VPP中,可以使用IKEv2插件来配置IKEv2转发。可以使用以下命令配置IKEv2转发: ``` ikev2 route name IKEV2-ROUTE ikev2 route local-networks 10.0.0.0/24 ikev2 route remote-networks 10.1.0.0/24 ikev2 route profile IKEV2-PROFILE ``` 以上就是在VPP配置IKEv2的步骤。需要根据实际情况进行调整和修改。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值