Asterisk without RTP streams vs. SER in statefull mode

I am am starting up a residential VOIP company and will be using only SIP both with my customers and my termination provider. I am also doing peering with other SIP networks. My goal is to be able to avoid handling the RTP streams as much as possible as to save bandwidth.

My original Idea was to use SER to handle the Call routing and only use Asterisk for voicemail, forwarding, etc. However, when talking to a termination provider, he suggested that I could get the same results using asterisk by itself, by setting reinvite=yes.

I was wondering what the comparative performance would be. Most of the comparisons I’ve seen have been comparing Asterisk in B2BUA mode ( handling RTP streams) to SER in stateless proxy mode (just relaying SIP transactions). So they have been comparing apples to oranges (Asterisk in it’s slowest mode, with SER in its fastest). To get a true apples to apples comparison, SER would need to use functions such as t_relay() and loose_route() and probably a few more, which impede optimal performance; Asterisk would be configured with reinvite=yes (or is it canreinvite=yes?) so that it doesn’t have the overhead of handling RTP and thus would have a higher performance.

With all that said, what would the performance difference be? How many registrations/calls can I handle per machine (3.8 GHz P4 1GB RAM)? What are the advantages and disadvantages of each approach?

asterisk will by default reinvite wherever it can unless you use canreinvite=no. this can be set in sip.conf [general] section to apply globally (you can override it per peer with canreinvite=yes) or set per peer.

Your machine should be able to handle at least a few hundred calls. You will want to be using Realtime and have MySQL cache as much as possible. Obviously transcoding is out of the question. Check out the Wiki page Asterisk Dimensioning for some real world stories, keep in mind many of those are not what their hardware is capable of, but what they put on it. IE, ‘My p-200 takes 20 calls!’ doesn’t mean his p-200 can only handle 20 and 21 will break it, it means that he’s only fed 20 into it and it hasnt broken yet.