Exosym

Member

Last active 11 years ago

  1. 11 years ago
    Mon Apr 1 23:52:58 2013
    Exosym started the conversation Monitoring extensions on multiple servers.

    Hello all!

    This is a combination question / tutorial for how to monitor extensions on multiple servers (since the way we have it set up is almost certainly not ideal). My colleague and I set out today to try to get FOP2 to be able to monitor extensions on other FreePBX servers. Referring to the documentation at http://www.fop2.com/documentation-confi ... ngMultiple showed that it should be as simple as adding additional parameters in /usr/local/fop2/fop2.cfg, specifically:

    manager_host =
    manager_port =
    manager_user =
    manager_secret =

    for each other server you want to monitor. However, it's not quite that easy. While that does connect you to the AMI of the other server (assuming you use remote_mgr as the manager_user; we couldn't get it to work with admin), it doesn't make any buttons for you to monitor. The script /usr/local/fop2/autoconfig-buttons-freepbx.sh won't make the buttons either, even if you define buttons in /usr/local/fop2/buttons_custom.cfg (which gets run at the end of /usr/local/fop2/autoconfig-buttons-freepbx.sh if it exists)... or rather, it will (maybe, still not sure on that), but you can't see it because it's not part of any groups, and since users see what they see on FOP2 based on what groups they're allowed to view, it will never show up for anyone. So you need to make it part of a group, which gets done in /usr/local/fop2/autoconfig-users-freepbx.sh.

    Basically, you can see what happens when you run /usr/local/fop2/autoconfig-users-freepbx.sh (or /usr/local/fop2/autoconfig-buttons-freepbx.sh for that matter); it just generates a bunch of text from God knows where (it's all detailed in the script itself but there was no way I could read it all). Presumably, when you restart FOP2 with

    service fop2 restart

    it runs /usr/local/fop2/fop2.cfg, which in turn runs /usr/local/fop2/autoconfig-users-freepbx.sh, which in turn runs /usr/local/fop2/autobuttons.cfg, which all that does is run /usr/local/fop2/autoconfig-buttons-freepbx.sh, which basically generates a ton of specially formatted text and sends it off somewhere, somehow. So at this point all we knew was that, based on the text output of /usr/local/fop2/autoconfig-users-freepbx.sh, groups were probably defined there. So in our case, what we did was defined a group manually at the end of that script and then manually defined a user at the end of that script that belonged to that group. Basically, in /usr/local/fop2/autoconfig-users-freepbx.sh:

    [original_script]
    Lots of scripting
    [/original_script]
    group=allLocalAndRemote:[Put all the extensions you'd like to monitor here, both local and remote, in the format of SIP/1234]
    user=[extension]:[password]:[FOP2permissions]:allLocalAndRemote

    So yours might look like:

    [original_script]
    Lots of scripting
    [/original_script]
    group=allLocalAndRemote:SIP/1234, SIP1235, SIP/1236, SIP/2001
    user=1235:5321:all:allLocalAndRemote

    where 1235 is your extention and 2001 is an extension on a remote server. So what this does is it makes the remote extension 2001 part of the allLocalAndRemote group (along with all those other extensions including yours) and then the next line specifically defines you as a user with the ability to view the allLocalAndRemote group. Now of course /usr/local/fop2/buttons_custom.cfg has to have your button(s) defined like so:

    [SIP/2001]
    type=extension
    extension=2001
    context=from-internal
    label=remote-extension-name
    privacy=none
    server=ip-of-remote-server

    and some of those fields are probably just wrong, like maybe context=from-internal, but it works well enough that the button actually shows up for whoever you defined as a user at the end of /usr/local/fop2/autoconfig-users-freepbx.sh (in the example, it was 1235).

    So that's how we got it done, and while we know that cannot possibly be the right way to do it, we couldn't find a better way (yet). If anyone knows of a better way, please please let us know here.

  2. 13 years ago
    Mon Oct 24 17:26:08 2011
    Exosym started the conversation Action Menu customization.

    Hi guys,
    Running FOP2 2.23 on Elastix (FreePBX 2.7.0.3) and loving it. Sorry if this has been asked before, but we have one problem: we purchased the white label license with the voicemail manager but without IM support because we didn't want IM. However, the action menu seems hell-bent on displaying a chat option, and even though the messages don't get sent, it confuses our users who now think that the program is broken. About the closest we've gotten to fixing the problem is to comment out the link to the chat CSS in /var/www/html/fop2/index.html, which won't remove the chat button in the action menu but at least disables the chat window from coming up. We've tried removing the chat permission and restarting FOP2/amportal but that doesn't seem to do anything here. We want to purchase licenses for the rest of our servers but can't justify it if we can't get rid of the chat button.

    tl;dr: Is there any way to remove the chat button from the action menu if removing the chat permission doesn't work?