Sipgate Problem - for a change SOLVED!

Check out page page 31 of this

http://www.thecaretaker.org.uk/routers/dsl504/dsl504_manual_r2.0x.pdf

thats all the options i get! on or off :frowning:

In in UK so PPoE i believe.

What do I need to install on the linux box do acheive this?

That’s cool. So long as it’s turned on, you should be alright.

So you’ll need NAT on; redirection enabled; redirected ports set up right; the correct externip statement in sip.conf; do ‘sip reload’ on the running asterisk when you change the externip statement; nat=yes in the right place(s) in sip.conf. All of which you had (i think) - but it still didn’t work…

I’d start from the basics and go through all those things as set them up systematically and see what happens. Make sure that externip statement is really the right IP address - should be able to get it from the router, obviously, but it’s also worth downloading stunclient (do a google search for stunclient and linux, or have a look on voip-info somewhere) and check that stunclient sees what you think is the situation.

Maybe. But when i was there a few months back i had an ADSL account with virgin and it was using PPPoATM. I’m not entirely sure what the difference is, as it’s all PPP over ATM anyway, but there is a difference. Check on your modem/router’s config or check with your ISP.

Or, alternatively, just try PPPoE and see if it works. I think in the UK there’s a mixture of the two and at least some ISPs support both (either).

Probably nothing. But that may depend on what distribution you’re using. If it’s a recent one, it’s pretty well guaranteed to be included and you should be able to set up a PPPoE connection in the network configuration option in the system settings or system tools menu.

In my system (FC3, gnome), it’s in the System Settings → Network menu option. When you go to set up a new network connection, one of the options is “xDSL” - that’s the one you use. You will have to tell it which ethernet card to do the connection over and give it the connection settings (i.e., username, password).

To get it working, though, you will have to have a dedicated ethernet card for that connection, set your modem/router to bridging mode, and have just the one cable from the modem/router to the dedicated ethernet card. You will have to set up a firewall on the linux box too and use a second ethernet card, connected to a ethernet switch/hub to connect any other computers to the net through the linux box.

If you’ve only got one other computer you want to connect to the net, you can dispense with the separate switch/hub and use a crossover ethernet cable to connect it direct to the second ethernet card on the linux box.

Page ix and page 8 of that manual refer to bridged connections. I haven’t looked any further through it, but there may be other references, or it may just be obvious what you click on to set it up in bridged mode. It should be a simple matter of just selecting bridged mode - you shouldn’t need to touch any other settings on the modem/router. This means it’s very simple to set it up and see if it works - if it doesn’t it should be simple to set it back to the way it was.

Thanks a lot Will again :smile:

thats given me something to work through.

I wont let it beat me :confused: Ill get their in the end

hello again

ive played around some more

i now have sipgate, gossiptel and voipuser set up in sip.conf

ive put my box in a DMZ on a routable IP.

I get registration messages and when i type “sip show registry” its says “request sent” and “sip show channels” shows the details but no rx.

Is their some config I have missed?

Can I turn NAT off on my router to try and troubleshoot to see if that is the problem? How does the addressing work if I disable NAT! Will I still get DHCP addresses from my router but not NAT’d addresses?

I also tryed to stun client on my windows box and all said was fine ( i couldnt get it to run on the linux box but windows is set up same)

Would trying an IAX account help?

PS My DLINK router is one hour away from being launched out the window into the garden
:imp:

PPS

a softphone configured directly to sipgate works fine with stun from the * box.

dont know if this has a bearing on it

Have you tested that the DMZ is working the way you think it should? For example, try ssh’ing to it from an external system - i.e., one that’s completely outside your local network, somewhere on the internet. If you can do that, then you can be pretty sure sip packets can get to it too.

Where did you get the routeable IP address? If your internet connection is on a dynamic address, a static address can’t possibly be being routed through it. Are you sure you’ve got the hang of this IP address stuff?

You can’t have a DMZ if you’ve got a dynamic IP address.

You should probably also try an ethereal scan of packets in and out of that interface in the hope you might get some clues from that.

[quote]I get registration messages and when i type “sip show registry” its says “request sent” and “sip show channels” shows the details but no rx.

Is their some config I have missed?[/quote]
Have you double checked there’s no firewall running by default on the linux box?

DHCP should still work. Turning off NAT will mean that any packets going out from your internal systems are sent onto the internet with a local (non-internet-routeable) address and external systems won’t be able to reply.

What do you mean it said it was fine??? Stun isn’t about telling you it’s fine or not, it should tell you what your external IP address is. What did it tell you?

Yes. It might help work out what’s going on.

Oh.

That puts a very different complexion on it then, doesn’t it!

If sip works from the asterisk box, then it can only be your asterisk configuration!

You’d better check the asterisk configs again!

Maybe you posted them earlier, but this has turned into rather a long thread! :wink:

Maybe you’d better post your sip.conf.

thanks again will

yeah, i get the IP stuff but * seems to be a little random with its messages.

Leave it with me, ill do some more tinkering tonight and then post my sip.conf if not fixed.

right

the x-ten softphone DEFINATELY logins to sipgate and registers find from my * server through my nat device.

