Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

FOP2 Community Forum

  1. Home
  2. Support
  3. buttons_custom.cfg not being loaded

buttons_custom.cfg not being loaded

Scheduled Pinned Locked Moved Support
17 Posts 3 Posters 431 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N
    N
    nicolas
    wrote on last edited by
    #6

    modify the script a little bit:

    echo
    if [ -f buttons_custom.cfg ]; then
    cat buttons_custom.cfg
    else
    echo "there is no buttons_custom.cfg file"
    echo "there is no buttons_custom.cfg file"
    echo "there is no buttons_custom.cfg file"
    echo "there is no buttons_custom.cfg file"
    echo "there is no buttons_custom.cfg file"
    echo "there is no buttons_custom.cfg file"
    fi
    

    then execute it and look at the output.

    1 Reply Last reply
    0
    • A
      A
      atsak
      wrote on last edited by
      #7

      It says there is no buttons_custom.cfg

      But there is - here's the directory listing. I must be missing something simple.

      -rw-r--r-- 1 root root 36 Aug 24 00:03 autobuttons.cfg
      -rw-r--r-- 1 asterisk asterisk 36 Jun 23 13:35 autobuttons.cfg.~1~
      -rwxr-x--x 1 root root 7889 Aug 26 00:19 autoconfig-buttons-freepbx.sh
      -rwxr-x--x 1 asterisk asterisk 7588 Jun 23 13:35 autoconfig-buttons-freepbx.sh.~1~
      -rwxr-x--x 1 root root 3032 Aug 24 00:03 autoconfig-users-freepbx.sh
      -rwxr-x--x 1 asterisk asterisk 2444 Jun 23 13:35 autoconfig-users-freepbx.sh.~1~
      -rw-r--r-- 1 root root 74974 Jun 23 18:31 borrame.log
      -rw-r--r-- 1 root root 1032 Aug 24 00:03 buttons.cfg.sample
      -rw-r--r-- 1 asterisk asterisk 1032 Jun 23 13:35 buttons.cfg.sample.~1~
      -rw-r--r-- 1 root root 91 Aug 25 01:07 buttons_custom.cfg
      -rw-r--r-- 1 root root 122 Aug 24 00:03 extensions_override_freepbx.conf
      -rw-r--r-- 1 asterisk asterisk 6569 Jun 23 13:35 extensions_override_freepbx.conf~
      -rw-r--r-- 1 asterisk asterisk 3001 Jun 23 13:35 FOP2Callbacks.pm
      -rw-r--r-- 1 root root 3001 Aug 24 00:03 FOP2Callbacks.pm.sample
      -rw-r--r-- 1 asterisk asterisk 5184 Jul 25 15:55 fop2.cfg
      -rw-r--r-- 1 root root 6200 Aug 24 00:03 fop2.cfg.new
      -rw-r--r-- 1 root root 77 Aug 24 00:03 fop2.lic
      -rw-r--r-- 1 root root 77 Jun 23 13:51 fop2.lic.~1~
      -rwxr-x--x 1 root root 8410474 Aug 24 00:03 fop2_server
      -rw-r--r-- 1 root root 7168 Aug 25 23:35 fop2settings.db
      -rwxr-x--x 1 root root 8219 Aug 24 00:03 generate_override_contexts.pl
      -rw-r--r-- 1 root root 5230 Aug 24 00:00 NEWFOPmezFEJ
      -rwxr-xr-x 1 root root 6934 Aug 24 00:03 recording_fop2.pl
      -rwxr-xr-x 1 root root 6271 Aug 24 00:03 tovoicemail.pl
      root@pbx:/usr/local/fop2 $

      1 Reply Last reply
      0
      • A
        A
        atsak
        wrote on last edited by
        #8

        It says there is no buttons_custom.cfg

        But there is - here's the directory listing. I must be missing something simple.
        -rw-r--r-- 1 root root 91 Aug 25 01:07 buttons_custom.cfg

        root@pbx:/usr/local/fop2 $

        OK I found if I changed the script to use the full path /usr/local/fop2/buttons_custom.cfg, the autoconfig freepbx script will now call the file correctly.

        Except it still doesn't show up in the panel.

        What's my next step?

        1 Reply Last reply
        0
        • N
          N
          nicolas
          wrote on last edited by
          #9

          Problem with buttons_custom.cfg is that if you define groups for users, they won't show up as they will not appear in the group definitions.

          1 Reply Last reply
          0
          • A
            A
            atsak
            wrote on last edited by
            #10

            But I don't have any groups for users . . . that's what I keep saying.

            Really! I have never defined a group for users. It's just the default settings. I can't figure out how to post a screenshot of my freepbx fop2 admin screen shot where it shows no groups are configured . . . but I have one to prove it if you want 😄

            1 Reply Last reply
            0
            • N
              N
              nicolas
              wrote on last edited by
              #11

              Do not look at the fop2admin screen, but at the output from autoconfig-users-freepbx.sh script, that way you know for sure if you have groups assigned or not, look for the user=xxx lines, the 4th parameter is the group.

              In any case, if your button config shows when you run autoconfig-buttons-freepbx.sh and you do not see it in the fop2 screen (after reloading fop2, if you change your button config you must reload fop2 server and also relogin to the web client), it is probably there is something missing or incorrect in the button definitions themselves, from what I read about your sample, it is correct, so it should show. It is mandatory to set the type, the type must be valid (type=extension), and you also must put the extension, context and label values. If one of them is missing , the button will not show.

              Also, be sure you are using the registered version so you are not bitten by the 15 buttons limit of the free version.

              1 Reply Last reply
              0
              • A
                A
                atsak
                wrote on last edited by
                #12

                I gave up trying to get this working, but I am upgrading to the new version and thought I'd try again.

                Does the AMI manager user and secret need to be the same on the external server for it to work? In other words, how does it query the external server for status?

                1 Reply Last reply
                0
                • N
                  N
                  nicolas
                  wrote on last edited by
                  #13

                  Hi,

                  Passwords can differt, there is no reason to make them the same, you can specify any password, host, user, port, etc.

                  Making this work is not hard at all, but fop2 restrictions might come into play for displaying the buttons ON THE WEB BROWSER, not so when running the autoconfiguration script as I suggested above.

                  If you see the buttons when running the autoconfig script, but not on the browser, then your limitation is for buttons groups assigned to users, as custom buttons will not be placed into groups.

                  The new version will work the same as the old one, just try to catch me on the live help and I will guide you on making it work.

                  1 Reply Last reply
                  0
                  • T
                    T
                    TRAFSupport
                    wrote on last edited by
                    #14

                    Hello,

                    I am having a similar issue.

                    I have FOP2 registered and set up to monitor two servers and because I am using FreePBX, I have to define buttons for these users manually using the "server=" value.

                    When I run autoconfig-users-freepbx.sh, it does show that it is parsing the buttons_custom.cfg file, but the custom buttons do not show in FOP. I originally tried with no groups set in FreePBX, then I tried setting up a group ("ALL") and manually joining that button to it using a "group=ALL" value, but it still does not show up. I have ensured that the user I am logging into FOP2 as, is able to see that group.

                    The test extension in buttons_custom.cfg looks like the following:
                    [SIP/${XXXX}]
                    type=extension
                    extension=${XXXX}
                    context=from-internal
                    label=${LABEL}
                    server=${HOST_IP}

                    With an optionally added "group=ALL" for after I tried creating a group to see if that would help.

                    Any information as to why I can't get these buttons to show up would be appreciated.

                    Thank you,

                    1 Reply Last reply
                    0
                    • N
                      N
                      nicolas
                      wrote on last edited by
                      #15

                      Hi,

                      There are 2 things to check. That the include of the custom button config file has a full path (if you run fop2 from the init script, an #include buttons_custom.cfg will probably fail, while #include /usr/local/fop2/buttons_custom.cfg will work).

                      The other thing to check is still the groups. If you want to see custom buttons, your fop2 user should not have ANY groups clicked on the fop2 users page in Fop2admin. You have to check that by running:

                      /usr/local/fop2/autoconfig-users-freepbx.sh

                      you should have something like

                      user=100💯all

                      if you have

                      user=100💯all:somegroup

                      you will face issues unless somegroup includes the buttons for the custom config file, and as somegroup is autogenerated, it will not contain anything!.

                      1 Reply Last reply
                      0
                      • T
                        T
                        TRAFSupport
                        wrote on last edited by
                        #16

                        Thanks,

                        I got it working now, however how I did it was not what I expected. It looks like when you set FOP2 to connect to multiple servers, if you build the extensions as a mirror on both servers, FOP2 picks up hints from whichever is actually registered/active. There is no need to create any custom buttons using the "server=" value what so ever.

                        The added advantage is I can also use display groups without it affecting the visibility of the buttons. I don't know if this will work for others, but this might help people who are having issues with the FreePBX admin module and monitoring multiple servers.

                        Thanks,

                        1 Reply Last reply
                        0
                        • N
                          N
                          nicolas
                          wrote on last edited by
                          #17

                          Hi,

                          FOP2 does not discretely monitor same device name across multiple servers. It was mentioned many times in the forum:

                          View Post 495

                          You cannot have a button for SIP/100 on server A and another button for SIP/100 on server B. FOP2 will group activity for SIP/100 no matter the server it is located.

                          This is why you cannot monitor DAHDI trunks on multiple servers for examples, let alone DAHDI extensions. Well, you can, but you cannot do that discretely.

                          Best regards,

                          1 Reply Last reply
                          0

                          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                          With your input, this post could be even better 💗

                          Register Login
                          Reply
                          • Reply as topic
                          Log in to reply
                          • Oldest to Newest
                          • Newest to Oldest
                          • Most Votes


                          • Login

                          • Don't have an account? Register

                          • Login or register to search.
                          Powered by NodeBB Contributors
                          • First post
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • World
                          • Users
                          • Groups