本帖最後由 角色 於 2015-7-1 01:10 編輯
Workshop 8: Installation of HKBN 2b App for both outbound and inbound calls
With the following information, any HK PSNT number can be ported to HKBN 2b App account as shown in in the following link:http://www.telecom-cafe.com/foru ... &extra=page%3D1
With suitable arrangement your telephone number starting from the digit "2" can be easily ported to HKBN 2b App. The procedure of settings up HKBN 2b App are
Let us assume the followings:
HKBN 2b App number = 31234567
Password = pass
Step 1: Adding the following lines to your sip.con
sip.conf- [general]
- .
- .
- .
- register => 31234567hk:pass@s2hkbntel.net:5060/31234567
- ;The above register string should be placed just after the context "general" and before the next context.
- [hkbn2b]
- type=peer
- username=31234567hk
- secret=pass
- port=5060
- host=s2hkbntel.net
- fromuser=31234567hk
- fromdomain=s2hkbntel.net
- nat=force_rport,comedia
- canreinvite=no
- canredirect = no
- insecure=port,invite
- dtmfmode=auto
- context=from-hkbn2b
複製代碼 Step 2: Adding the following dial plan to your extensions.conf- ;00852 using the hkbn2b trunk
- exten => _00852.,1,Dial(SIP/${EXTEN:5}@hkbn2b,,)
- exten => _00852.,n,Hangup()
- [from-hkbn2b]
- exten => 31234567,1,Dial(SIP/3104,,r)
- exten => 31234567,n,Hangup()
複製代碼 Step 3: Adding IP address for hostnames in /etc/hosts- 203.80.89.135 s2hkbntel.net s21hkbntel.net
複製代碼 If the above IP address to hostnames do not work, please use the following- 203.80.89.139 s2hkbntel.net s22.hkbntel.net
複製代碼 You need to update the new settings in sip.con accordingly.
If the above does not work, there is another set of parameters to be used as follows
sip.conf- register => 31234567hk:pass@s2hkbntel.net:5060/31234567hk
- [hkbn2b]
- type=peer
- username=31234567hk
- secret=pass
- port=5060
- host=s2hkbntel.net
- fromuser=31234567hk
- fromdomain=s2hkbntel.net
- nat=force_rport,comedia
- canreinvite=no
- canredirect = no
- insecure=port,invite
- qualify=yes
- dtmfmode=auto
- context=from-hkbn2b
複製代碼 extensions.conf- exten => _9.,1,Dial(SIP/${EXTEN:1}@hkbn2b,,)
- exten => _9.,n,Hangup()
- exten => 3101,1,Dial(SIP/3101,,r)
- exten => 3102,1,Dial(SIP/3102,,r)
- [from-hkbn2b]
- exten => 31234567hk,1,Dial(SIP/3101,,r)
- exten => 31234567hk,n,Hangup()
複製代碼 |