SIP服務器主/備份冗餘和配置簡介

介紹

主用和備用SIP伺服器

SIP伺服器冗餘機制確保了SIP服務的可靠性和連續性。主/備用伺服器部署是這些冗餘方法之一。主用和備用伺服器共享用戶帳戶、對話資訊(取決於伺服器冗餘實現方式)、註冊資訊和其他相關資料。在正常條件下,所有SIP請求和回應都由主伺服器處理。當主伺服器發生故障、正在維護或無法訪問時,SIP終端會自動切換到備用伺服器進行服務請求,確保用戶連續訪問。一旦主伺服器恢復,SIP終端可以自動切換回主伺服器。

SIP伺服器主備
                                                                            圖1 SIP伺服器主備

術語

故障轉移:當主伺服器不可用時,備用伺服器接管所有服務而不影響用戶體驗的機制。
故障恢復:設備在備用伺服器提供服務時檢查主伺服器是否已恢復,從而能夠快速切換回主伺服器的機制。
伺服器不可用:當客戶端嘗試註冊時,伺服器回應500/503,或UDP收到ICMP目標不可達消息,或TCP連接超時。
註冊故障恢復:當主伺服器不可用且電話註冊到備用伺服器時,電話創建一個新的註冊對話來檢測主伺服器是否已恢復。此功能具有獨立且可配置的探測間隔。

目標受眾

本文檔適用於電話用戶和維護人員。

主用和備用伺服器

功能設定

在電話上為SIP線路配置兩個伺服器條目。SIP伺服器1是主伺服器,SIP伺服器2是備用伺服器。

故障轉移

電話目前支援Register、Invite和Bye的信令故障轉移。其他信令方式暫不支援。

1. 註冊故障轉移

觸發條件:手動註冊 / 註冊超時 / OPTIONS超時 / CANCEL請求超時
(1) 電話向主伺服器發送Register請求;
(2) 電話嘗試向主伺服器發送Register請求指定次數(V3產品)或在指定時間內(V2產品);
(3) 如果主伺服器不可用,電話向備用伺服器發送Register請求;
(4) 備用伺服器回應200 OK,電話註冊成功。
2. Invite故障轉移
觸發條件:用戶撥打電話
(1) 電話A呼叫電話B;
(2) 電話A向主伺服器發送Invite請求;
(3) 電話A嘗試向主伺服器發送Invite請求指定次數(V3產品)或在指定時間內(V2產品);
(4) 如果主伺服器不可用,電話向備用伺服器發送Register請求;
(5) 備用伺服器回應200 OK,電話成功註冊到備用伺服器;
(6) 電話向備用伺服器發送Invite請求;
(7) 備用伺服器回應200 OK,電話A和B之間建立通話。
3. Bye故障轉移
觸發條件:通過主伺服器建立通話後,電話掛斷
(1) 電話A通過主伺服器與電話B建立通話;
(2) 電話A掛斷;
(3) 電話A向主伺服器發送Bye請求;
(4) 電話A嘗試向主伺服器發送Bye請求指定次數(V3產品)或在指定時間內(V2產品);
(5) 如果主伺服器不可用,電話向備用伺服器發送Register請求;
(6) 備用伺服器回應200 OK,電話成功註冊到備用伺服器;
(7) 電話向備用伺服器發送Bye消息;
(8) 備用伺服器回應200 OK,與電話B的通話終止。
4. 故障轉移失敗
當所有伺服器都不可用時,電話按照主/備優先級依次嘗試每個伺服器指定次數(V3產品)或在指定時間內(V2產品)。最後一個伺服器作為異常處理。根據RFC 3261,SIP將重試64*T1(32秒)。如果當前SIP信令請求仍然失敗,則向用戶報告失敗。

故障恢復

電話支援獨立的註冊故障恢復。電話成功註冊到備用伺服器後,會定期向主伺服器發送獨立的Register請求,以檢測主伺服器是否已恢復。
觸發條件:註冊故障恢復計時器超時。
(1) 電話成功註冊到備用伺服器;
(2) 當註冊故障恢復超時時,電話向主伺服器發送獨立的Register請求;
(3) 如果主伺服器回應200 OK,電話切換回主伺服器;
(4) 如果主伺服器仍然不可用,Register請求根據RFC 3261重傳,直到64*T1(32秒)超時。超時後,計時器重新啟動,並繼續定期探測主伺服器。

SIP伺服器主備配置

配置項說明

                配置項                 說明                 值
                SIPN Register Addr:                 主伺服器地址。 IP / 域名 預設:空
                SIPN Register Port:                 主伺服器端口。 數字 預設:5060
                SIPN Register TTL:                 主伺服器註冊間隔。 數字 預設:3600秒
                SIPN Transport:                 主伺服器傳輸協定:UDP、TCP或TLS。 0: UDP
1: TCP
3: TLS
預設:0
                SIPN Backup Addr:                 備用伺服器地址。 IP / 域名 預設:空
                SIPN Backup Port:                 備用伺服器端口。 數字 預設:5060
                SIPN Backup TTL:                 備用伺服器註冊間隔。 數字 預設:3600秒
                SIPN Backup Transport:                 備用伺服器傳輸協定:UDP、TCP或TLS。 0: UDP
