日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

SIPp web frontend(2)

發布時間:2025/3/8 编程问答 20 豆豆
生活随笔 收集整理的這篇文章主要介紹了 SIPp web frontend(2) 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

SIP?VoIP?測試交流群: 323827101


歡迎大家轉載。為保留作者成果,轉載請注明出處。http://blog.csdn.net/netluoriver。有些文件在資源中也能夠下載。假設你沒有積分。能夠聯系我索要!


3.6Adding calls to a test(測試腳本添加呼叫)

To add a call, use the?add a call?link of the corresponding party (see in the figure above) and get to the?Create new call?screen.

加入一個呼叫,對應的一端使用add a call?鏈接 (見上圖)和開始創建新呼叫

Here the command line parameters to pass to SIPp can be set up (the corresponding parameters are stated in round brackets, e.g.,?-timeout) or (-m), but first

這里的命令行參數能夠設置SIPp(用圓括號規定對應的參數比如:(-timeout)或(-m)),首先

·choose an?Executable?(the version of SIPp you want to use, defined in?config.ini.php. See section?Config file?for more details).

選擇一運行文件(在config.ini.php中定義你想用的SIPp版本號

查看Config file一節獲得很多其它具體信息)

·choose a?Scenario?defined earlier in the?Manage scenarios?tab (Section?Manage scenarios).

管理場景選項卡選擇一個前面定義的場景

·if a client scenario is used, enter a?Remote host. This is where SIPp addresses its messages to.

假設已經用了client場景,輸入一個遠程主機地址。

地址就是SIPp發送給對端的消息地址。

·check the?Monitor call?checkbox, if during the test execution realtime feedback of the test progress should be displayed. In that case the tester can also influence the test by pausing it, or by adjusting the packet rate (See section?Run a test?for more details).

檢查監視呼叫復選框,假設在測試腳本時,會實時顯示測試過程。在那種情況下測試者通過暫停或調整包的速率也會影響測試效果(查看執行一個測試一節獲得更加具體信息)

·check the?Log?checkbox, if log files (-trace_err, -trace_logs, -trace_rtt, -trace_stat) should be stored in the database.

檢查日志復選框,日志文件(-trace_err, -trace_logs, -trace_rtt, -trace_stat)否存到數據庫中。

If the given configuration options are not enough, the?Extended parameters?text field can be used to pass any command line parameters to SIPp. The?Extended parameters?are not evaluated or modified in any way. It is up to the administrator to use a correct syntax. There may be some command line options that do not work, or even cause SIPp to hang (i.e.?-bg).

假設所給的配置選項不夠用。Extended parameters?文本框能夠給SIPp傳遞不論什么命令行參數。?Extended parameters由管理員使用正確的語法。

并不以不論什么方式評估或改動。或許會有一些命令選項不可用或引起SIPp掛起(比如-bg選項)

If a parameter is specified in the form and also as?extended parameter, the?extended parameter?has the higher priority, and overwrites the other.

假設在表格中指定了一個參數,而且也作為擴展參數,那么擴展參數會有更高的優先權,寫還有一

Global parameters (applied to any call) can be defined in the?AVP Section?of the?config.ini.php. These have the lowest priority.

?config.ini.phpAVP Section能定義全局參數(應用于不論什么呼叫)。這些有最低優先權。

3.7Modify a test / create a new test version(改動/創建一個新測試腳本)

Tests and calls can be modified at any time. If a test has already runs, a crucial modification of the test would mean that test information belonging to these runs is lost, and thus the run is not reproducible anymore. To avoid this, a new version is created automatically.

測試腳本和呼叫可能在不論什么時候都能夠被改動。

假設個測試腳本已經執行了。改動測試腳本著屬于這些執行的測試信息丟失,從而執行不再重現了。為了避免這樣的情況,會自己主動創建一個新的版本號。

Simply switch between the versions of a test by clicking the version numbers. A version can even be deleted by using the?remove this version?link, but then all its runs are lost too.

