Reliable Scalable and Interoperable Internet Telephony by Kundan
Reliable, Scalable and Interoperable Internet Telephony by Kundan Singh Advisor: Henning Schulzrinne Computer Science Department, Columbia University, New York Oct 12, 2007, Job Talk at FXPAL
My research background/timeline rans 23 t bia t lien 23 c H. 3 way gate olum cs. c 20072 2006 2005 2004 2003 2002 2001 Relia bility e scala r u t ruc t s a infr P I Vo ion luat eva nce fere Con SIP ing P us Vo. I P 2 P ng hari ad s r/lo ove Fail tion SIP bora colla dia ce time erfa Mul r int use AT EMA CIN ile N Mob nse spo e re e voic ctur ive stru ract nfra Inte IP i g o ncin ) se V fere rary rpri n b i o l c Ente l SIP (SIP mai + ip+ oice Libs RTSP v r lato SIP @ Ph. D ia b m olu ility & cs. c b -H. 3 SIP MS@ rk@ d o a r W la erg Und a Motoro Indi @1997 1999 2000 k@ Wor bs, La Bell be Ado
Outline of the presentation Introduction n n Server redundancy n n Load sharing and failover in SIP telephony Peer-to-peer (P 2 P) n n P 2 P telephony using SIP Enterprise IP telephony n n n What is the problem? Why important? Multi-platform collaboration using SIP Scalable centralized conferencing architecture Other interesting projects Conclusion 3
Telephone reliability & scalability (PSTN: Public Switched Telephone Network) database (SCP) for freephone, calling card, … signaling network (SS 7) local telephone switch (class 5 switch) signaling router 10, 000 customers (STP) 20, 000 calls/hour regional telephone switch (class 4 switch) 100, 000 customers 150, 000 calls/hour “bearer” network database (SCP) 10 million customers 2 million lookups/hour signaling router (STP) 1 million customers 1. 5 million calls/hour telephone switch (SSP) Switches strive for 99. 999% availability. Lucent’s 5 E-XC supports 4 million BHCA. 4
Internet telephony (SIP: Session Initiation Protocol) alice@yahoo. com example. com INVITE REGISTER INVITE 129. 1. 2. 3 bob@example. com 192. 1. 2. 4 DB DNS Can SIP server provide carrier grade reliability and scalability using commodity hardware 5
What are the problems? n Can SIP server provide carrier-grade reliability and scalability using commodity hardware? n n How can we build a server-less self-organizing peer-to-peer Vo. IP network? n n What affects the server performance? Can this be done in standards compliant way? Can communication be extended to multiplatform collaboration using existing protocols? n How well multi-party conferencing scales? 6
Outline of the presentation Introduction n n Server redundancy n n Load sharing and failover in SIP telephony Peer-to-peer (P 2 P) n n P 2 P telephony using SIP Enterprise IP telephony n n n What is the problem? Why important? Multi-platform collaboration using SIP Scalable centralized conferencing architecture Other interesting projects Conclusion 7
High availability Failover implementation and analysis Web scripts D 1 Master/ slave P 1 phone. cs. columbia. edu _sip. _udp SRV 0 0 5060 phone. cs. columbia. edu SRV 1 0 5060 sip 2. cs. columbia. edu Web scripts replication D 2 Slave/ master P 2 sip 2. cs. columbia. edu REGISTER proxy 1 = phone. cs backup = sip 2. cs 8
Scalability Comparison of the two designs P 1 a-h D 1 P 2 i-q D 2 P 3 D 2 r-z Low Scalability High Reliability D 2 High Scalability Low Reliability 9
Scalability (and reliability) Two stage architecture I stage II stage a*@example. com a 1 s 1 Master a 2 Slave a. example. com _sip. _udp SRV 0 0 a 1. example. com SRV 1 0 a 2. example. com sip: bob@example. com s 2 sip: bob@b. example. com b*@example. com s 3 ex example. com _sip. _udp SRV 0 40 s 1. example. com SRV 0 40 s 2. example. com SRV 0 20 s 3. example. com SRV 1 0 ex. backup. com b 1 Master b 2 Slave b. example. com _sip. _udp SRV 0 0 b 1. example. com SRV 1 0 b 2. example. com Capacity = f(#stateless, #groups) 10
Load Sharing Performance result: calls/second n n Using 3+3 servers gives carrier-grade performance (10 million busy hour call attempts) Registration test: supports 10 million subscribers On commodity hardware: 3 GHz, Pentium 4, 1 GB memory Test with UDP, stateless, no DNS and no mempool 11
Server performance What happens inside a server? What thread/event models possible? Web server recv accept SIP server stateful Response recvfrom parse Request File read send Match transaction Modify response Stateless proxy Found Match transaction Update DB REGISTER other Redirect/reject Lookup DB Stateless proxy 1. 2. 3. 4. (Blocking) I/O Critical section (lock) Critical section (r/w lock) Pure event-based (one thread) Thread-per-msg or transaction Pool-thread per msg (sipd) Two stage thread pool sendto Build response Proxy Modify Request DNS 12
Problem with servers C C S C n Server-based n C n P P P n Cost: maintenance, configuration Central points of failures, catastrophic failures Controlled infrastructure (e. g. , DNS) Peer-to-peer n n n Robust: no central dependency Self organizing, no configuration Inherent scalability 13
We built: P 2 P-SIP n Unlike proprietary Skype architecture n n Robust and efficient lookup using DHT Interoperability n n Hybrid architecture n n n Lookup in SIP+P 2 P Inter-domain P 2 P-SIP Unlike file-sharing applications n n n DHT algorithm uses SIP communication Data storage, caching, delay, reliability Data model and service model Disadvantages n Lookup delay and security 14
SIP-using-P 2 P Implementation in SIPc with the help of Xiaotao Wu n Open. DHT n n Identity protection n Using Data model Certificate-based SIP id == email P 2 P for Calls, IM, presence, offline message and name lookup 15
Distributed Hash Table (DHT) Chord background 1 54 8 58 10 14 47 21 32 38 14 8+2 = 10 14 8+4 = 12 14 8+8 = 16 21 8+16=24 32 8+32=40 42 n Finger table: log. N n 24 8+1 = 9 n n 38 node Identifier circle Keys assigned to successor Evenly distributed keys and nodes n 42 Key 30 n ith finger points to first node that succeeds n by at least 2 i-1 Stabilization for join/leave 16
P 2 P-over-SIP: SIPpeer: implementation in C++ n n DHT maintenance using SIP sippeer: n n n Adaptor for existing phones n n n scalability and availability Advanced: n n Use P 2 P-SIP node as an outbound proxy NAT/firewall traversal Analysis: n n C++, Linux, Chord, failover Server farm vs super-peer vs all peers Offline messages, conferencing, Interdomain overlay My P 2 P-SIP work at Adobe 17
Server-based vs peer-to-peer Reliability, failover latency DNS-based. Depends on client retry timeout, DB replication latency, registration refresh interval DHT self organization and periodic registration refresh. Depends on client timeout, registration refresh interval. Scalability, number of users Depends on number of servers in the two stages. Depends on refresh rate, join/leave rate, uptime Call setup latency One or two steps. O(log(N)) steps. Security TLS, digest authentication, S/MIME Additionally needs a reputation system, working around spy nodes Maintenance, configuration Administrator: DNS, database, middle-box Automatic: one time bootstrap node addresses PSTN interoperability Gateways, TRIP, ENUM Interact with server-based infrastructure or co-locate peer node with the gateway 18
Outline of the presentation Introduction n n Server redundancy n n Load sharing and failover in SIP telephony Peer-to-peer (P 2 P) n n P 2 P telephony using SIP Enterprise IP telephony n n n What is the problem? Why important? Multi-platform collaboration using SIP Scalable centralized conferencing architecture Other interesting projects Conclusion 19
Internet telephony infrastructure CINEMA: Columbia Inter. Net Extensible Multimedia Architecture Telephone switch Local/long distance 1 -212 -5551212 CINEMA servers rtspd: media server sipconf: RTSP Conference server PSTN Department PBX Internal Telephone Extn: 7040 713 x Quicktime RTSP clients sipum: Unified messaging sipd: Proxy, redirect, Registrar server SIP/PSTN Gateway SQL database cgi vxml Web server SIP VXML Built many components in a complete system for enterprise IP telephony and multimedia collaboration siph 323: SIP-H. 323 translator Web based configuration My work H. 323 Net. Meeting 20
Goal of my work n n n Beyond voice: video, text, IM, presence, screen sharing, shared web browsing, … Beyond SIP phone: regular telephone, email, web, … Beyond synchronous communication: offline mails, discussion forum, file sharing, … Internet Telephony Interactive voice response Internet Radio/TV Messaging and Presence Unified messaging Video conferencing Media G. 711 MPEG SIP RTSP SAP RSVP RTCP Application layer RTP Transport (TCP, UDP) Network (IPv 4, IPv 6) Quality of service Signaling Media transport Link layer Physical layer Program Call routing Voice XML DTMF Mixing Speech/ text SDP 21
Communication to collaboration n Comprehensive n Personalized view n n Synchronous (tightly-coupled) collaboration n n Unified messaging, shared files, discussion forum, notification Multi-platform (device) n n Conferencing: audio, video, IM, white-board, screen sharing, shared web browsing Asynchronous (loosely-coupled) collaboration n n Calendar, address book, groups and access control Telephone: touch tone input and audio (IVR) PC: multimedia client, email, IM Reuse existing protocols and tools Unified messaging n The gaps among different media (audio, video, text), devices (PC, phone) and means of communications (Email, SIP, IM) disappear for messaging 22
Conference Playout delay G 711 A DVI B Linear Periodic timer M - A=B+C E D Linear Mixed linear M-B D E G 711 DVI M=A+B+C GSM C Linear M-C D Receive n n n E G 711 Send G. 711, GSM, DVI, Speex, G. 722, Speex mixing (decode-mix-encode) Video replication; IM; text; VNC screen sharing; floor control; IVR for joining Optimization possible for same codecs 23
Conference 24
Conference server Performance evaluation of audio mixer and cascaded architecture n n SIP REFER message is used to create cascading N. (N-1) participants Higher delay n n N 2/4 participants Lower delay I measured the CPU usage for two cascaded servers: supports about 1000 participants 25
Presence/event notification office. com bob@office. com Presence server PA alice@home. com SUBSCRIBE PUA REGISTER NOTIFY registrar PUA + PA 26
Columbia IM and presence 27
Network call control n Priority. pl SIP_FROM SIP_TO stdin CGI-PROXY-REQUEST stdout n n SIP-CGI CPL SIP servlets Urgent if (defined $ENV{SIP_FROM} && $ENV{SIP_FROM} =~ /sip: boss@mycompany. com/) SIP proxy Phone { foreach $reg (get_regs()) { print "CGI-PROXY-REQUEST $ reg SIP/2. 0n"; print "Priority: urgentnn"; Low-priority } } Voicemail 28
Voicemail n n Endpoint redirects Design alternatives Issues Redirect after 10 s alice@vmail. yahoo. com Proxy controls Voicemail acts like a phone vmail. pl SIP_FROM SIP_TO stdin CGI-PROXY-REQUEST stdout If no response accept after 15 s 29
Web interface n Retrieval n n n Web interface rtsp: //server/alice /inbox/1677. au, sip: alice-1677 retrieve@server press 1 to listen… Configuration n Folders Options Email 30
Voice. XML Gateway PSTN Telephone sipvxml Internet Voice gateway VXML • Voice and telephony functions • Voice. XML browser IVR platform • Voice and telephony functions (ASR, TTS, DTMF) • Service logic (application specific) HTML Internet user Web server • Service logic (CGI, servlet, JSP) 31
Voice. XML contd. <form action=“url”> Enter your Id: <input name=‘id’> <input type=‘submit’> </form> <field name=‘id’> <prompt> Your ID, please. </prompt> </field> <block> <submit next=“url”/> </block> </form> Telephony, speech synthesis or audio output, user input and grammar, program flow, variable and properties, error handling, … 32
Columbia sipvxml PSTN Telephone n n n Unified messaging access Email by phone Event notification and scheduling Audio volume control for conference Advanced conference control Internet SIP/PSTN gateway TTS, ASR, DTMF, XML, sipvxml HTTP, RTSP SIP phone Web server Media server rtspd Email. tcl 33
Email + phone Email by phone Email procmail important mails Email to IM Internet SIP Voice. XML browser HTTP JSP n n Login Email formatting Listen, reply, delete, compose, forward Navigation -next, previous, jump Email servlet DB SIP n n TTS IM Call n Inbox Email formatting SIP based Text-to-speech SIP Internet Inbox Email to phone 34
IM + voice call n Who can initiate? n SIP MESSAGE TTS ASR n n Call RTP Feedback n IM n SIP INVITE n n authentication, billing, … to voice user to IM user initial IM greeting Talk-spurt detection Speech recognition 35
Notification n Calendar Events Conferences Schedule from a browser SIP call 2129397063 Web server Calendar. cgi “at 6: 00 pm” IM kundan@ Email Kns 10@… 36
Phone announcement server Text or audio Destinations n Input n n TTS PAS SIP n Example n n . . . n Range: 93970? ? List: A, B, C Announcement Emergency Issues n n Voicemail Failure detection 37
Outline of the presentation Introduction n n Server redundancy n n Load sharing and failover in SIP telephony Peer-to-peer (P 2 P) n n P 2 P telephony in SIP Enterprise IP telephony n n n What is the problem? Why important? Multi-platform collaboration using SIP Scalable centralized conferencing architecture Other interesting projects Conclusion 38
Revisiting the problems n Developed a two stage scalable and Can SIP server provide carrier-grade reliability reliable SIP server architecture: linear scaling. Usehardware? event-based. and scalability using commodity n n How can we build a server-less self-organizing Developed P 2 P-SIP architecture: SIP peer-to-peer Vo. IP network? -using-P 2 P and P 2 P-over-SIP n n What affects the server performance? Can this be done in standards compliant way? Can communication be extended to multiplatform collaboration using existing Multi-platform collaboration using protocols? n n existing protocols and tools, How well multi-party conferencing scales? unified messaging, centralized conferencing (cascaded), SIPHow to interoperate between SIP and H. 323? H. 323 interworking. 39
Conclusions n Impact: n n n n Commercialized by SIPquest (now First. Hand. Tech. com) and sold to many customers. CINEMA was deployed in our department for a brief period of time. Used in various other projects at IRT: NG 911, firewall controller, presence scalability, TCP/TLS measurements, … P 2 P-SIP is a “hot” topic in industry and IETF now – client desktop, hardware phone as well as server vendors are pursuing this. SIP-H. 323 requirements eventually became an RFC Worked on SIP stack and P 2 P-SIP implementation at Adobe; the SIP implementation is announced already and planned to be beta-released this year, and hopefully P 2 P-SIP will make it to consumers some day “So what” (Implications): n n Replacing PSTN – better features, quality and performance at lower cost and maintenance; zero cost Vo. IP using P 2 P-SIP Distributed, multi-provider, component architecture for telephony and collaboration 40
My publications Conference, workshop, technical report, magazine/journal 1. K. Singh and H. Schulzrinne, “Using an external DHT as a SIP location service", Columbia University Technical Report CUCS-007 -06, NY, Feb’ 06. 2. K. Singh and H. Schulzrinne, “Peer-to-peer Internet telephony using SIP", NOSSDAV, Skamania, Washington, Jun 2005. . K. Singh and H. Schulzrinne, "Peer-to-peer Internet Telephony using SIP", New York Metro Area Networking Workshop, CUNY, Sep 2004. K. Singh and H. Schulzrinne, "Peer-to-peer Internet Telephony using SIP", Columbia University Technical Report CUCS-044 -04, NY, Oct 2004. 3. K. Singh and H. Schulzrinne, “Failover, load sharing and server architecture in SIP telephony”, Elsevier Computer Communication Journal. To appear. Aug 2006. “K. Singh and H. Schulzrinne, “Failover and load sharing in SIP telephony", SPECTS (Symposium on performance evaluation of computer and telecommunication systems). Philadelphia, PA, Jul 2005. K. Singh and H. Schulzrinne, "Failover and Load Sharing in SIP Telephony", Columbia University Technical Report CUCS-011 -04, NY, May 2004. H. Schulzrinne, K. Singh and X. Wu, "Programmable Conference Server", Columbia University Technical Report CUCS-040 -04, NY, Oct 2004. 5. K. Singh, Xiaotao Wu, J. Lennox and H. Schulzrinne, "Comprehensive Multi-platform Collaboration", MMCN 2004 - SPIE Conference on Multimedia Computing and Networking, Santa Clara, CA, Jan 2004. 4. K. Singh, Xiaotao Wu, J. Lennox and H. Schulzrinne, "Comprehensive Multi-platform Collaboration", Columbia University Technical Report CUCS-027 -03, NY, Nov 2003. 6. M. Buddhikot, A. Hari, K. Singh and S. Miller, "Mobile. NAT: A new Technique for Mobility across Heterogeneous Address Spaces", ACM MONET journal, March 2005. M. Buddhikot, A. Hari, K. Singh and S. Miller, "Mobile. NAT: A new Technique for Mobility across Heterogeneous Address Spaces", WMASH 2003 - ACM International Workshop on Wireless Mobile Applications and Services on WLAN Hotspots, San Diego, CA, Sep 2003. 7. K. Singh, A. Nambi and H. Schulzrinne, "Integrating Voice. XML with SIP services", ICC 2003 - Global Services and Infrastructure for Next Generation Networks, Anchorage, Alaska, May 2003. K. Singh, A. Nambi and H. Schulzrinne, "Integrating Voice. XML with SIP services", Second New York Metro Area Networking Workshop, Columbia University, NY, Sep 2002. 8. K. Singh, W. Jiang, J. Lennox, S. Narayanan and H. Schulzrinne, "CINEMA: Columbia Inter. Net Extensible Multimedia Architecture", Columbia University Technical Report CUCS-011 -02, NY, May 2002. W. Jiang, J. Lennox, H. Schulzrinne and K. Singh, "Towards Junking the PBX: Deploying IP Telephony", NOSSDAV 2001. W. Jiang, J. Lennox, S. Narayanan, H. Schulzrinne, K. Singh and X. Wu, "Integrating Internet Telephony Services", IEEE Internet Computing (magazine), May/June 2002 (Vol. 6, No. 3). 9. K. Singh, Gautam Nair and H. Schulzrinne, "Centralized Conferencing using SIP", 2 nd IP-Telephony Workshop (IPTel'2001), April 2001. 10. K. Singh and H. Schulzrinne, "Unified Messaging using SIP and RTSP", IP Telecom Services Workshop 2000, Atlanta, Georgia, U. S. A, Sept 2000. K. Singh and H. Schulzrinne, "Unified Messaging using SIP and RTSP", Columbia University Technical Report CUCS-020 -00, NY, Oct 2000. 11. K. Singh, H. Schulzrinne, "Interworking Between SIP/SDP and H. 323", 1 st IP-Telephony Workshop (IPTel'2000), April 2000. K. Singh and H. Schulzrinne, "Interworking Between SIP/SDP and H. 323", Columbia University Technical Report CUCS-015 -00, NY, May 2000. 41
30 second version n I developed reliability and scalability techniques for Internet telephony and showed that it is at par with the existing telephone system reliability and scalability at a much lower cost. I developed interoperable architecture to build self organizing network of Internet telephones, without depending on managed infrastructure or servers. I developed tools and components for a multiplatform multimedia collaboration system using existing standards and showed that it can scale to large number of simultaneous participants. 42
Scientific contribution n That linear cluster scalability can be observed in SIP servers. That we don’t need to depend on servers or managed infrastructure for Internet telephony. That we can build highly scalable and reliable Internet telephony systems using existing standards on commodity hardware. 43
- Slides: 43