Asterisk

手機不會在 Asterisk 伺服器上註冊

  • April 12, 2016

我正在嘗試在我們的星號伺服器上註冊 Grandstream 電話。我們已經這樣做了幾十次,已經記錄瞭如何做到這一點,最近它不再起作用了……我已經嘗試了幾部手機 - 他們都拒絕了。已安裝的電話可以正常工作並重新啟動。

Asterisk 安裝在需要遷移到新伺服器的舊伺服器上,同時更新 Asterisk 1.4。現在它是舊伺服器。

對於 Grandstream 手機,我們使用一個腳本來生成一個由手機下載的配置文件。Apache 日誌顯示此文件已下載。電話連接到網路,獲取 IP 地址,下載配置文件,並在摘機時顯示正確的電話號碼。

在 sip.conf 中配置了電話,重新載入了 sip 和撥號方案。

配置文件是從另一台伺服器(網路伺服器)下載的。此伺服器已更新,應執行生成配置文件的腳本。這在此伺服器上不再起作用。在舊的星號伺服器上,腳本確實執行。當我們在那裡執行它時,它會生成文件。我們將其複製到另一台伺服器,在那裡它被手機下載和使用,顯示更新的配置,如不同的電話號碼。

因此,這似乎可行,只是電話無法註冊。

任何想法可能是什麼問題?


更新

在將詳細和調試級別設置為 5 後的輸出下方asterisk -r。我桌子上的電話在顯示屏上有 IP 地址 192.168.1.35,但我在日誌中的任何地方都看不到。

asterisk01*CLI> core set verbose 5
Verbosity was 3 and is now 5
asterisk01*CLI> core set debug 5
Core debug was 0 and is now 5
Really destroying SIP dialog '52b8582e7218fed92bdd58db35ac477e@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '0e7e9d1034abcebd6949e1cb459d87a3@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '76a6eb0a37efaec065d5a9d04a113bf7@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '47a09781040504e214255c8b4e180422@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '51dcc8d92495210716ae1fe0428b78bb@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '10d552824581213f2ecb030b74688aae@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '7b18bd6b203a44d351f702a725a8a7dc@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '23cb9717004156f26da28d9f5de60193@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '270f864b04225b3c73a1bac0558ffe70@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '211c62621704df0e4015002254b88116@100.1.2.3' Method: REGISTER
Really destroying SIP dialog '27d3e1c93e8201a9010d7a6579453a9f@100.1.2.3' Method: OPTIONS
asterisk01*CLI> module reload logger
 == Parsing '/etc/asterisk/logger.conf': Found
Asterisk Event Logger restarted
Asterisk Queue Logger restarted
Really destroying SIP dialog '935f319873f8b64c@192.168.1.26' Method: REGISTER
Really destroying SIP dialog '0867da6333ffd1f33fe0a03a33fe19cb@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '0afcaa63507dcba27f48cead73b1595c@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '2d695efc77d1123d280e6f4f225d0858@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '4fa21bed44ecff1c01d879cc42c8f95e@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '1e2612cd082d70286677dc2175bc424b@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '2daf9dafe3e68588@192.168.1.12' Method: SUBSCRIBE
Really destroying SIP dialog 'ba642c4b669c2138@192.168.0.100' Method: REGISTER
Really destroying SIP dialog '1ae57b0b6cabe2dd@192.168.1.12' Method: SUBSCRIBE
Really destroying SIP dialog '14ddfaf63647f28a@192.168.1.11' Method: REGISTER
Really destroying SIP dialog '779c270421e56b02@192.168.1.14' Method: REGISTER
[2016-03-15 09:40:32] NOTICE[22537]: chan_sip.c:7392 sip_reregister:    -- Re-registration for  127500001@bd.abcvoip.test
   -- ast_get_srv: SRV lookup for '_sip._udp.bd.abcvoip.test' mapped to host sipproxy.tc2.bd.abcvoipsrv.test, port 5060
REGISTER attempt 1 to 127500001@bd.abcvoip.test
REGISTER attempt 2 to 127500001@bd.abcvoip.test
[2016-03-15 09:40:32] NOTICE[22537]: chan_sip.c:12475 handle_response_register: Outbound Registration: Expiry for bd.abcvoip.test is 120 sec (Scheduling reregistration in 105 s)
[2016-03-15 09:40:32] NOTICE[22537]: chan_sip.c:7392 sip_reregister:    -- Re-registration for  126950001@bd.abcvoip.test
   -- ast_get_srv: SRV lookup for '_sip._udp.bd.abcvoip.test' mapped to host sipproxy.sig.bd.abcvoipsrv.test, port 6060
