Author Topic: Lmce asterisk 10.04 linksys SPA3102  (Read 11213 times)

kalios

  • Newbie
  • *
  • Posts: 14
    • View Profile
Lmce asterisk 10.04 linksys SPA3102
« on: April 15, 2012, 01:13:14 am »
After the latest upgrades, my asterisk seem to install without hiccups. I have here a Linksys SPA3102. Does anyone have any idea on how to configure it to run with the new Asterisk configuration

sambuca

  • Guru
  • ****
  • Posts: 462
    • View Profile
Re: Lmce asterisk 10.04 linksys SPA3102
« Reply #1 on: April 15, 2012, 08:46:36 pm »
It depends on how you want to use it? Are you using it as an adapter to connect a analog phone to LMCE, or are you connection LMCE to your analog phone line?

Both scenarios are described in the wiki, iirc.

br,
sambuca

kalios

  • Newbie
  • *
  • Posts: 14
    • View Profile
Re: Lmce asterisk 10.04 linksys SPA3102
« Reply #2 on: April 16, 2012, 02:00:22 am »
They apply for 8.10 Freepbx. i was under the understanding that freepbx is no longer being used for 10.04 and that asterisk is all done through a sql database?

Ive attempted following the wiki regarding setting up the SPA for linuxmce however i can not add SIP trunks under Advanced>configuration>phone setup. The Url is not found.

Also i would like to set it up so that LMCE uses my analog phone.

Thanks for the reply
« Last Edit: April 16, 2012, 02:03:18 am by kalios »

sambuca

  • Guru
  • ****
  • Posts: 462
    • View Profile
Re: Lmce asterisk 10.04 linksys SPA3102
« Reply #3 on: April 16, 2012, 07:58:14 am »
You're correct, freepbx is not used anymore, and the Advanced -> Configuration -> Phone Setup menu should be removed. Instead, use Wizard - devices - phone lines to set up trunks.
Choose the SPA protocol, and iirc; the username and phone number needs to be equal. It is quite simple.

The SPA configuration is more difficult though, but that should be the same as for 810, so the wiki article still applies.

- sambuca

kalios

  • Newbie
  • *
  • Posts: 14
    • View Profile
Re: Lmce asterisk 10.04 linksys SPA3102
« Reply #4 on: April 20, 2012, 12:27:31 am »
Thanks Sambuca, ill give it a go

pw44

  • Addicted
  • *
  • Posts: 666
    • View Profile
Re: Lmce asterisk 10.04 linksys SPA3102
« Reply #5 on: September 12, 2012, 09:11:49 pm »
Hya,
i' m having troubles to make spa3102 work with the lmce 10.04.
On my previous installation, 8.10, it worked like a charm, but now, it seems that they don' t like each other.
spa3102 replies fail to register to lmce 10.04.

Name                  spa3102   
Enabled                  yes (marked)
Incoming FAX line    no (not marked)   
Prefix                  9
Username *          spa3102             The username to access provider's service (not webpage), sometimes is the phone number
Password *          lmce                   The password to access provider's service (not webpage)
Phone number *      2122499999   The phone number assigned tAs o you by provider
Host *             192.168.80.30    The host to register your asterisk with provider
Protocol *                SIP

asterisk 1.8.11-1 also dies when trying to call from one extension to another (2 cisco 7970 phones).

As freepbx is no longer available, i also kindly ask how to customize the dial plan and other parameters, like register string and so on...

If one of the asterisk gurus can give me a help, i would greatly appreciate, as i need the pstn line and also my 2 other voip trunks....

TIA,

Paulo

cfernandes

  • Guru
  • ****
  • Posts: 359
    • View Profile
    • my company web site
Re: Lmce asterisk 10.04 linksys SPA3102
« Reply #6 on: September 12, 2012, 09:20:18 pm »
Paulo ,

i my case  i have a ht-503 

and my conf is

