VOIP: Difference between revisions

From Wildsong
Jump to navigationJump to search
Brian Wilson (talk | contribs)
Brian Wilson (talk | contribs)
 
(29 intermediate revisions by the same user not shown)
Line 1: Line 1:
[http://www.asterisk.org/ Asterisk]
== Wildsong's phone system overview ==


[http://www.freeworlddialup.com Free World Dialup]
* A small Supermicro server ([[Bellman]]) runs Asterisk on Debian
* 2 Grandstream GXV3240 Android deskphones are the main office and workshop phones.
* A Linksys SPA2000 directs calls to a Model 500 rotary dial phone in the studio.
* Elastic SIP Trunking service is provided by Twilio
* Inbound calls are directed to an extension that rings the SPA2000 phone, the GXV3240s, and sends the call back out to my cellphone via Twilio.
* SMS messages come to Twilio and gets forwarded to my cellphone via a TWMLBIN rule (Programmable SMS).
* The Asterisk PBX handles voicemail.


me 275052
We still have a GoogleVoice number that forwards calls to the Twilio number and to Julie's cellphone. I am relying on the Asterisk forwarding to get GoogleVoice calls on my cellphone.
steve 754819
dean 257532


I currently use [http://www.packet8.net Packet8] service at home,
== Hardware ==
have for a couple years now. It works fine but I am now diving in deeper.
 
I am also building a system for a small business,
which will probably use Linksys equipment.
 
I am playing with softphones now.


pulver communicator (from fwd site) (Windows)
=== PSTN gateways ===


ekiga (for Linux) could not get it going because the linux box has no mic input!
Are you still using POTS lines? Really? Get rid of them and use Twilio.
(A Shuttle SB95)


Adore softphone (Windows)
If you must use POTS lines for some reason (no Internet available?) then my current recommendation would be a Sangoma Vega 50. It works flawlessly and reasonably easy to set up and configure.


== Hardware ==
I have also used Digium boards. The X100P is cheap but supports only one line. The TDM400 is good for 4 lines.


PSTN gateway
I worked with a Grandstream GXV4104 and found it to be possible to make it work but really a pain to configure.


[http://www.linksys.com Linksys SPA-400]
Long ago
I tried out a [http://www.linksys.com Linksys SPA-400] with 3 PSTN analog phone lines and an Asterisk server running on a recycled PC. It probably works fine as intended, in an all Linksys system but I was never able to get it to work reliably with Asterisk. The irony is that the SPA-400 runs Linux and Asterisk internally.


This is an interesting device because it's open source.
You can download the source tarball from the Linksys site.
You can download the source tarball from the Linksys site.


version 1.0.0.2
version 1.0.0.2


It looks like it's based on Monta Vista Hardhat Linux
It's based on Monta Vista Hardhat Linux


* MIPS processor
* MIPS processor
Line 44: Line 41:
* /usr/sbin/lightbox controls LED's
* /usr/sbin/lightbox controls LED's
* dropbear ssh
* dropbear ssh
After a few months of wrestling with it, we bought a TDM-400 and sold the SPA-400 on eBay.
=== Handsets ===
Ones that I have tried include
Grandstream GXV3240 (my favorite), GXV3275, DP715
[[Grandstream BT-100]] -- cheapie
Linksys/Sipura SPA-841
Linksys SPA-941
Polycom IP-550
Polycom IP-650
What has paging / auto-answer / intercom support??? [http://www.voip-info.org/wiki/index.php?page=Asterisk+Paging+and+Intercom]
The GXV324xx phones do, I have tested it and it works fine.
Some phones support multicast. incl Grandstream, Aastra, Snom, Linksys
Aastra -- The ALERT_INFO variable works for 480i, 480i CT, 9133i, 9112i firmware 1.2.x or later [http://www.voip-info.org/wiki/view/Sayson+IP+Phone+Auto+Answer]
The bugs listed for this phone seem to preclude its desirability.
It's been replaced by the 9480i which is TOO EXPENSIVE
Linksys SPA-841
Snom 300 supports POE and auto answer and multicast paging
http://www.snom.com/en/products/ip-phones/snom-300-ip-phone/
== Network ==
=== Setting up QOS on Mikrotik ===
Refer to http://wiki.mikrotik.com/wiki/Voip
/ip firewall mangle
# First mark things as SIP
add action=mark-packet new-packet-mark=SIP_IN  chain=prerouting  in-interface=ether1-gateway  disabled=no passthrough=no \
    src-address=192.168.1.2 comment="Bellman"
add action=mark-packet new-packet-mark=SIP_OUT chain=postrouting out-interface=ether1-gateway disabled=no passthrough=no \
    dst-address=192.168.1.2 comment="Bellman"
add action=mark-packet new-packet-mark=SIP_IN  chain=prerouting  in-interface=ether1-gateway  disabled=no passthrough=no \
    src-address=192.168.1.43 comment="GXV3240"
add action=mark-packet new-packet-mark=SIP_OUT chain=postrouting out-interface=ether1-gateway disabled=no passthrough=no \
    dst-address=192.168.1.43 comment="GXV3240"
add action=mark-packet new-packet-mark=SIP_IN  chain=prerouting  in-interface=ether1-gateway  disabled=no passthrough=no \
    src-address=192.168.1.45 comment="SPA2000"
add action=mark-packet new-packet-mark=SIP_OUT chain=postrouting out-interface=ether1-gateway disabled=no passthrough=no \
    dst-address=192.168.1.45 comment="SPA2000"
add action=mark-packet new-packet-mark=ELSE_IN  chain=prerouting  in-interface=ether1-gateway  disabled=no passthrough=no \
    src-address=!192.168.1.2 comment="All Else"
add action=mark-packet new-packet-mark=ELSE_OUT chain=postrouting out-interface=ether1-gateway disabled=no passthrough=no \
    dst-address=!192.168.1.2 comment="All Else"
add action=mark-packet new-packet-mark=ELSE_IN  chain=prerouting  in-interface=ether1-gateway disabled=no passthrough=yes \
    src-address=192.168.1.2 src-port=80 protocol=tcp comment="Bellman Web Server"
add action=mark-packet new-packet-mark=ELSE_OUT chain=postrouting out-interface=ether1-gateway disabled=no passthrough=yes \
    dst-address=192.168.1.2 dst-port=80 protocol=tcp comment="Bellman Web Server"
iptables -A twilio_whitelist -j ACCEPT -s 54.172.60.0/30
iptables -A twilio_whitelist -j ACCEPT -s 54.244.51.0/30
iptables -A twilio_whitelist -j ACCEPT -s 54.171.127.192
iptables -A twilio_whitelist -j ACCEPT -s 54.171.127.193
iptables -A twilio_whitelist -j ACCEPT -s 54.171.127.194
iptables -A twilio_whitelist -j ACCEPT -s 54.65.63.192
iptables -A twilio_whitelist -j ACCEPT -s 54.65.63.193
iptables -A twilio_whitelist -j ACCEPT -s 54.65.63.194
iptables -A twilio_whitelist -j ACCEPT -s 54.169.127.128
iptables -A twilio_whitelist -j ACCEPT -s 54.169.127.129
iptables -A twilio_whitelist -j ACCEPT -s 54.169.127.130
iptables -A twilio_whitelist -j ACCEPT -s 54.252.254.64
iptables -A twilio_whitelist -j ACCEPT -s 54.252.254.65
iptables -A twilio_whitelist -j ACCEPT -s 54.252.254.66
iptables -A twilio_whitelist -j ACCEPT -s 177.71.206.192
iptables -A twilio_whitelist -j ACCEPT -s 177.71.206.193
iptables -A twilio_whitelist -j ACCEPT -s 177.71.206.194
/queue tree
add name="IN" parent=global-in priority=1
add name="OUT" parent=global-out priority=1
add name="SIP_IN" packet-mark=SIP_IN parent=IN priority=2
add name="SIP_OUT" packet-mark=SIP_OUT parent=OUT priority=2
add name="ALL_ELSE_IN" packet-mark=ELSE_IN parent=IN priority=8
add name="ALL_ELSE_OUT" packet-mark=ELSE_OUT parent=OUT priority=8
== Software ==
Asterisk -- works well but pretty complicated for small installations.
I have some set up notes here [[Asterisk]].
Freeswitch -- http://www.freeswitch.org/


== Asterisk ==
== Asterisk ==
Line 50: Line 149:


http://www.limeylinux.org/
http://www.limeylinux.org/
=== Setting up ===
=== Using Digium cards for FXS/FXO ===
Zaptel modules
Use the command '''genzaptelconf -d''' to generate new config files.
Generates /etc/zaptel.conf and /etc/asterisk/zapata-channels.conf files.
==== Echo cancellation and gain settings on FXO lines ====
This page covers both of these topics:http://www.asteriskdocs.org/modules/tinycontent/content/docbook/current/docs-html/x1695.html
This one is interesting too: http://www.rowetel.com/blog/?p=18
# Edit /etc/zaptel.conf to adjust receive and xmit gain levels.
# Use '''ztmonitor ''channel''''' to see levels during a call.
# Use '''asterisk -r''' and the reload command to change settings during a call.
== Web interface ==
===Voicemail===
==== User interface ====
On delete of message, move it to Trash/
==== Administration interface ====
* Should trashed messages be deleted or archived? How often?
* Should messages marked as old be deleted or archived? How often?
* Per user control of Trash/ ?
== Service providers ==
[[Internet Telephony Service Providers]]
== Links ==
[http://www.asterisk.org/ Asterisk]
Digital signal processing and Spandsp: http://www.soft-switch.org/
The Blackfin project http://rowetel.com/ucasterisk/
Digium
Elastix
iPitomy
Qualmetrics
Trixbox

Latest revision as of 02:54, 18 October 2018

Wildsong's phone system overview

  • A small Supermicro server (Bellman) runs Asterisk on Debian
  • 2 Grandstream GXV3240 Android deskphones are the main office and workshop phones.
  • A Linksys SPA2000 directs calls to a Model 500 rotary dial phone in the studio.
  • Elastic SIP Trunking service is provided by Twilio
  • Inbound calls are directed to an extension that rings the SPA2000 phone, the GXV3240s, and sends the call back out to my cellphone via Twilio.
  • SMS messages come to Twilio and gets forwarded to my cellphone via a TWMLBIN rule (Programmable SMS).
  • The Asterisk PBX handles voicemail.

We still have a GoogleVoice number that forwards calls to the Twilio number and to Julie's cellphone. I am relying on the Asterisk forwarding to get GoogleVoice calls on my cellphone.

Hardware

PSTN gateways

Are you still using POTS lines? Really? Get rid of them and use Twilio.

If you must use POTS lines for some reason (no Internet available?) then my current recommendation would be a Sangoma Vega 50. It works flawlessly and reasonably easy to set up and configure.

I have also used Digium boards. The X100P is cheap but supports only one line. The TDM400 is good for 4 lines.

I worked with a Grandstream GXV4104 and found it to be possible to make it work but really a pain to configure.

Long ago I tried out a Linksys SPA-400 with 3 PSTN analog phone lines and an Asterisk server running on a recycled PC. It probably works fine as intended, in an all Linksys system but I was never able to get it to work reliably with Asterisk. The irony is that the SPA-400 runs Linux and Asterisk internally.

You can download the source tarball from the Linksys site.

version 1.0.0.2

It's based on Monta Vista Hardhat Linux

  • MIPS processor
  • ?? Flash
  • ?? RAM
  • Linux 2.4 kernel
  • Busybox
  • Asterisk PBX software
  • thttpd
  • /usr/sbin/lightbox controls LED's
  • dropbear ssh

After a few months of wrestling with it, we bought a TDM-400 and sold the SPA-400 on eBay.

Handsets

Ones that I have tried include

Grandstream GXV3240 (my favorite), GXV3275, DP715

Grandstream BT-100 -- cheapie

Linksys/Sipura SPA-841

Linksys SPA-941

Polycom IP-550

Polycom IP-650

What has paging / auto-answer / intercom support??? [1] The GXV324xx phones do, I have tested it and it works fine.

Some phones support multicast. incl Grandstream, Aastra, Snom, Linksys

Aastra -- The ALERT_INFO variable works for 480i, 480i CT, 9133i, 9112i firmware 1.2.x or later [2] The bugs listed for this phone seem to preclude its desirability. It's been replaced by the 9480i which is TOO EXPENSIVE

Linksys SPA-841

Snom 300 supports POE and auto answer and multicast paging http://www.snom.com/en/products/ip-phones/snom-300-ip-phone/

Network

Setting up QOS on Mikrotik

Refer to http://wiki.mikrotik.com/wiki/Voip

/ip firewall mangle
  1. First mark things as SIP
add action=mark-packet new-packet-mark=SIP_IN  chain=prerouting  in-interface=ether1-gateway  disabled=no passthrough=no \
    src-address=192.168.1.2 comment="Bellman"
add action=mark-packet new-packet-mark=SIP_OUT chain=postrouting out-interface=ether1-gateway disabled=no passthrough=no \
    dst-address=192.168.1.2 comment="Bellman"

add action=mark-packet new-packet-mark=SIP_IN  chain=prerouting  in-interface=ether1-gateway  disabled=no passthrough=no \
    src-address=192.168.1.43 comment="GXV3240"
add action=mark-packet new-packet-mark=SIP_OUT chain=postrouting out-interface=ether1-gateway disabled=no passthrough=no \
    dst-address=192.168.1.43 comment="GXV3240"
add action=mark-packet new-packet-mark=SIP_IN  chain=prerouting  in-interface=ether1-gateway  disabled=no passthrough=no \
    src-address=192.168.1.45 comment="SPA2000"
add action=mark-packet new-packet-mark=SIP_OUT chain=postrouting out-interface=ether1-gateway disabled=no passthrough=no \
    dst-address=192.168.1.45 comment="SPA2000"
add action=mark-packet new-packet-mark=ELSE_IN  chain=prerouting  in-interface=ether1-gateway  disabled=no passthrough=no \
    src-address=!192.168.1.2 comment="All Else"

add action=mark-packet new-packet-mark=ELSE_OUT chain=postrouting out-interface=ether1-gateway disabled=no passthrough=no \
    dst-address=!192.168.1.2 comment="All Else"
add action=mark-packet new-packet-mark=ELSE_IN  chain=prerouting  in-interface=ether1-gateway disabled=no passthrough=yes \
    src-address=192.168.1.2 src-port=80 protocol=tcp comment="Bellman Web Server" 

add action=mark-packet new-packet-mark=ELSE_OUT chain=postrouting out-interface=ether1-gateway disabled=no passthrough=yes \
    dst-address=192.168.1.2 dst-port=80 protocol=tcp comment="Bellman Web Server"

iptables -A twilio_whitelist -j ACCEPT -s 54.172.60.0/30 iptables -A twilio_whitelist -j ACCEPT -s 54.244.51.0/30 iptables -A twilio_whitelist -j ACCEPT -s 54.171.127.192 iptables -A twilio_whitelist -j ACCEPT -s 54.171.127.193 iptables -A twilio_whitelist -j ACCEPT -s 54.171.127.194 iptables -A twilio_whitelist -j ACCEPT -s 54.65.63.192 iptables -A twilio_whitelist -j ACCEPT -s 54.65.63.193 iptables -A twilio_whitelist -j ACCEPT -s 54.65.63.194 iptables -A twilio_whitelist -j ACCEPT -s 54.169.127.128 iptables -A twilio_whitelist -j ACCEPT -s 54.169.127.129 iptables -A twilio_whitelist -j ACCEPT -s 54.169.127.130 iptables -A twilio_whitelist -j ACCEPT -s 54.252.254.64 iptables -A twilio_whitelist -j ACCEPT -s 54.252.254.65 iptables -A twilio_whitelist -j ACCEPT -s 54.252.254.66 iptables -A twilio_whitelist -j ACCEPT -s 177.71.206.192 iptables -A twilio_whitelist -j ACCEPT -s 177.71.206.193 iptables -A twilio_whitelist -j ACCEPT -s 177.71.206.194

/queue tree
add name="IN" parent=global-in priority=1
add name="OUT" parent=global-out priority=1
add name="SIP_IN" packet-mark=SIP_IN parent=IN priority=2
add name="SIP_OUT" packet-mark=SIP_OUT parent=OUT priority=2
add name="ALL_ELSE_IN" packet-mark=ELSE_IN parent=IN priority=8
add name="ALL_ELSE_OUT" packet-mark=ELSE_OUT parent=OUT priority=8

Software

Asterisk -- works well but pretty complicated for small installations. I have some set up notes here Asterisk.

Freeswitch -- http://www.freeswitch.org/

Asterisk

You might want to use an IDE/CF adapter that can hold two CF cards. This way you could stick in a smaller second card -say- 32 or 64MB and mount stuff like /etc/asterisk, /var/log, /var/run and voicemail etc on that one, possibly leaving the main card mounted read-only for most of the time.

http://www.limeylinux.org/

Setting up

Using Digium cards for FXS/FXO

Zaptel modules

Use the command genzaptelconf -d to generate new config files. Generates /etc/zaptel.conf and /etc/asterisk/zapata-channels.conf files.

Echo cancellation and gain settings on FXO lines

This page covers both of these topics:http://www.asteriskdocs.org/modules/tinycontent/content/docbook/current/docs-html/x1695.html

This one is interesting too: http://www.rowetel.com/blog/?p=18

  1. Edit /etc/zaptel.conf to adjust receive and xmit gain levels.
  2. Use ztmonitor channel to see levels during a call.
  3. Use asterisk -r and the reload command to change settings during a call.

Web interface

Voicemail

User interface

On delete of message, move it to Trash/

Administration interface

  • Should trashed messages be deleted or archived? How often?
  • Should messages marked as old be deleted or archived? How often?
  • Per user control of Trash/ ?

Service providers

Internet Telephony Service Providers

Links

Asterisk

Digital signal processing and Spandsp: http://www.soft-switch.org/

The Blackfin project http://rowetel.com/ucasterisk/


Digium

Elastix

iPitomy

Qualmetrics

Trixbox