通過點擊版本號號能夠實現兩個版本號的簡單切換。以致能夠用?remove this version鏈接來刪除一個版本號。但這樣關這個版本號的測試消息也會刪除。

3.8Duplicate a test(復制一個測試腳本)

If a test is duplicated using the?duplicate test?link, the currently displayed version of the test is copied into version 1 of the duplicate. The new name of the duplicate is composed with the original name followed by the word?copy. A duplicate initially has no runs.

假設duplicate test鏈接復制了一個測試腳本,當前顯示的測試版本號被復制到副本的版本號1中原來的名稱加上單詞copy顯示副本的名稱。副本初始化不會執行

3.9System information(系統信息)

In the?System information?tab, the page is split in 3 areas. First a list of currently running SIPp instances is displayed. Then the available free disk space is stated. Finally there is a list with the versions of SIPp that are defined in the?config.ini.php?file, along with their verbose screens.

System information標簽分成了3個區域。currently running SIPp instances顯示在第一個。然后規定可用的磁盤空間。

最后的個列表顯示了在?config.ini.php文件中定義的SIPp版本號號,連同他們的具體的屏幕。

3.10Kill a hanging SIPp instance(殺死一個掛起的SIPp實例)

An admin can try to kill an instance of SIPp by pressing the corresponding red?X?button in the list of currently running SIPp instances. Although SIPp runs that are not started through the web frontend are also in the list, they cannot be killed.

當前執行的SIPp列表通過點擊紅色?X??????button來殺一個SIPp實例是從web頁面執行的SIPp實例,在web頁面不能殺死。

3.11Config file(配置文件)

A line in the config file with a leading ; is a comment and has no effect to the configuration.

配置文件的開頭部分是一個描寫敘述會影響到配置

The configuration file is divided in three sections respectively tagged with
[EXECUTABLES], [AVP], and [CONFIG].

配置文件被分成三部分,分別用[EXECUTABLES], [AVP][CONFIG]標記

?

·In the?[EXECUTABLES]-section SIPp executables and their versions can be specified. At least one executable is mandatory.

[EXECUTABLES]部分是SIPp運行文件,能夠指定運行實例。

當中至少有一個SIPp可運行文件。

·In the?[AVP]-section global command line parameters for SIPp can be specified in form of attribute-value pairs (attribute = value).?

[AVP]部分以屬性-值對的形式(屬性=值)指定SIPP全局命令行參數。

I.e. most parameters of SIPp (without the leading -) will be accepted (see?sipp -h?for more details).

比如,接受SIPp(參數中沒有-)大多數參數(用命令“sip -h”獲得很多其它信息)