Name                  ht503   
Enabled                  yes (marked)
Incoming FAX line    no (not marked)   
Prefix                  9
Username *          ht503             The username to access provider's service (not webpage), sometimes is the phone number
Password *          lmce                   The password to access provider's service (not webpage)
Phone number *      3121020606   The phone number assigned tAs o you by provider
Host *             dynamic    The host to register your asterisk with provider
Protocol *                SPA


and work  like a charm

pw44

  • Addicted
  • *
  • Posts: 666
    • View Profile
Re: Lmce asterisk 10.04 linksys SPA3102
« Reply #7 on: September 13, 2012, 01:50:30 am »
Hya,
i did change at the admin page the host to "dynamic" and protocol to "SPA".
Nothing changed, spa3102 showing
Code: [Select]
PSTN Line Status
Hook State: On Line Voltage: 66 (V)
Loop Current: 0.0 (mA) Registration State: Failed

So i did access the mysql asterisk table and under sipdevices, i've found that port was set to 5060, when it should be 5061 (see: http://wiki.linuxmce.org/index.php/Linksys_SPA3102). My older 8.10 also was configured to port 5061
Code: [Select]
peer details:
allow=ulaw
canreinvite=no
context=from-trunk
dtmfmode=rfc2833
host=dynamic
incominglimit=1
nat=never
port=5061
qualify=yes
secret=lmce
type=friend
username=spa3102

So, i did change 5060 to 5061.

Code: [Select]
Host: localhost
Database: asterisk
Generation Time: Sep 12, 2012 at 08:35 PM
Generated by: phpMyAdmin 3.3.2deb1 / MySQL 5.1.63-0ubuntu0.10.04.1
SQL query: SELECT * FROM `sip_devices` LIMIT 0, 30 ;
Rows: 2
id name context callingpres deny permit secret md5secret remotesecret transport host nat type accountcode amaflags callgroup callerid defaultip dtmfmode fromuser fromdomain insecure language mailbox pickupgroup qualify regexten rtptimeout rtpholdtimeout setvar disallow allow fullcontact ipaddr port defaultuser subscribecontext directmedia trustrpid sendrpid progressinband promiscredir useclientcode callcounter busylevel allowoverlap allowsubscribe allowtransfer ignoresdpversion template videosupport maxcallbitrate rfc2833compensate session-timers session-expires session-minse session-refresher t38pt_usertpsource outboundproxy callbackextension registertrying timert1 timerb qualifyfreq contactpermit contactdeny lastms regserver regseconds useragent
1 200 from-internal allowed_not_screened NULL NULL stsnt6114jeps7r3 NULL NULL udp,tcp NULL NULL friend NULL NULL NULL device <200> NULL NULL NULL NULL NULL NULL 200@device NULL NULL NULL NULL NULL NULL NULL alaw;ulaw NULL NULL 5061 200 NULL no NULL NULL NULL NULL NULL NULL NULL yes yes yes no NULL no NULL yes accept 1800 90 uas NULL NULL NULL yes 500 NULL 120 NULL NULL 0 NULL 0 NULL
2 2122498618 from-trunk allowed_not_screened NULL NULL lmce NULL NULL udp,tcp dynamic never friend NULL NULL NULL 2122498618 NULL NULL spa3102 dynamic port,invite NULL NULL NULL yes NULL NULL NULL NULL NULL alaw;ulaw NULL NULL 5061 spa3102 NULL no NULL NULL NULL NULL NULL NULL NULL yes yes yes no NULL no NULL yes accept 1800 90 uas NULL NULL NULL yes 500 NULL 120 NULL NULL 0 NULL 0 NULL

