“Sangoma Wanpipe驱动命令”的版本间的差异
(创建页面,内容为“WANPIPE操作的核心是“wanrouter”脚本工具. 它可以用来执行start/stop/restart 和显示WANPIPE当前状态和环境。 usage: wanrouter <command>...”) |
(没有差异)
|
2017年2月2日 (四) 15:22的最新版本
WANPIPE操作的核心是“wanrouter”脚本工具. 它可以用来执行start/stop/restart 和显示WANPIPE当前状态和环境。
usage: wanrouter <command> Linux paths: Wanpipe configuration directory: /etc/wanpipe Wanpipe executable/script directory: /usr/sbin Asterisk configuration directory: /etc/asterisk Zaptel configuration file: /etc/zaptel.conf
Wanpipe, Dahdi and Asterisk (Manual Start/Stop)
手动停止Wanpipe,你必须先停止 #> amportal stop #>smg_ctrl stop (仅适用于A500 BRI 用户) #> wanrouter stop #>service dahdi stop
To manually start Wanpipe devices, Zaptel and Asterisk run: #> wanrouter start #>smg_ctrl start (only for A500 BRI users) #> dahdi_cfg -vvvv (If you have AFT series T1/E1 or Analog cards) #>safe_asterisk #> asterisk -r ( To connect with Asterisk )
Wanpipe, Zaptel and Asterisk (Manual Start/Stop)
手动停止Wanpipe,你必须先停止 #> amportal stop #>smg_ctrl stop (only for A500 BRI users) #> wanrouter stop #>service zaptel stop
手动启动Wanpipe 设备, Zaptel and Asterisk run: #> wanrouter start #>smg_ctrl start (only for A500 BRI users) #> ztcfg -vvvv (If you have AFT series T1/E1 or Analog cards) #>safe_asterisk #> asterisk -r ( To connect with Asterisk )
WAN Router 命令
Usage: wanrouter: {options} <wanpipe#> <interface>
#>wanrouter start : Starts all devices specified in wanrouter.rc WAN_DEVICES
#>wanrouter stop : Stops all devices specified in wanrouter.rc WAN_DEVICES
#>wanrouter restart : Restart all devices specified in wanrouter.rc WAN_DEVICES
#>wanrouter start wanpipe# : Start a single device
#>wanrouter stop wanpipe# : Stops a single device #>wanrouter restart wanpipe# : Restart a single device #>wanrouter list : List all active devices
#>wanrouter modules: Show wanpipe kernel modules
#>wanrouter status: Display status for all active devices
#>wanrouter summary: Summary of Wanpipe config files
#>wanrouter hwprobe: #>wanrouter hwprobe verbose (for A200/A400 analog cards to check FXO/FXS modules ) Display wanpipe hardware probe info.
#>wanrouter messages: Display wanpipe kernel event messages i.e. /var/log/messages
#>wanrouter version: wanpipe version information.
WANPIPE Environment Check
Make sure that the new WANPIPE kernel modules have been installed correctly, that they can be successfully loaded into the kernel, and that the hardware is properly detected.
#> wanrouter hwprobe Check that a configuration (.conf) file exists in wanpipe configuration directory
#> wanrouter summary Make sure that no WANPIPE devices are currently running on the system
#> wanrouter list
WANPIPE Startup 执行脚本启动的设备 start/stop/restart WANPIPE devices都保存在wanrouter.rc文件: (默认是wanpipe1)
#> wanrouter start #> wanrouter stop #> wanrouter restart
启动 start/stop/restart 单 wanpipe 设备: (例如: wanpipe2) 利用命令行启动单设备:
#> wanrouter start wanpipe2 #> wanrouter stop wanpipe2 #> wanrouter restart wanpipe2
打印当前状态和配置设备:
#> wanrouter status
Wanpipe 高级用户操作
Wanpipe 内核软件包 1. Wanpipe/Zaptel Kernel Drivers. The drivers are listed in order of dependency. sdladrv.o (sdladrv.ko) : Hardware Layer under Linux (FreeBSD) zaptel.o (zaptel.ko) : Zaptel Layer under Linux (FreeBSD) wanrouter.o (wanrouter.ko) : Wanpipe Protocol Interface Layer under Linux (FreeBSD) wanpipe.o (wanpipe.ko) : Wanpipe multi-protocol layer under Linux (FreeBSD) 2. 用户端程序 2.1 配置工具 wancfg Wanpipe configuration tool 2.2 操作 wanconfig // 启动ADSL wanconfig -a /etc/wanpipe/wan_adsl.list card wanpipe1 up (Linux) wanconfig -a /usr/local/etc/wanpipe/wan_adsl.list card wanpipe1 up (FreeBSD) wanrouter Wanpipe operation script used to start/stop/restart Wanpipe drivers. The wanrouter script uses the above (wanconfig) to start wanpipe as well as standard "ifconfig" to bring all necessary interfaces up.
wanpipemon- Debug/监测工具 Wanpipe 用来检测硬件,驱动和线路同步问题
Graphical Mode: wanpipemon -g // 显示图形界面 Raw trace: wanpipemon -i <if name> -c tr // 显示原数据 D-Channel trace: wanpipemon -i <if name> -c trd // 获取 D 通道信令消息,只是PRI Alarms : wanpipemon -i <if name> -c Ta // 线路状态告警工具 Hardware echo canceller monitoring: wanpipemon -i <if name> -c ehw // 硬件 回声抑制模块检测工具
Wanpipe 手动启动脚本 如果用户不愿意使用脚本启动工具的话,可以使用以下命令按照顺序分步执行:
wanrouter start
1. Load Kernel Modules // 加载内核模块
Linux: #>insmod sdladrv.o #>insmod zaptel.o #>insmod wanrouter.o #>insmod wanpipe.o or #>modprobe -v wanpipe FreeBSD: #> kldload sdladrv.ko #> kldload zaptel.ko #> kldload wanrouter.ko #> kldload wanpipe.ko or #> kldload wanpipe
2. Configure and Start Drivers // 配置和启动设备
#> wanconfig card wanpipe1 up
3. Confirmation // 确认
#>tail -f /var/log/messages
4. Check the events and driver statistics (Linux). // 检查事件和驱动的数据
#>cat /proc/net/wanrouter/status
5. Check driver state // 检查驱动状态
Hardware Echo canceller commands (A104d/A108d/A200d only) // 硬件回声抑制DSP命令
操作命令前,确认硬件已经运行并且状态正常
#> wanpipemon -i <interface name> -c ehw
以上命令应该显示Sangoma HW回声模块已经在通道N被激活。这里N代表进行通话的语音通道 如果显示正常工作,通过一些配置启用硬件回声抑制模块:
1)在wanpipe*.conf里面设置TDMV_HWEC = YES in wanpipe*.conf 2)在/etc/dahdi/system.conf 文件注释掉 MG2类似的软件回声模块 3)在chan_dahdi.conf或者旧版本的zaptel下面添加 echocancel=yes 支持硬件回声抑制