2025년 9월 11일 목요일

[ASTERISK] 02 실행확인

core show version

core show uptime

core show channels

pjsip show endpoints

pjsip show registrations

dialplan show

dialplan show internal

core set verbose 3


[pjsip.conf]
[transport-udp]
type=transport
protocol=udp
bind=0.0.0.0:5060

; ===== 내선 1000 =====
[1000]
type=endpoint
transport=transport-udp
context=internal
disallow=all
allow=ulaw
auth=1000-auth
aors=1000

[1000-auth]
type=auth
auth_type=userpass
username=1000
password=1000pass

[1000]
type=aor
max_contacts=1

; ===== 내선 2000 =====
[2000]
type=endpoint
transport=transport-udp
context=internal
disallow=all
allow=ulaw
auth=2000-auth
aors=2000

[2000-auth]
type=auth
auth_type=userpass
username=2000
password=2000pass

[2000]
type=aor
max_contacts=1


[extensions.conf]
[internal]
; 1000 ↔ 2000 서로 전화
exten => 1000,1,NoOp(Call to 1000)
 same => n,Dial(PJSIP/1000,20)
 same => n,Voicemail(1000@default,u)
 same => n,Hangup()

exten => 2000,1,NoOp(Call to 2000)
 same => n,Dial(PJSIP/2000,20)
 same => n,Voicemail(2000@default,u)
 same => n,Hangup()

; 에코 테스트(오디오/네트워크 확인용)
exten => 600,1,Answer()
 same => n,Echo()
 same => n,Hangup()

위 파일 복사( /etc/asterisk/ ) 후 실행 확인
asterisk -rvvv
core set verbose 3
pjsip reload
dialplan reload
pjsip show endpoints      ; 1000, 2000 보이는지 확인
pjsip show contacts       ; 소프트폰 등록되면 접속 주소가 뜸

linphone 설치

ID : 1000
PW : 1000pass

IP주소:5060
프로토콜 : UDP

ID : 2000
PW : 2000pass

접속 후 1000 <-> 2000 서로 전화걸기


댓글 없음:

댓글 쓰기