1: TCP
3: TLS
預設:0
                SIPN Enable Failback:                 控制是否為該線路啟用註冊故障恢復。 0 / 1 預設:1
                SIPN Failback Interval:                 電話註冊到備用伺服器/代理後,探測主伺服器/代理是否已恢復的間隔。 數字 預設:1800秒
                SIPN Signal Retry Counts:                 當伺服器/代理不可用時,除最後一個伺服器/代理外(32秒超時)的SIP請求重傳次數。 數字 預設:3

用戶配置界面

用戶可以登錄電話的Web伺服器配置主用和備用伺服器。
(1) 點擊「線路」選項卡,選擇SIP子選項卡(這是預設頁面);
(2) 從頁面內的「線路」下拉清單中選擇要配置的線路;
(3) 配置線路註冊資訊;
(4) 配置SIP Server1(主伺服器)和SIP Server2(備用伺服器)資訊,如圖2所示;
(5) 點擊當前頁面上的「基本設定」配置主備伺服器的故障恢復相關設定,如圖3所示;
(6) 點擊頁面底部的「提交」按鈕應用配置。
SIP伺服器主備配置
                                                 圖2 SIP伺服器主備配置
故障恢復設定

目錄
客服 電話
We use cookie to improve your online experience. By continuing to browse this website, you agree to our use of cookie.

Cookies

This Cookie Policy explains how we use cookies and similar technologies when you access or use our website and related services. Please read this Policy together with our Terms and Conditions and Privacy Policy so that you understand how we collect, use, and protect information.

By continuing to access or use our Services, you acknowledge that cookies and similar technologies may be used as described in this Policy, subject to applicable law and your available choices.

Updates to This Cookie Policy

We may revise this Cookie Policy from time to time to reflect changes in legal requirements, technology, or our business practices. When we make updates, the revised version will be posted on this page and will become effective from the date of publication unless otherwise required by law.

Where required, we will provide additional notice or request your consent before applying material changes that affect your rights or choices.

What Are Cookies?

Cookies are small text files placed on your device when you visit a website or interact with certain online content. They help websites recognize your browser or device, remember your preferences, support essential functionality, and improve the overall user experience.

In this Cookie Policy, the term “cookies” also includes similar technologies such as pixels, tags, web beacons, and other tracking tools that perform comparable functions.

Why We Use Cookies

We use cookies to help our website function properly, remember user preferences, enhance website performance, understand how visitors interact with our pages, and support security, analytics, and marketing activities where permitted by law.

We use cookies to keep our website functional, secure, efficient, and more relevant to your browsing experience.

Categories of Cookies We Use

Strictly Necessary Cookies

These cookies are essential for the operation of the website and cannot be disabled in our systems where they are required to provide the service you request. They are typically set in response to actions such as setting privacy preferences, signing in, or submitting forms.

Without these cookies, certain parts of the website may not function correctly.

Functional Cookies

Functional cookies enable enhanced features and personalization, such as remembering your preferences, language settings, or previously selected options. These cookies may be set by us or by third-party providers whose services are integrated into our website.

If you disable these cookies, some services or features may not work as intended.

Performance and Analytics Cookies

These cookies help us understand how visitors use our website by collecting information such as traffic sources, page visits, navigation behavior, and general interaction patterns. In many cases, this information is aggregated and does not directly identify individual users.

We use this information to improve website performance, usability, and content relevance.

Targeting and Advertising Cookies

These cookies may be placed by our advertising or marketing partners to help deliver more relevant ads and measure the effectiveness of campaigns. They may use information about your browsing activity across different websites and services to build a profile of your interests.

These cookies generally do not store directly identifying personal information, but they may identify your browser or device.

First-Party and Third-Party Cookies

Some cookies are set directly by our website and are referred to as first-party cookies. Other cookies are set by third-party services, such as analytics providers, embedded content providers, or advertising partners, and are referred to as third-party cookies.

Third-party providers may use their own cookies in accordance with their own privacy and cookie policies.

Information Collected Through Cookies

Depending on the type of cookie used, the information collected may include browser type, device type, IP address, referring website, pages viewed, time spent on pages, clickstream behavior, and general usage patterns.

This information helps us maintain the website, improve performance, enhance security, and provide a better user experience.

Your Cookie Choices

You can control or disable cookies through your browser settings and, where available, through our cookie consent or preference management tools. Depending on your location, you may also have the right to accept or reject certain categories of cookies, especially those used for analytics, personalization, or advertising purposes.

Please note that blocking or deleting certain cookies may affect the availability, functionality, or performance of some parts of the website.

Restricting cookies may limit certain features and reduce the quality of your experience on the website.

Cookies in Mobile Applications

Where our mobile applications use cookie-like technologies, they are generally limited to those required for core functionality, security, and service delivery. Disabling these essential technologies may affect the normal operation of the application.

We do not use essential mobile application cookies to store unnecessary personal information.

How to Manage Cookies

Most web browsers allow you to manage cookies through browser settings. You can usually choose to block, delete, or receive alerts before cookies are stored. Because browser controls vary, please refer to your browser provider’s support documentation for details on how to manage cookie settings.

Contact Us

If you have any questions about this Cookie Policy or our use of cookies and similar technologies, please contact us at support@becke.cc .