These parameters can be overwritten in each individual call by using the?Extended parameters?textarea in the web tool. Take care that you only use parameters that work with every version of SIPp you are using with this tool. If a attribute has no value, but is a switch, use TRUE as a value (e.g.,?aa = TRUE). If a value contains non-alphanumeric characters it needs to be enclosed in double-quotes (").

web通過用Extended parameters?文本每一個獨立的呼叫中重寫這些參數。注意僅能在正在用的SIPp的版本號用這個參數(也就是說版本號中有命令才干用。畢竟每一個SIPp的版本號功能不一樣,新的版本號功能比較多一些嘛),除非是一個開,用TRUE作為一個值(比如,aa = TRUE)假設值包括非字母數字的字符須要用雙引號(")起來

Parameters not allowed are:?參數不同意是:
i, m, nd, nr, t, p, r, timeout, pause_msg_ign, v, bind_local, inf, sd, sf, sn, stf, trace_msg, trace_shortmsg, trace_screen, trace_err, linebreak trace_timeout, trace_stat, trace_rtt, trace_logs

·In the?[CONFIG]-section you will find program specific parameters, like admin password or MySQL-database connection information...

[CONFIG]部分你會程序指定參數。如管理password或MYSQL-database連接信息……

Refer to the config file?config.ini.php?to get more detailed information about the specific parameters.

關于指定參數請參數配置文件里的config.ini.php獲得很多其它具體信息。

4User guide(用戶向導)

4.1Manage tests(管理測試腳本)

There is a list of available tests in the?Manage tests. If there are many tests, it may be useful to sort the tests by clicking one of the column headings.

Manage tests中是測試腳本列表

假設有非常多測試腳本,通過點擊頭能夠自己主動分類。

4.2Run a test(執行一個測試腳本)

Click on a test to get a more detailed view. There choose a version and click on the?run this version?link to open the test popup.

一個測試項中點擊。會得到一個具體的界面。

選擇個版本號點擊run this version鏈接彈出測試頁面。

Click on?Run test now?to begin testing. Both parties start to process their queues. On the left hand side of each call there is a small image showing the actual state of the call.

Run test now單擊開始進行測試。兩方開始處理隊列。在個呼叫的左手一個小圖像顯示呼叫的實際狀態。

4.3Key commands(keyword命令)

If monitoring is turned on, the test progress can be influenced by using key commands (this is the same as in the command line). First set the focus to the corresponding monitoring screen by clicking on it. When the border of the screen turns red, use the key commands on your keyboard.

假設打開了監控。keyword命令影響測試進展(用命令行測試也一樣會影響)。首先通過點擊keyword命令設置焦點到對應的監視屏幕屏幕的邊界變為紅色,使用你的鍵盤鍵入命令

·0-9?to switch between screens

0-9?切換屏幕

·+ , - , * , /?to adjust packet rate

+ , - , * , /?調整包速率

·q?to soft exit

q軟退出

·p?to pause/resume execution

p暫停/恢復運行

4.4Abort a call / test(停止一個呼叫/測試

Never close the test window without the test finished, because there may reside SIPp processes running on the server. If for some reason a call does not terminate by itself, there are three possibilities to finish the test anyway:

僅僅有測試完畢后才會關閉測試窗體,因在服務中可能駐留SIPp進程。假設因為原因一個呼叫沒有自己掛斷,完畢這個測試有三種可能:

·If the call has monitoring turned on, try to end the call with the key command?q?(soft exit).

假設打開了監控功能。試試用軟命令q鍵退出(退出)

·A call that hangs can be terminated by pressing the red?X?on its right hand side.

通過點擊右側紅色?X?button結束掛起的呼叫

·The whole test can be stopped with the?Abort test?link at the top of the window.

點擊接窗體頂部的Abort test鏈接來停止結束測試

4.5Runs(執行

After a test has finished, the test window is closed automatically and the created run is displayed. The?exit?and the?std error?column may contain important information (roll the mouse over the columns for more details in a tooltip box). Click the grey eye buttons to download the log files created during the test.

測試完畢后,測試窗體自己主動關閉創建執行過程中的顯示參數。列exit和std error或許包括重要的信息(懸浮框中滾動鼠標軸獲得具體信息)。點擊灰色眼睛button來下載在過程中創建的日志文件。

It is possible to return to this page, or to another run, any time. Just navigate to the corresponding test in the?Manage tests?tab, choose the right version and click on a run at the bottom of the page.

可能會返回這個頁面。或返回至還有一個執行頁面,Manage tests選項卡中導航到對應的測試中就可以,選擇一正確的版本號并在頁面底部點擊就可以執行。

5Programming guide(程序設計說明)

5.1Database (ER Diagram)(數據庫(ER圖表))

5.2Files(文件

·add_call.php?is responsible for the?add/modify call?screen. Adds/modifies calls in the database.

·add_call.php屏幕中代表add/modify call?。在數據庫中代表Adds/modifies?呼叫

·authentication.php: checks if admin is logged in. It is included everywhere, where admin should have special permissions.

authentication.php:選擇是否admin登錄。它包括了admin訪問權限的不論什么地方。

·Call_Data.php: class Call_Data: contains call specific data (process-id, log filenames...) of a currently running call. It has methods to store log files in the database, delete the log files and determine the exit code after execution. When a call is about to be executed, an object of this class is generated and stored in a session variable.

Call_Data.php:Call_Data包括一個當前執行呼叫中調用指定的數據(process-id, log filenames...)

把日志文件存儲到數據庫刪除日志文件和決定運行完后退出的代碼。當運行一個呼叫時,生成這個類的一個對象并保存一個會話變量

·config.ini.php: configuration file

config.ini.php:配置文件

·create_run.php: is called from run_progress.php via ajax. It creates a run in the database with the current timestamp.

create_run.php:通過ajaxrun_progress.php調用。數據庫中創建一個執行的當前時間戳。

·dbHelper.php: is where the SQL happens. For each table in the database, there is a corresponding class that handles database communication.

dbHelper.php:?SQL處理的地方,對數據庫中的每一個表來說。有一個對應的類處理數據庫通信

·db.php: generates the MySQL database connection object.

db.php:生成MySQL數據連接對象

·exec_call.php: is called from?run_progress.php?via ajax. The basic function of this file is to build up the command line, create the XML-scenario file and the CSV-injection file in the system's temporary folder, execute the call and return its process id (pid).

exec_call.php:通過ajax從run_progress.php調用

這個文件基本功能是構造命令行,系統的暫時目錄中創建XML場景文件和CSV注入文件運行呼叫并返回它的進程id(pid).

·garbagecollector.php: removes all SIPp directories in the system's temp folder that have not been modified for a specific time (defined in?config.ini.php). Further all SIPp processes older than a specific time get killed.

garbagecollector.php:?(暫不會翻譯)

·get_screen.php: During execution of a call this file is requested periodically via ajax. Here the actual monitor-screen is extracted from the screen file, and returned to?status_screen.php?(if monitoring is turned on). Further this file checks if the SIPp process is still running, and if not, it returns exit-code and standard-error tostatus_screen.php.

get_screen.php:在執行呼叫期間,通過ajax個文件會周期的向server進行請求。實際上是從screen文件里導出監控屏幕將結束輸入至?status_screen.php(假設打開了監控功能)

進一步講。這個文件檢查SIPp進程是否仍在執行假設沒有。tostatus_screen.php返回的退出代碼和標準錯誤

·helper.php: just some useful functions.

helper.php:是一實用的功能說明

·index.php: redirect to?tests.php.

index.php:定向到test.php

·info.php: represents the?System information?tab.

info.php:代表System information標簽

·kill_process.php: is called from?run_progress.php?via ajax, if the user wants to kill a SIPp process.

kill_process.php:?假設用戶想殺死SIPp進程。會通過ajax從run_progress.php調用此文件

·read_config.php: reads the config file in the three arrays?$executables, $avp,?and?$config. Default values are set if necessary, and there is a function?getConfig-Parameters?that assembles command line parameters from the?AVP?section.

read_config.php:$executables, $avp,?$config讀取配置文件。

假設有必要能夠設置默認值。有一個得到配置參數(getConfig-Parameters)功能AVP部分中收命令行參數。

·run_detail.php: represents the?show run?page.

run_detail.php:代表show run頁面

·run_progress.php: represents the?run test?popup. This is where all the ajax happens. Refer to the file itself for detailed information.

run_progress.php:代表run test?彈出窗。這是全部ajax執行的地方,參考此文件獲得至多信息

·scenario_detail.php: represents the?create/modify scenario?screen. Inserts or updates scenario data in the database.

scenario_detail.php:代表create/modify scenario屏幕,在數據庫中插入或場景數據。

·scenarios.php: represents the?Manage scenarios?tab.

scenarios.php:代表Manage scenarios?標簽

·send_key.php: is called via ajax from?status_screen.php?when the user presses a key on the keyboard.

send_key.php:當用戶在鍵盤中按下一個鍵時,?status_screen.php?通過ajax調用send_key.php

·status_screen.php: is displayed in a iframe in?run_progress.php?during test. Here the status monitor screen of a running SIPp instance is displayed by polling it from the server frequently. Further, keyboard action is sent to?send_key.php, that forwards it to the running SIPp instance.

status_screen.php:測試過程中一個內框架中顯示?run_progress.php?。會從server頻繁地輪循顯示執行SIPp實例的監控屏幕狀態。進一步講,鍵盤的動作發send_key.php,驅動它來執行SIPp實例

·stop_sipp.php: has a function that tries to stop a running SIPp instance. It takes care that the pid belongs to a SIPp process.

stop_sipp.php:嘗試停止一個執行的SIPp實例它負責pid屬于一個SIP進程

·sys_get_temp_dir.php: provides functions that determine the working directory and the systems temp directory.

sys_get_temp_dir.php:提供限定工作文件夾和系統時時文件夾

·test_detail.php: represents the?create/modify test?screen.

test_detail.php:代表create/modify test?屏幕

·tests.php: represents the?Manage tests?tab.

tests.php:代表Manage tests?標簽頁。

·view_csv.php: is for downloading CSV files (log files etc.) that are stored in the database.

view_csv.php:下載保存在數據庫中CSV文件(日志文件

·view_messages.php: is for downloading the file created by the command line option?-trace_messages. The trace_messages file is not stored in the database because it may be very large, but it is left for a short time in the systems temp folder until the garbage collector removes it.

view_messages.php:下載通過命令行?-trace_messages選項創建的文件trace_messages文件不會存到數據庫中,為它或許大,可是系統暫時目錄中一直保留。除非到達垃圾設置值才會刪除。

·view_text.php: is for downloading text files (log files etc.) that are stored in the database.

view_text.php:下載存在數據庫中的txt文件日志文件等)

·view_xml.php: is for downloading XML files (scenario files) that are stored in the database.

view_xml.php:?下載存在數據庫中的XML文件場景文件)

·/js/ajaxConnection.js: crossbrowser function to create an ajax request object in javascript.

/js/ajaxConnection.js:javascript跨瀏覽器函數來創建一個ajax的請求對象

·/js/helper.js: some useful javascript functions.

/js/helper.js:些實用的javascript函數。

·/js/run.js: opens a window for a test run.

/js/run.js:測試執行打開一個窗體

·/js/tooltip.js: provides functions to display tooltip texts.

/js/tooltip.js:提供函數來顯示工具提示文

·/navigation/pagehead.php: If you want to add a new tab to the navigation, do it here.

/navigation/pagehead.php:假設你想導航欄中加入一個新的標簽在這里進行操作。

·/navigation/register.php: Here the navigation of the webfrontend is created.

/navigation/register.php:創建webfrontend導航欄

5.3Command flow during test process(測試過程中的命令流)

by?Mario SMERITSCHNIG [code/documentation]

?Mario SMERITSCHNIG【代碼/文檔

?

?

?

?

網上找了一個安裝文檔地址是:

http://opensource.telkomspeedy.com/wiki/index.php/VoIP_Cookbook:_Installation_of_SIPp_Webfrontend

?

?

拷貝?&提取

mkdir /var/www/sipp

cp sipp_webfrontend_v1.2.tgz /var/www/sipp/

cd /var/www/sipp/

tar zxvf sipp_webfrontend_v1.2.tgz

mv /var/www/sipp/src/* /var/www/sipp/

創建數據

mysql -u root -p

password:

CREATE DATABASE SIPpDB;

USE SIPpDB;

\. /var/www/sipp/tables.sql

quit

編輯config.ini.php

vi /var/www/sipp/config.ini.php

[EXECUTABLES]

3.0 = "/usr/bin/sipp"

?

[CONFIG]

db_host = "localhost"

db_user = "root"

db_pwd = "123456"

db_name = "SIPpDB"

admin_pwd = ""

?

了更加easy訪問網頁,清空admin_pwd字段能夠通過

http://localhost/sipp

訪問SIPp Webfrontend?。用

username admin

password <no password>

?

轉載于:https://www.cnblogs.com/clnchanpin/p/7052450.html

總結

以上是生活随笔為你收集整理的SIPp web frontend(2)的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。