Then i changed the protocol to SIP, and the asterisk log shows:
Code: [Select]
[Sep 12 21:06:36] ERROR[23452]: netsock2.c:263 ast_sockaddr_resolve: getaddrinfo("dynamic", "(null)", ...): No address associated with hostname
[Sep 12 21:06:36] WARNING[23452]: acl.c:582 resolve_first: Unable to lookup 'dynamic'
[Sep 12 21:06:36] WARNING[23452]: acl.c:711 ast_ouraddrfor: Cannot connect
[Sep 12 21:06:36] ERROR[23452]: chan_sip.c:3808 __sip_reliable_xmit: Serious Network Trouble; __sip_xmit returns error for pkt data
[Sep 12 21:06:36] NOTICE[23452]: chan_sip.c:13135 sip_reg_timeout:    -- Registration for 'spa3102@dynamic' timed out, trying again (Attempt #7)

So, it did not work either.

Anyone do have the spa3102 working with lmce 1004?

Another question, regarding the dial rules, outbound, trunk sequences, registration string, etc: is there a way to define the dial rules? trunk sequence? registration string?

Thx in advance!

Paulo

« Last Edit: September 13, 2012, 02:20:37 am by pw44 »

gbutters

  • Regular Poster
  • **
  • Posts: 19
    • View Profile
Re: Lmce asterisk 10.04 linksys SPA3102
« Reply #8 on: September 13, 2012, 03:08:40 am »
Hya,
i did change at the admin page the host to "dynamic" and protocol to "SPA".
Nothing changed, spa3102 showing
Code: [Select]
PSTN Line Status
Hook State: On Line Voltage: 66 (V)
Loop Current: 0.0 (mA) Registration State: Failed

So i did access the mysql asterisk table and under sipdevices, i've found that port was set to 5060, when it should be 5061 (see: http://wiki.linuxmce.org/index.php/Linksys_SPA3102). My older 8.10 also was configured to port 5061
Code: [Select]
peer details:
allow=ulaw
canreinvite=no
context=from-trunk
dtmfmode=rfc2833
host=dynamic
incominglimit=1
nat=never
port=5061
qualify=yes
secret=lmce
type=friend
username=spa3102

So, i did change 5060 to 5061.

Code: [Select]
Host: localhost
Database: asterisk
Generation Time: Sep 12, 2012 at 08:35 PM
Generated by: phpMyAdmin 3.3.2deb1 / MySQL 5.1.63-0ubuntu0.10.04.1
SQL query: SELECT * FROM `sip_devices` LIMIT 0, 30 ;
Rows: 2
id name context callingpres deny permit secret md5secret remotesecret transport host nat type accountcode amaflags callgroup callerid defaultip dtmfmode fromuser fromdomain insecure language mailbox pickupgroup qualify regexten rtptimeout rtpholdtimeout setvar disallow allow fullcontact ipaddr port defaultuser subscribecontext directmedia trustrpid sendrpid progressinband promiscredir useclientcode callcounter busylevel allowoverlap allowsubscribe allowtransfer ignoresdpversion template videosupport maxcallbitrate rfc2833compensate session-timers session-expires session-minse session-refresher t38pt_usertpsource outboundproxy callbackextension registertrying timert1 timerb qualifyfreq contactpermit contactdeny lastms regserver regseconds useragent
1 200 from-internal allowed_not_screened NULL NULL stsnt6114jeps7r3 NULL NULL udp,tcp NULL NULL friend NULL NULL NULL device <200> NULL NULL NULL NULL NULL NULL 200@device NULL NULL NULL NULL NULL NULL NULL alaw;ulaw NULL NULL 5061 200 NULL no NULL NULL NULL NULL NULL NULL NULL yes yes yes no NULL no NULL yes accept 1800 90 uas NULL NULL NULL yes 500 NULL 120 NULL NULL 0 NULL 0 NULL
2 2122498618 from-trunk allowed_not_screened NULL NULL lmce NULL NULL udp,tcp dynamic never friend NULL NULL NULL 2122498618 NULL NULL spa3102 dynamic port,invite NULL NULL NULL yes NULL NULL NULL NULL NULL alaw;ulaw NULL NULL 5061 spa3102 NULL no NULL NULL NULL NULL NULL NULL NULL yes yes yes no NULL no NULL yes accept 1800 90 uas NULL NULL NULL yes 500 NULL 120 NULL NULL 0 NULL 0 NULL

Then i changed the protocol to SIP, and the asterisk log shows:
Code: [Select]
[Sep 12 21:06:36] ERROR[23452]: netsock2.c:263 ast_sockaddr_resolve: getaddrinfo("dynamic", "(null)", ...): No address associated with hostname
[Sep 12 21:06:36] WARNING[23452]: acl.c:582 resolve_first: Unable to lookup 'dynamic'
[Sep 12 21:06:36] WARNING[23452]: acl.c:711 ast_ouraddrfor: Cannot connect
[Sep 12 21:06:36] ERROR[23452]: chan_sip.c:3808 __sip_reliable_xmit: Serious Network Trouble; __sip_xmit returns error for pkt data
[Sep 12 21:06:36] NOTICE[23452]: chan_sip.c:13135 sip_reg_timeout:    -- Registration for 'spa3102@dynamic' timed out, trying again (Attempt #7)

So, it did not work either.

Anyone do have the spa3102 working with lmce 1004?

Another question, regarding the dial rules, outbound, trunk sequences, registration string, etc: is there a way to define the dial rules? trunk sequence? registration string?

Thx in advance!

Paulo



Name                  spa3102   
Enabled                  yes (marked)
Incoming FAX line    no (not marked)   
Prefix                  9
Username *          3121020606             The username to access provider's service (not webpage), sometimes is the phone number
Password *          lmce                   The password to access provider's service (not webpage)
Phone number *      3121020606   The phone number assigned tAs o you by provider
Host *             dynamic    The host to register your asterisk with provider
Protocol *                SPA


Username and phone number have to be the same.

pw44

  • Addicted
  • *
  • Posts: 666
    • View Profile
Re: Lmce asterisk 10.04 linksys SPA3102
« Reply #9 on: September 13, 2012, 03:54:13 am »
Name                  spa3102   
Enabled                  yes (marked)
Incoming FAX line    no (not marked)   
Prefix                  9
Username *          3121020606             The username to access provider's service (not webpage), sometimes is the phone number
Password *          lmce                   The password to access provider's service (not webpage)
Phone number *      3121020606   The phone number assigned tAs o you by provider
Host *             dynamic    The host to register your asterisk with provider
Protocol *                SPA


Username and phone number have to be the same.


Thx for the answer, but using protocol SPA, not even tries to register. spa3102 shows:
Code: [Select]
PSTN Line Status
Hook State: On Line Voltage: 65 (V)
Loop Current: 0.0 (mA) Registration State: Failed
Last Registration At: 0/0/0 00:00:00 Next Registration In: 54 s

Thx, but it did not work. Anyone?

cfernandes

  • Guru
  • ****
  • Posts: 359
    • View Profile
    • my company web site
Re: Lmce asterisk 10.04 linksys SPA3102
« Reply #10 on: September 13, 2012, 12:21:19 pm »
Paulo ,


i think  that on you version  the script  db_phone_config.sh  is old

can you get the new on svn


http://svn.linuxmce.org/svn/branches/LinuxMCE-1004/src/lmce-asterisk/root/usr/pluto/bin/db_phone_config.sh

Carlos

pw44

  • Addicted
  • *
  • Posts: 666
    • View Profile
Re: Lmce asterisk 10.04 linksys SPA3102
« Reply #11 on: September 13, 2012, 12:51:26 pm »
Paulo ,

i think  that on you version  the script  db_phone_config.sh  is old

can you get the new on svn


http://svn.linuxmce.org/svn/branches/LinuxMCE-1004/src/lmce-asterisk/root/usr/pluto/bin/db_phone_config.sh

Carlos

Carlos,
thx for the info. Shouldn't this script be in the lastest DVD, which was the one i downloaded 3 days ago?
I will give a try later and report.
BR,
Paulo