REGISTER attempt 1 to 126950001@bd.abcvoip.test
REGISTER attempt 2 to 126950001@bd.abcvoip.test
[2016-03-15 09:40:32] NOTICE[22537]: chan_sip.c:12475 handle_response_register: Outbound Registration: Expiry for bd.abcvoip.test is 120 sec (Scheduling reregistration in 105 s)
Really destroying SIP dialog '37df2740a103c2f1@192.168.1.24' Method: REGISTER
Really destroying SIP dialog '758fa91f28f0f36f@192.168.1.23' Method: REGISTER
Really destroying SIP dialog '5529bbf1f7f1b5e4@192.168.1.12' Method: REGISTER
Really destroying SIP dialog '208c036d74daffd9@192.168.1.36' Method: REGISTER
Really destroying SIP dialog 'fb772e776bc9b6a8@192.168.2.1' Method: REGISTER
Really destroying SIP dialog 'ZDEyMzJjY2E1Nzk2NTY2YzUyY2M2MGVkZWExNzQ1NGU' Method: REGISTER
Really destroying SIP dialog 'b21ca35c2fdeb8fd@192.168.1.14' Method: REGISTER
Really destroying SIP dialog '61d66fac6776922f735e88ef22ed60a2@100.1.2.3' Method: OPTIONS
 == Parsing '/etc/asterisk/manager.conf': Found
 == Manager 'fpbphp' logged on from 54.228.185.179
Really destroying SIP dialog '2408998e33792f6c270090d467815e14@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '547cc0ec0fbda2e5390aae74710b6e94@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '5e477bd31d699ba5655d340b4733a3b7@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '007e36387d264ea7233a65134742fea1@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '11343658319afdbf717d368d36c5722e@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '53a7e8e91dcc9b98596172c62dde33b3@100.1.2.3' Method: OPTIONS
      > Channel SIP/511-090f9bf0 was answered.
 == Manager 'fpbphp' logged off from 54.228.185.179
   -- Executing [0034123456789@office:1] Goto("SIP/511-090f9bf0", "office-out|0034123456789|1") in new stack
   -- Goto (office-out,0034123456789,1)
   -- Executing [0034123456789@office-out:1] Set("SIP/511-090f9bf0", "CLID=") in new stack
   -- Executing [0034123456789@office-out:2] Set("SIP/511-090f9bf0", "CALLERID(number)=") in new stack
   -- Executing [0034123456789@office-out:3] NoOp("SIP/511-090f9bf0", "") in new stack
   -- Executing [0034123456789@office-out:4] GotoIf("SIP/511-090f9bf0", "0?dial") in new stack
   -- Executing [0034123456789@office-out:5] Set("SIP/511-090f9bf0", "CALLERID(number)=+34123456789") in new stack
Really destroying SIP dialog '68ffbaaa3042b94b2afee7594cbba63b@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '7ed096356886d08d79bb06e52b5604a4@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '3b9593e2411217415008dfd435814f1c@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '62ac88ea31b11bc7760492470b2c39b6@100.1.2.3' Method: REGISTER
Really destroying SIP dialog '5f271031175a10f53643447a25a5a80f@100.1.2.3' Method: REGISTER
Really destroying SIP dialog '2a04fa5b57e32e0e157f04a60c2589b3@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '1edf7b2d45aa7f1f233f79be5f1bf030@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '935f319873f8b64c@192.168.1.26' Method: REGISTER
Really destroying SIP dialog '2c8a83c56b3457e969a4462a65606ea2@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '22dc609d75e59e63057a64de180f7cb1@100.1.2.3' Method: OPTIONS
Really destroying SIP dialog '6c598605092cc1365cc56e96047da86e@100.1.2.3' Method: OPTIONS

在安裝舊的 java 版本後,我設法讓編譯腳本再次工作。我不明白它與其他伺服器有何不同,因為此腳本是在網路伺服器上創建的,而不是星號伺服器,並且只是手機的配置文件。無論如何,它有效,這才是最重要的!

引用自:https://serverfault.com/questions/763666