heres my sip.conf and extrensions.conf

my ip is 65.65.0.3 and my external is 84.93.231.77

anyting need to be done to rtp.conf ?

[quote][general]
port=5060
binaddr=0.0.0.0
srvlookup=yes
context=default
externip=84.93.231.77
localnet=65.65.0.0/255.255.255.0
;nat=yes

register => userid:secret@sipgate.co.uk/userid
register => userid:secret@nat.gossiptel.com:5082/userid
register => userid:secret@voipuser.org/userid

[sipgate]
type=friend
username=userid
secret=secret
host=sipgate.co.uk
fromuser=userid
fromdomain=sipgate.co.uk
nat=yes
authuser=userid
dtmfmode=info
context=from_sipgate
qualify=yes
insecure=very
canreinvite=no
disallow=all
allow=ulaw
allow=alaw

[gossiptel]
type=friend
username=userid
secret=secret
port=5082
host=nat.gossiptel.com
fromuser=userid
fromdomain=nat.gossiptel.com
nat=yes
authuser=userid
context=from_gossip
;insecure=very
canreinvite=no
disallow=all
allow=ulaw
allow=alaw

[voipuser]
type=friend
username=userid
secret=secret
host=voipuser.org
fromuser=userid
fromdomain=voipuser.org
nat=yes
authuser=userid
context=from_voipuser
qualify=yes
insecure=very
canreinvite=no
disallow=all
allow=ulaw
allow=alaw

[100]
type=friend
context=default
username=100
secret=password
host=dynamic

[200]
; Turn off silence suppression in X-Lite (“Transmit Silence”=YES)!
; Note that Xlite sends NAT keep-alive packets, so qualify=yes is not needed
type=friend
host=dynamic
context=default
username=200
secret=password

[/quote]

and some output from debug console

[quote]
Asterisk Ready.
*CLI> Jun 28 20:26:12 DEBUG[3851]: acl.c:200 ast_apply_ha: ##### Testing 193.111.200.12 with 65.65.0.0
Jun 28 20:26:12 DEBUG[3851]: chan_sip.c:863 ast_sip_ouraddrfor: Target address 193.111.200.12 is not local, substituting externip
Jun 28 20:26:12 DEBUG[3851]: chan_sip.c:4699 transmit_register: Scheduled a registration timeout for nat.gossiptel.com : 14
Jun 28 20:26:22 DEBUG[3851]: acl.c:200 ast_apply_ha: ##### Testing 216.127.66.119 with 65.65.0.0
Jun 28 20:26:22 DEBUG[3851]: chan_sip.c:863 ast_sip_ouraddrfor: Target address 216.127.66.119 is not local, substituting externip
Jun 28 20:26:22 DEBUG[3851]: chan_sip.c:4699 transmit_register: Scheduled a registration timeout for voipuser.org : 16
Jun 28 20:26:22 DEBUG[3851]: sched.c:225 sched_settime: Request to schedule in the past?!?!
Jun 28 20:26:22 DEBUG[3851]: sched.c:225 sched_settime: Request to schedule in the past?!?!
Jun 28 20:26:22 NOTICE[3851]: chan_sip.c:4570 sip_reg_timeout: – Registration for 'userid@sipgate.co.uk’ timed out, trying again (Attempt #1)
Jun 28 20:26:22 DEBUG[3851]: chan_sip.c:1076 __sip_ack: Stopping retransmission on ‘7054f9be0eb4af1846e795fb749f34f9@127.0.0.1’ of Request 102: Not Found
Jun 28 20:26:22 WARNING[3851]: chan_sip.c:1088 __sip_pretend_ack: Have a packet that doesn’t want to give up!
Jun 28 20:26:27 DEBUG[3851]: acl.c:200 ast_apply_ha: ##### Testing 217.10.79.219 with 65.65.0.0
Jun 28 20:26:27 DEBUG[3851]: chan_sip.c:863 ast_sip_ouraddrfor: Target address 217.10.79.219 is not local, substituting externip
Jun 28 20:26:27 DEBUG[3851]: chan_sip.c:4699 transmit_register: Scheduled a registration timeout for sipgate.co.uk : 18
Jun 28 20:26:27 DEBUG[3851]: sched.c:225 sched_settime: Request to schedule in the past?!?!
Jun 28 20:26:27 DEBUG[3851]: sched.c:225 sched_settime: Request to schedule in the past?!?!
Jun 28 20:26:27 DEBUG[3851]: sched.c:225 sched_settime: Request to schedule in the past?!?!
Jun 28 20:26:27 DEBUG[3851]: chan_sip.c:1076 __sip_ack: Stopping retransmission on ‘7054f9be0eb4af1846e795fb749f34f9@127.0.0.1’ of Request 102: Not Found
stop noip show channels
Peer User/ANR Call ID Seq (Tx/Rx) Format Last Msg
217.10.79.219 userid 7054f9be0eb 00103/00000 unknow
216.127.66.119 userid 5fe5e7cb1a8 00102/00000 unknow
193.111.200.12 userid 65c390ef4ae 00102/00000 unknow
217.10.79.219 userid 7054f9be0eb 00102/00000 unknow(d)
4 active SIP channel(s)
*CLI> sip show registry
Host Username Refresh State
voipuser.org:5060 userid 120 Request Sent
nat.gossiptel.com:5082 userid 120 Request Sent
sipgate.co.uk:5060 userid 120 Request Sent
*CLI[/quote]

