Asterisk 1.8 package



  • Hello ,
    I am using Asterisk package in the new Pcengines APU board with Pfsense 2.1 .
    I am searching to use Codec G729  ?  there is someone who try it?

    Regards

    Daniel



  • I think i need to recompile the sources  from here http://asterisk.hosting.lv/ 
    in a FreeBSD 8.0 system , with the linux compatibility ( Pfsense 2.1 doenst)

    Tell me if i am in the right way !!

    Thanks for your help

    Regards

    Daniel



  • Hi All,

    Does somebody tried the odbc connector from pfsense to another host?
    I'm trying to configure it (to use a remote mysql server as dialplan backend) but can't configure properly the odbc on pfsense.
    After adding the driver and the DSN, with isql I receive segmentation fault.
    It is a missconfiguration or bug?



  • I have a IPSEC VPN connections between 2 locations.

    Location 1 Has a pfsense router (10.0.1.254) with a dedicated Asterisk server (10.0.1.2) behind the routers LAN port.

    Location 2 is a pfSense Netgate router with Asterisk installed on the router (10.0.9.254)

    At location 2 anything behind the Netgate router LAN port (10.0.9.254) ipsec traffic travels to Location 1 (10.0.1.0/24) fine with out issues. But from inside the Netgate router (10.0.9.254) either via trying to ping in the GUI or ssh the Location 1's network (10.0.1.0/24)  no packetes travel down the VPN.

    So my issues is that I have short codes (ie *80) to dial the two locations but since Asterisk is not using the VPN tunnel on the Location 2 Netgate router (10.0.9.254) they time out.

    I need to find out how to get Asterisk from Location 2 to communicate down the VPN. Right now it simply does not even see the 10.0.1.0/24 network at location 1 from inside the router.

    Any idea how to get inner office extension to work over vpn? My other locatios with dedicated Asterisk servers behind the router/firewall work fine. I can not get any location with asterisk as an add on to register as a sip peer over the vpn



  • Is anyone else having issues installing the Asterisk package?

    pfSense version: 2.1.5-RELEASE (amd64)
    Asterisk package details: Beta - 1.8.26.1 pkg v0.3.3 - platform: 2.0

    Beginning package installation for Asterisk .
    Downloading package configuration file… done.
    Saving updated package information... done.
    Downloading Asterisk and its dependencies...
    Checking for package installation...
    Downloading https://files.pfsense.org/packages/amd64/8/All/asterisk-1.8.26.1-amd64.pbi ...  (extracting)
    Verifying Checksum...SKIP_ARCHLINES: 62
    Archive checksum: 58be47139e05fac3450d80a4b884ba9c89015eb775d7af0e22880b7f382f991c
    Saved checksum: b2a19cd1ee8711e4794554d58c065a9471ab3637d5b1b1340e2bd0060ac648d5
    pbi_add: /tmp/apkg_asterisk-1.8.26.1-amd64.pbi failed checksum, the archive may be corrupt.
    of asterisk-1.8.26.1-amd64 failed!

    Installation aborted.Removing package…
    Starting package deletion for asterisk-1.8.26.1-amd64...done.
    Removing Asterisk components...
    Menu items... done.
    Services... done.
    Loading package instructions...
    Include file asterisk.inc could not be found for inclusion.
    Deinstall commands...
    Not executing custom deinstall hook because an include is missing.
    Removing package instructions...done.
    Auxiliary files... done.
    Package XML... done.
    Configuration... done.
    done.
    Failed to install package.

    Installation halted.

    Even though it's only meant for pfSense 2.0, is that because I'm running 2.1.5 the issue here?



  • Hello,

    I'm not installing it on AMD but on my Alix system I also run pFsense 2.1.5
    As you maybe read in my earlier posts I had a lot of trouble installing that new Asterisk version. Main cause was storage:

    • short of storage (this version consumes 580GB)
    • speed of storage. On a low speed CF card install nearly always failed and had to be resumed.

    But finally it succeeded and runs ok.



  • @chercheur:

    Main cause was storage:

    • short of storage (this version consumes 580GB)

    Is that a typo? 580 gigabytes?



  • The Asterisk 1.8 package is not working\installing correctly under PFsense 2.2 i386 nanobsd (4 Gig dist) :(
    I am trying to install on an Alix board (alix2d13).
    Installing through the web interface does not seem to be the right way because this takes so long the web browser times out.
    So I also tried to install the package using the console (pfSsh.php playback installpkg Asterisk)
    The package seems to install correctly, but after the installation is done I am unable to start the service using de webinterface.
    When starting Asterisk using the console by starting /usr/pbi/bin/asterisk as root, the service starts and Asterisk is running fine. It Does not seem to be an Asterisk configuration issue (this also happens with de default Asterisk config)



  • Some additional info
    It looks like de asterisk.inc file is not executed correctly
    After a reboot, /var/log/asterisk for example is not created

    Here also some logging after the manual start as root from the console

    [Jan 26 20:34:01] NOTICE[-1] cdr.c: CDR simple logging enabled.
    [Jan 26 20:34:02] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:02] NOTICE[-1] loader.c: 162 modules will be loaded.
    [Jan 26 20:34:02] WARNING[-1] loader.c: Error loading module 'res_snmp.so': Shared object "libperl.so" not found, required by "libnetsnmpmibs.so.30"
    [Jan 26 20:34:03] WARNING[-1] res_fax.c: 'modems' setting 'V17,V27,V29' is no longer accepted with 'minrate' setting 2400
    [Jan 26 20:34:03] WARNING[-1] res_fax.c: 'minrate' has been reset to 4800, please update res_fax.conf.
    [Jan 26 20:34:03] NOTICE[-1] pbx_lua.c: Lua PBX Switch loaded.
    [Jan 26 20:34:03] WARNING[-1] loader.c: Error loading module 'res_snmp.so': Shared object "libperl.so" not found, required by "libnetsnmpmibs.so.30"
    [Jan 26 20:34:03] WARNING[-1] loader.c: Module 'res_snmp.so' could not be loaded.
    [Jan 26 20:34:04] NOTICE[-1] res_smdi.c: No SMDI interfaces are available to listen on, not starting SMDI listener.
    [Jan 26 20:34:04] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:04] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:04] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:04] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:04] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:04] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:04] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:04] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:04] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:04] WARNING[-1] db.c: Database unavailable
    [Jan 26 20:34:04] NOTICE[-1] cel_custom.c: No mappings found in cel_custom.conf. Not logging CEL to custom CSVs.
    [Jan 26 20:34:06] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:06] WARNING[-1] db.c: Database unavailable
    [Jan 26 20:34:06] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory
    [Jan 26 20:34:06] WARNING[-1] db.c: Database unavailable
    [Jan 26 20:36:11] WARNING[-1] db.c: Unable to open Asterisk database '/var/db/asterisk/astdb': No such file or directory



  • @matthijs:

    The Asterisk 1.8 package is not working\installing correctly under PFsense 2.2 i386 nanobsd (4 Gig dist) :(

    I did not had time to look asterisk package yet.

    these "missing" folder maybe under /usr/pbi dir.

    If you know how to symlinks dirs on unix systems, you may get it running.



  • Hi guys,

    It works if you log in by ssh shell and just type in "asterisk", but log file is not seen by the web interface.
    I'll have a look at this in the next few days, shouldn't be hard to fix.

    By the way, marcelloc, do you think it would be possible to have a newer asterisk package for 2.2?
    I'm thinking of Asterisk v11.10 at least, with extra support for the super-high quality and open opus audio codec.



  • I changed

    $replace[2]='astdbdir => /tmp';

    in /usr/local/pkg/asterisk.inc

    the astdb file gets created there after a reboot
    Unfortunatly the asterisk service is still not started automaticly after a reboot and I am also still unable to manualy start the service by using the webinterface (still have to start /usr/pbi/bin/asterisk via the ssh console)

    After starting Asterisk I still see the following in the asterisk log
    (Maybe some issues are related to my specific asterisk configuration)

    ==>

    [Jan 27 10:15:59] NOTICE[-1] cdr.c: CDR simple logging enabled.
    [Jan 27 10:15:59] NOTICE[-1] loader.c: 162 modules will be loaded.
    [Jan 27 10:16:00] WARNING[-1] loader.c: Error loading module 'res_snmp.so': Shared object "libperl.so" not found, required by "libnetsnmpmibs.so.30"
    [Jan 27 10:16:00] WARNING[-1] res_fax.c: 'modems' setting 'V17,V27,V29' is no longer accepted with 'minrate' setting 2400
    [Jan 27 10:16:00] WARNING[-1] res_fax.c: 'minrate' has been reset to 4800, please update res_fax.conf.
    [Jan 27 10:16:00] NOTICE[-1] pbx_lua.c: Lua PBX Switch loaded.
    [Jan 27 10:16:01] WARNING[-1] loader.c: Error loading module 'res_snmp.so': Shared object "libperl.so" not found, required by "libnetsnmpmibs.so.30"
    [Jan 27 10:16:01] WARNING[-1] loader.c: Module 'res_snmp.so' could not be loaded.
    [Jan 27 10:16:01] NOTICE[-1] res_smdi.c: No SMDI interfaces are available to listen on, not starting SMDI listener.
    [Jan 27 10:16:01] NOTICE[-1] cel_custom.c: No mappings found in cel_custom.conf. Not logging CEL to custom CSVs.



  • Disabled the loading of res_snmp.so
    And changed minrate' setting to 4800 in res_fax.conf
    (wich I guess was specific for my configuration)
    No more logging errors\issues now

    Asterisk still not  starting after a reboot (any hint on where to seach for to fix this ?)
    If I run asterisk via the webinterface (diagnostics ==> command prompt) Asterisk also starts.



  • I'm not sure why the Asterisk is not loading at boot. PFSense is my first experience with BSD.

    I did have a thought for a workaround though, have you considered cron? Using the special keyword @reboot you could run a custom start up script.



  • @robi:

    By the way, marcelloc, do you think it would be possible to have a newer asterisk package for 2.2?
    I'm thinking of Asterisk v11.10 at least, with extra support for the super-high quality and open opus audio codec.

    Sorry I was not following very accurately.
    I suffer from the same issues and revert back to pfsense 2.1.5.

    Is there any way to contact the person/team who created the previous package ?



  • marcelloc is the author, contact via this forum/topic.



  • Hi All,

    "/var/run" is cleaned at startup and hence "/var/run/asterisk" needs to be chowned in the asterisk init script. Here is a quick fix (amd64) :

    1- Edit "/usr/pbi/asterisk-amd64/local/etc/rc.d/asterisk" and after the line "reload_cmd=asterisk_reload", add the following one :
    start_precmd="chown -R asterisk:wheel /var/run/asterisk"

    2- Create the missed link

    ln /usr/pbi/asterisk-amd64/local/etc/rc.d/asterisk /usr/local/etc/rc.d/asterisk

    3- Start asterisk or reboot

    /usr/local/etc/rc.d/asterisk start

    Regards,



  • Hi Bastion,

    I tried your solution but Asterisk is not starting after a reboot in my situation (Alix board i386)
    (I have to manualy start it)



  • Hi matthijs,

    I've tested it on amd64/i386 with 2.2 and 2.2.1 many times, and had it working on all tests.
    Did you try it on a fresh install  !!?

    Cordially,



  • Hi Bastion, strange, it worked after a second reboot (I didnt change anything)



  • Rebooted again and it failed again to autostart, it sometimes works sometimes not
    Did also a clean install, same behaviour, did you also test it on a nanobsd i386 (Alix board) ?
    Because sometimes I also have the issue that OpenVPN fails to autostart
    The Alix board is quite slow at things, so maybe things are not proparly stopped at a shut down\reboot, or things time-out or something during startup.


  • Banned

    I bet about 99% of the inexplicable package issues would be solved by abandoning the PBI packaging POS. Really hope it happens very soon.

    (And pretty much can understand that people's motivation to maintain packages in their free time is about zero at this point. Most of time is wasted on debugging the packaging, instead of development and features.  >:( )



  • Rebooted again and everything started succesfully
    This time I waited a little longer before logging into the webinterface.
    Maybe the problem is related with logging into soon after a reboot (interfering with processes still starting in the background)



  • matthijs,

    After rebooting, pfSense normally needs a bit "patience/time" to autostart all services …

    P.S : Agree ! doktornotor  ;)



  • Package seems to be broken..

    install on new 2.2.2 -> asterisk dont start

    after apply Bastions dirty workaround ends up with -> no asterisk_enable in rc.conf after manual add-in in rc.conf -> pam_error



  • Update:

    after make a new /etc/rc.asterisk an put asterisk_enable=YES into it … it works again



  • I just installed Asterisk on PfSense 2.2.2.
    I ran into some of the problems mentioned in this thread.
    These are my notes on solutions to the problems.

    1. Installation

    Installation takes a long, long time (on my box, about 24.5 minutes AFTER download is complete).
    You can't see what's going on in the web UI.
    I recommend enabling ssh, logging in to ssh and issuing the following command at the ssh command prompt:

    pfSsh.php playback installpkg Asterisk

    After a few minutes it will say 'Done' and the cursor will remain at the end of that line.
    It isn't done: it's just done with the download.
    Wait until it's really done – you'll know from the console output. Be patient.

    I'm not sure if this method installs the PfSense GUI stuff.
    If, after this step, you don't have an Asterisk entry in the PfSense Status menu, go to
    System->Packages and under Installed Packages->Asterisk click on the 'xml' button.

    2. Post-install fixes

    First, do this stuff:

    https://forum.pfsense.org/index.php?topic=47210.msg490067#msg490067

    Next, to fix the Asterisk log warnings about res_snmp.so and libperl.so, do the following:

    • under Diagnostics->NanoBSD set Media Read/Write status to Read/Write

    • log in with ssh, start a shell and cd to /usr/pbi/asterisk-<arch>/local/lib
          note: replace <arch>with i386 or amd64, depending on your system

    • issue the following command at the ssh command prompt:
          ln -s perl5/5.18/mach/CORE/libperl.so

    • under Diagnostics->NanoBSD set Media Read/Write status to Read-Only

    • under Status->Asterisk->Log press 'Clear log'

    • under Status->Asterisk->Commands press 'Restart Asterisk'

    • under Status->Asterisk->Log check the log; there should be no WARNINGs

    Hope this helps. I wanted to summarize everything in one place.</arch></arch>



  • Hi,

    first thanks for the hard work everyone is putting into this, I migrated over to Pfsense several months ago and I've come to enjoy the flexibility available. Now after the Asterisk update a couple of months ago the module chan_sccp.so no longer works, I was relying on a pre-built deb package. Can someone please build the module to support the latest build of pfsense and asterisk.

    Thanks in advance.



  • The package installation failed on pfsense 2.2.3 i386  :-\ help plz!!!



  • I Have the Asterisk Package Installed (0.3.1) on my pfSense system (2.2.2-RELEASE (amd64)) but there does not seem to be any of the modules installed. The config file suggests "/usr/local/lib/asterisk/modules" would be the place, but that directory does not exist.

    This means things like musiconhold won't work.

    Have I missed something out when installing this package?

    Regards

    Ben



  • @ben.suffolk:

    I Have the Asterisk Package Installed (0.3.1) on my pfSense system (2.2.2-RELEASE (amd64)) but there does not seem to be any of the modules installed. The config file suggests "/usr/local/lib/asterisk/modules" would be the place, but that directory does not exist.

    This means things like musiconhold won't work.

    Have I missed something out when installing this package?

    Regards

    Ben

    I have the same package version installed on the same pfSense version, but i386 instead of amd64.
    Yes, according to asterisk.conf the modules directory is /usr/local/lib/asterisk/modules.
    No, that directory doesn't exist on my system either.
    But Asterisk works fine.
    If no modules were being loaded Asterisk would be basically dead.
    Are you speculating that something will not work if you attempt it, or have you actually observed that Asterisk does not work?

    For reference du -h /usr/pbi/asterisk-i386 reports 472MB. amd64 should be somewhat larger.

    EDIT:
    To see what modules are loaded issue the following command at the Asterisk CLI prompt:

    module show


  • Banned

    The asterisk.conf references the chrooted paths. (For details on PBI junk, search this forum…)



  • @carlm:

    If no modules were being loaded Asterisk would be basically dead.
    Are you speculating that something will not work if you attempt it, or have you actually observed that Asterisk does not work?

    For reference du -h /usr/pbi/asterisk-i386 reports 472MB. amd64 should be somewhat larger.

    EDIT:
    To see what modules are loaded issue the following command at the Asterisk CLI prompt:

    module show

    Your right, lots of modules are loaded. What does not work for me is the music on hold command. Thats when I started looking and found the modules directory missing.



  • Please help me to install Asterisk-GUI on PFsense. I'm a newbie on this. My Pfsense box version is:
    2.2.1-RELEASE (amd64)
    FreeBSD 10.1



  • @nguyentan1980:

    Please help me to install Asterisk-GUI on PFsense. I'm a newbie on this. My Pfsense box version is:
    2.2.1-RELEASE (amd64)
    FreeBSD 10.1

    I assume you are referring to the old Asterisk GUI developed by Digium.
    Before doing anything take a look at this page:

    https://wiki.asterisk.org/wiki/display/AST/Asterisk+GUI

    There is no pfSense package for Asterisk GUI. Someone would have to make one, assuming it would be practical to run Asterisk GUI on pfSense (maybe not).

    Alternately, Asterisk GUI doesn't need to run on the same machine that Asterisk runs on – it communicates with Asterisk via AMI. A more practical approach would be to build and run Asterisk GUI on a separate UNIX/Linux box, if you have one.

    Note: I have never used Asterisk GUI. If you read the web page linked above you'll know as much about it as I do.

    Personally, I just configured Asterisk manually. Now I know what goes on "under the hood."



  • Thanks Carlm for your advice.



  • Another one of many reasons to stick with 2.1.5

    If you are serious about VoIP, 2.1.5 has working limiters, working asterisk (nice redundancy even if you do/should have another box or VM behind pfsense)

    Strange, too , how hard it is to find old versions…..

    :( >:( >:(



  • @msmith9xr4:

    Strange, too , how hard it is to find old versions…..

    Ok, so there isn't a big button on the download page saying 'old versions', but is it really that hard to look in the folder marked 'old' on the download mirror?
    There are a few situations where you might want 2.1.5, but for most people 2.2.4 is better.



  • I started out w/ v 0.3.1 of the Asterisk package.
    Others have commented that this version is much larger than the previous version.
    Anyone know what accounts for the size increase?
    Anything to do with the gcc48 stuff? Is that stuff necessary?

    Whenever I have to reinstall Asterisk (e.g., restore a previous config) it takes about 25 minutes to untar the Asterisk .pbi. I'm running nanoBSD i386 with a SanDisk 8GB Class 4 microSD card. Was about the same with a Kingston Class 10 card. A much smaller .pbi would really help, unless there's a way to speed up the untar operation (permanent R/W on nanoBSD??).

    Thanks!



  • Until pfSense 2.3 some packages will work better(and smaller) if you isntall via gui and then via console remove the pbi and install the freebsd package via pkg install


Log in to reply