On Sun, Aug 16, 2009 at 6:52 AM, Shayne O'Neill<shayne.oneill at gmail.com> wrote: > Hey guys, > > I'm getting some erratic DNS weirdness from Pennytel, and I'm wondering if > its something I should be handling in my code. > It's probably your nameserver setting that's not correct. This normally should point to the local nameserver (in your LAN, e.g. from DHCP), and not the public DNS server hosting the domain. Cheers Benny > Heres the code I'm using.. > > ? ? ? ?if (([defaults stringForKey:@"dnsserv"] != nil) && (![[defaults > stringForKey:@"dnsserv"] isEqualToString:@""])) { > ? ? ? ? ? ? ? ?NSLog(@"Setting DNS server %@",[defaults > stringForKey:@"dnsserv"]); > ? ? ? ? ? ? ? ?cfg.nameserver_count = 1; > ? ? ? ? ? ? ? ?cfg.nameserver[0] = pj_str([[defaults > stringForKey:@"dnsserv"] UTF8String]); } > ? ? ? ?else { > ? ? ? ? ? ? ? ?cfg.nameserver_count = 0; > ? ? ? ?} > > The bracket stuff is just ObjC semantics to extract the server from the > settings.. > > Heres the log outputs. > 2009-08-16 13:42:40.695 sipContract[541:207] Setting DNS server > 192.231.203.132 > . > . (Not relevant stuff deleted) > . > . > ?13:42:40.915 ? ?pjsua_acc.c ?Account sip:<account deleted from > log>@sip.pennytel.com added with id 0 > ?13:42:40.926 ? ? resolver.c ?Transmitting 44 bytes to NS 0 > (192.231.203.132:53): DNS SRV query for _sip._udp.sip.pennytel.com > ?13:42:40.926 ? ?pjsua_acc.c ?Registration sent > ?13:42:42.931 ? ? resolver.c ?Re-transmitting 44 bytes to NS 0 > (192.231.203.132:53): DNS SRV query for _sip._udp.sip.pennytel.com > ?13:42:44.934 ? ? resolver.c ?Re-transmitting 44 bytes to NS 0 > (192.231.203.132:53): DNS SRV query for _sip._udp.sip.pennytel.com > ?13:42:46.935 ? ? resolver.c ?Re-transmitting 44 bytes to NS 0 > (192.231.203.132:53): DNS SRV query for _sip._udp.sip.pennytel.com > ?13:42:48.934 ? ? resolver.c ?Re-transmitting 44 bytes to NS 0 > (192.231.203.132:53): DNS SRV query for _sip._udp.sip.pennytel.com > ?13:42:50.935 _sip._udp.sip. ?DNS SRV resolution failed for > _sip._udp.sip.pennytel.com: Operation timed out (PJ_ETIMEDOUT) > ?13:42:50.935 _sip._udp.sip. ?DNS SRV resolution failed for > _sip._udp.sip.pennytel.com, trying resolving A record for sip.pennytel.com > ?13:42:50.936 ? ? resolver.c ?Transmitting 34 bytes to NS 0 > (192.231.203.132:53): DNS A query for sip.pennytel.com > ?13:42:52.936 ? ? resolver.c ?Re-transmitting 34 bytes to NS 0 > (192.231.203.132:53): DNS A query for sip.pennytel.com > ?13:42:54.936 ? ? resolver.c ?Error transmitting request: No working DNS > nameserver (PJLIB_UTIL_EDNSNOWORKINGNS) > ?13:42:54.936 _sip._udp.sip. ?DNS A record resolution failed: Operation > timed out (PJ_ETIMEDOUT) > ?13:42:54.936 ?sip_resolve.c ?DNS A record resolution failed: Operation > timed out (PJ_ETIMEDOUT) > ?13:42:54.936 ? ?tsx0x851e64 ?Failed to send Request msg REGISTER/cseq=39325 > (tdta0x84f200)! err=70009 (Operation timed out (PJ_ETIMEDOUT)) > ?13:42:54.937 ? ?pjsua_acc.c ?SIP registration failed, status=503 (Service > Unavailable) > > Any ideas what might be going wrong here? > > =================================== > Shayne O'Neill Development > Mobile, Web and Business process integration. > shayne.oneill at gmail.com 0400247091 > Ask me about how Alfresco can help your business grow. > > > _______________________________________________ > Visit our blog: http://blog.pjsip.org > > pjsip mailing list > pjsip at lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org >