Im really hoping its a schoolboyerror :smile:

[quote=“spoonz”]my ip is 65.65.0.3 and my external is 84.93.231.77

anyting need to be done to rtp.conf ?[/quote]
Probably not. But, even if it did, that shouldn’t affect registration. RTP.conf only comes into play when setting up a call - you need two available ports for each call.

This is the only place where i can see there might be a complication. All the rest looks ok to me.

Is the x-lite using the same address as an external address?

Why have you got the localnet set to 65.65.0.0? is that really the address of your LAN? If that address block isn’t inside your router, then it’s not local. Not that that’s likely to make any difference to your problem.

The question here, really, is is your modem/router doing what you think it should be doing? Have you tried telnetting or ssh’ing from outside to your asterisk server’s IP address? This is important. You need to know that that address is really reachable.

However, if the xlite is definitely using that address and working, then it’s probably not an issue.

Apart from that, i’m afraid i’m at a loss to know what’s going on. If your asterisk box’s IP address works exactly like it would if it was directly exposed to the internet with no NAT etc, as i would expect a DMZ to operate, then this should be working as far as i can see.

Well, if it is i can’t see it!

Hang on! The xten softphone doesn’t run on linux, so you can’t be using it on your asterisk box, surely??? You are running asterisk on linux, aren’t you? I don’t think you said anywhere…

yes redhat and the x-ten runs fine :open_mouth:

http://www.xten.com/index.php?menu=products&smenu=xlite&ssmenu=download

True? On the voip-info site it says it works on windows and mac, that’s all. I would have tried it out a while ago if i’d known it works with linux! I’d better give it a try now then! :wink:

can you recomend where I can get a cheap(free) IAX account to test my theory on sip?

Voipgate. voipgate.com

They’ve got an echo tester plus a 1khz test tone - which is handy for calibrating volume levels etc.

echo test - 352 2727 3098
test tone - 352 2727 3096

right

im setting my router up as a bridge and configuring a new NIC in my * box to terminate the ADSL.

a couple of questions

  1. do i set the interface up as NIC or ADSL and provide the logon details etc

  2. will i need to change the IP of the router?

  3. I have a switch to plug my windows box into, can i get my linux box to share the internet connection?

I will set the firewall on linux and at least I can see whats heppening then.

morning again,

last night i bridged my router and setup my linux box to act as the termination.

all cool, got the connection working but same prob with UDP.

I began to think it was a problem with my ISP!

I read the Ts&Cs and apparently my service is restricted for news downloads and peer 2 peer services to stop large downloads.

On further investigation i found that peer2peer software use UDP ports and some quite diverse ones at that. Im hoping that my ISP have blocks/restrictions on these ports. This would explain my * servers behaviuor.

I have opened a support ticket with them to find out!

fingers crossed.

Well, at this stage, it seems like it would need to be something like that to explain what’s going on! Can you find out what ports the xlite uses and configure asterisk to use those. The only ones i can think of that seem likely to be different are the RTP ports used at your asterisk end.

You could always just try changing the RTP ports asterisk uses in rtp.conf - i can’t see any reason why you couldn’t use any port range you felt like. 10000 seems to be the start port in the default configs, and if that’s one that they’re blocking it could be a problem.

Although, thinking about it, that problem shouldn’t affect registration - as RTP only comes into the picture once a call is set up (i think).

Apart from that, the only other port involved, as far as i know, is set in the

port=5060

statement in sip.conf. However, the xlite must surely use 5060 as well. You can always try changing it though, without any real complications - so long as you change the port in any local phones too.

To be honest, though, if the xlite works, i can’t see why asterisk wouldn’t.

Maybe it’s worth downloading the latest CVS version of asteriks and installing that - just to see if it changes. Some things changed for me last time i did that (i’ve been through a few CVS versions now though).

This thread has gotten too long. I tried to read everything, but lost it somewhere in the middle.

To the original poster: context inbound and context incoming will never connect. This would prevent incoming calls to succeed.

Sorry if this is irrelevant.

thanks for all your help

now i have upgraded my connection with plusnet the problems have disappeared.

My * server now registers with sipgate THROUGH nat with no problems and I can get calls in. :smile:

Few other ones arose though

  1. No ringing sound on calling line (even though got ringing in extensions)

  2. sipgate can be a bit laggy on my connection but thats tough luck at the moment.

all good fun, time to do some tweaking me thinks

o and my zaptel card has arrived (X100) and thats not working now :frowning:

modprobe works etc

but when i run ztcfg i get unable to open /dev/zap/ctl

1 error detected

I followed the instructs closely on the wiki.

ahhhhh

ext => _XXXXXXXX,1,(SIP/100,30,r)

that damn “r” solved the ringing :smile: